Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / CompMod / System / ComponentModel / CollectionConverter.cs / 1305376 / CollectionConverter.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- /* */ namespace System.ComponentModel { using Microsoft.Win32; using System.Collections; using System.ComponentModel; using System.Diagnostics; using System.Globalization; using System.Runtime.Serialization.Formatters; using System.Runtime.Remoting; using System.Runtime.InteropServices; using System.Security.Permissions; ////// [HostProtection(SharedState = true)] public class CollectionConverter : TypeConverter { ///Provides a type converter to convert /// collection objects to and from various other representations. ////// public override object ConvertTo(ITypeDescriptorContext context, CultureInfo culture, object value, Type destinationType) { if (destinationType == null) { throw new ArgumentNullException("destinationType"); } if (destinationType == typeof(string)) { if (value is ICollection) { return SR.GetString(SR.CollectionConverterText); } } return base.ConvertTo(context, culture, value, destinationType); } ///Converts the given /// value object to the /// specified destination type. ////// public override PropertyDescriptorCollection GetProperties(ITypeDescriptorContext context, object value, Attribute[] attributes) { //return new PropertyDescriptorCollection(null); return null; } ///Gets a collection of properties for /// the type of array specified by the value parameter using the specified context and /// attributes. ////// public override bool GetPropertiesSupported(ITypeDescriptorContext context) { return false; } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007.Gets a value indicating whether this object /// supports properties. ///
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- ConditionCollection.cs
- __Error.cs
- BooleanFacetDescriptionElement.cs
- Compiler.cs
- SqlSelectStatement.cs
- XamlToRtfWriter.cs
- ContourSegment.cs
- DESCryptoServiceProvider.cs
- ValidationErrorCollection.cs
- Timer.cs
- CodeTypeReference.cs
- ErrorRuntimeConfig.cs
- DataGridViewTopRowAccessibleObject.cs
- TreeViewAutomationPeer.cs
- EmptyArray.cs
- SiteMapNode.cs
- DnsEndPoint.cs
- HtmlTextViewAdapter.cs
- ComponentEvent.cs
- HtmlFormWrapper.cs
- TabControlCancelEvent.cs
- ProviderConnectionPointCollection.cs
- ImageMapEventArgs.cs
- TimeIntervalCollection.cs
- InvalidFilterCriteriaException.cs
- TextViewBase.cs
- MetadataItemEmitter.cs
- FileDialog_Vista.cs
- SafeRegistryKey.cs
- Literal.cs
- BooleanExpr.cs
- AutomationEvent.cs
- DataGridView.cs
- CallSiteOps.cs
- EdgeModeValidation.cs
- DataObjectFieldAttribute.cs
- ListViewSelectEventArgs.cs
- AmbiguousMatchException.cs
- PickDesigner.xaml.cs
- DynamicPropertyReader.cs
- ArgumentNullException.cs
- MoveSizeWinEventHandler.cs
- GPStream.cs
- XmlSchemaAttributeGroup.cs
- GeneralTransform.cs
- XmlQueryOutput.cs
- DataServiceQueryContinuation.cs
- DefaultValueConverter.cs
- EntityModelSchemaGenerator.cs
- CacheChildrenQuery.cs
- HttpCookiesSection.cs
- AsyncOperation.cs
- StructuralType.cs
- XmlSchemaType.cs
- TreeViewItem.cs
- ToolTipService.cs
- DES.cs
- SqlSelectClauseBuilder.cs
- RegexCharClass.cs
- MultipartContentParser.cs
- Rect3D.cs
- EffectiveValueEntry.cs
- HitTestResult.cs
- XmlEventCache.cs
- TransformDescriptor.cs
- TextServicesCompartment.cs
- DispatcherOperation.cs
- XappLauncher.cs
- SessionStateUtil.cs
- ConfigurationLockCollection.cs
- FileLogRecordStream.cs
- DoubleStorage.cs
- RegisteredDisposeScript.cs
- AuthenticatingEventArgs.cs
- SqlCommand.cs
- PropertyManager.cs
- ScrollBar.cs
- DBCommandBuilder.cs
- GeometryHitTestResult.cs
- DataTableMapping.cs
- WindowsButton.cs
- Viewport3DAutomationPeer.cs
- FtpWebRequest.cs
- PingReply.cs
- FileSecurity.cs
- ItemAutomationPeer.cs
- RoutedCommand.cs
- StringResourceManager.cs
- sqlser.cs
- NotifyParentPropertyAttribute.cs
- Expressions.cs
- ToolStripItemDataObject.cs
- SynchronizationHandlesCodeDomSerializer.cs
- TableLayoutSettings.cs
- XmlSchemaResource.cs
- FtpCachePolicyElement.cs
- ScriptModule.cs
- oledbconnectionstring.cs
- SendActivityValidator.cs
- Trace.cs