Code:
/ DotNET / DotNET / 8.0 / untmp / WIN_WINDOWS / lh_tools_devdiv_wpf / Windows / wcp / Base / System / Windows / ExpressionConverter.cs / 1 / ExpressionConverter.cs
//---------------------------------------------------------------------------- // // File: ExpressionConverter.cs // // Description: // TypeConverter for a generic property value expression // // Copyright (C) 2003 by Microsoft Corporation. All rights reserved. // //--------------------------------------------------------------------------- using System; using System.ComponentModel; using System.Globalization; using System.ComponentModel.Design.Serialization; namespace System.Windows { ////// TypeConverter for a generic property value expression /// ////// The cole purpose of this TypeConveret is to block the /// default TypeConverter/ ToString() behavior /// public class ExpressionConverter : TypeConverter { ////// TypeConverter method override. /// /// /// ITypeDescriptorContext /// /// /// Type to convert from /// ////// true if conversion is possible /// public override bool CanConvertFrom(ITypeDescriptorContext context, Type sourceType) { return false; } ////// TypeConverter method override. /// /// /// ITypeDescriptorContext /// /// /// Type to convert to /// ////// true if conversion is possible /// public override bool CanConvertTo(ITypeDescriptorContext context, Type destinationType) { return false; } ////// TypeConverter method implementation. /// /// /// ITypeDescriptorContext /// /// /// current culture (see CLR specs) /// /// /// value to convert from /// ////// value that is result of conversion /// public override object ConvertFrom(ITypeDescriptorContext context, CultureInfo culture, object value) { throw GetConvertFromException(value); } ////// TypeConverter method implementation. /// /// /// ITypeDescriptorContext /// /// /// current culture (see CLR specs) /// /// /// value to convert from /// /// /// Type to convert to /// ////// converted value /// public override object ConvertTo(ITypeDescriptorContext context, CultureInfo culture, object value, Type destinationType) { throw GetConvertToException(value, destinationType); } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- WebBrowserUriTypeConverter.cs
- ProjectionCamera.cs
- StrongNameIdentityPermission.cs
- DataGridDefaultColumnWidthTypeConverter.cs
- RoleManagerSection.cs
- Module.cs
- EditorZoneBase.cs
- WebRequestModuleElement.cs
- FixedTextPointer.cs
- LinqExpressionNormalizer.cs
- SoapHttpTransportImporter.cs
- WCFServiceClientProxyGenerator.cs
- AlgoModule.cs
- BinaryCommonClasses.cs
- NavigationProperty.cs
- BitmapMetadataEnumerator.cs
- SqlUtils.cs
- UpdatePanelTriggerCollection.cs
- ListView.cs
- TreeNodeStyleCollection.cs
- DeviceContexts.cs
- sortedlist.cs
- HandlerBase.cs
- ConfigurationSettings.cs
- CodeCatchClauseCollection.cs
- EllipticalNodeOperations.cs
- Literal.cs
- ConnectionOrientedTransportChannelListener.cs
- DBCommand.cs
- FlowDocumentView.cs
- GetMemberBinder.cs
- _WebProxyDataBuilder.cs
- FormattedTextSymbols.cs
- DoubleConverter.cs
- Point.cs
- OrderPreservingMergeHelper.cs
- ArcSegment.cs
- AnonymousIdentificationSection.cs
- HtmlControlPersistable.cs
- PersonalizationProviderHelper.cs
- FloatSumAggregationOperator.cs
- DataReaderContainer.cs
- ContextMenuStrip.cs
- DataRowCollection.cs
- WebServiceMethodData.cs
- UDPClient.cs
- FileDialog.cs
- WebColorConverter.cs
- ListViewGroupItemCollection.cs
- DBConnectionString.cs
- Baml2006ReaderContext.cs
- CodeRegionDirective.cs
- EmptyCollection.cs
- UIElementParaClient.cs
- DataTableReaderListener.cs
- OutputScopeManager.cs
- StrokeCollectionDefaultValueFactory.cs
- ScriptingAuthenticationServiceSection.cs
- MessageLoggingFilterTraceRecord.cs
- OptimizerPatterns.cs
- METAHEADER.cs
- UserControlCodeDomTreeGenerator.cs
- DbMetaDataCollectionNames.cs
- SchemaMapping.cs
- FormClosingEvent.cs
- GenericXmlSecurityToken.cs
- UriExt.cs
- TcpServerChannel.cs
- SimpleHandlerFactory.cs
- ServiceInfoCollection.cs
- ControlParameter.cs
- SQLStringStorage.cs
- CodeAttributeArgumentCollection.cs
- CommandArguments.cs
- KeyValueConfigurationElement.cs
- NetNamedPipeBindingCollectionElement.cs
- XmlNamespaceDeclarationsAttribute.cs
- ZipIOExtraFieldPaddingElement.cs
- DataFieldCollectionEditor.cs
- PackWebResponse.cs
- Page.cs
- ConsumerConnectionPointCollection.cs
- HtmlTextBoxAdapter.cs
- XmlSchemaImport.cs
- CrossSiteScriptingValidation.cs
- ProcessMonitor.cs
- MetadataUtilsSmi.cs
- FilteredXmlReader.cs
- XmlAggregates.cs
- InstanceStore.cs
- ComponentEditorPage.cs
- ThreadStaticAttribute.cs
- DataGridRow.cs
- ColumnMap.cs
- CfgParser.cs
- MultipleViewProviderWrapper.cs
- FrameworkPropertyMetadata.cs
- SQLInt64.cs
- ClassHandlersStore.cs
- WizardForm.cs