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
- SamlDoNotCacheCondition.cs
- PersonalizationEntry.cs
- HandledMouseEvent.cs
- DataSourceControl.cs
- SqlDataSourceRefreshSchemaForm.cs
- PrintDialogException.cs
- ScrollPattern.cs
- GridViewRowCollection.cs
- SelectionItemPattern.cs
- DrawingImage.cs
- ContentOperations.cs
- ThreadAttributes.cs
- PermissionSetTriple.cs
- FixedSchema.cs
- RequestCacheValidator.cs
- DrawListViewColumnHeaderEventArgs.cs
- CompilerResults.cs
- Normalization.cs
- UriScheme.cs
- EdmSchemaAttribute.cs
- AttachedProperty.cs
- SamlSecurityToken.cs
- SqlNodeTypeOperators.cs
- UnsafeCollabNativeMethods.cs
- TextEndOfLine.cs
- ComponentResourceKeyConverter.cs
- SeparatorAutomationPeer.cs
- _LocalDataStore.cs
- SystemNetHelpers.cs
- FrugalList.cs
- SecurityTokenProvider.cs
- NextPreviousPagerField.cs
- StorageComplexTypeMapping.cs
- ConnectionOrientedTransportChannelFactory.cs
- HtmlFormParameterWriter.cs
- TdsParserHelperClasses.cs
- ListControl.cs
- NetworkStream.cs
- GridView.cs
- AnnotationResourceChangedEventArgs.cs
- PropertyKey.cs
- AssemblyInfo.cs
- CodeObject.cs
- ListViewUpdateEventArgs.cs
- URLIdentityPermission.cs
- WindowsAltTab.cs
- DefaultBindingPropertyAttribute.cs
- TraceUtils.cs
- Timer.cs
- CssTextWriter.cs
- ApplicationServiceHelper.cs
- SaveFileDialog.cs
- UserControl.cs
- GeneratedCodeAttribute.cs
- VerificationException.cs
- TypeResolvingOptions.cs
- NameValueSectionHandler.cs
- ReaderWriterLockWrapper.cs
- DataGridCommandEventArgs.cs
- ItemCheckEvent.cs
- UriTemplateQueryValue.cs
- UrlMappingCollection.cs
- SqlNodeTypeOperators.cs
- FormatConvertedBitmap.cs
- querybuilder.cs
- DuplicateWaitObjectException.cs
- LicenseProviderAttribute.cs
- WindowsScrollBarBits.cs
- BindingExpressionBase.cs
- ClientScriptManager.cs
- AxisAngleRotation3D.cs
- AuthenticationModulesSection.cs
- IsolatedStoragePermission.cs
- NavigationService.cs
- StateManagedCollection.cs
- SystemIPAddressInformation.cs
- WebZone.cs
- ResourceCodeDomSerializer.cs
- FieldBuilder.cs
- DataGridLinkButton.cs
- ReadOnlyCollection.cs
- DoubleLinkListEnumerator.cs
- HTTPRemotingHandler.cs
- PreloadedPackages.cs
- AnonymousIdentificationModule.cs
- JulianCalendar.cs
- PassportPrincipal.cs
- CodeMemberMethod.cs
- XPathDocument.cs
- QueryOperator.cs
- LoaderAllocator.cs
- XmlAttributeOverrides.cs
- SqlInternalConnection.cs
- ReflectTypeDescriptionProvider.cs
- EditingCoordinator.cs
- SafeRegistryKey.cs
- ViewCellSlot.cs
- StorageInfo.cs
- ItemsControl.cs
- ItemsPresenter.cs