Code:
/ DotNET / DotNET / 8.0 / untmp / whidbey / REDBITS / ndp / fx / src / CompMod / System / ComponentModel / CollectionConverter.cs / 1 / 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; } } }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
- SmtpFailedRecipientException.cs
- DataGridViewComboBoxCell.cs
- HtmlButton.cs
- StandardCommands.cs
- IxmlLineInfo.cs
- HandlerMappingMemo.cs
- Nullable.cs
- CompensatableTransactionScopeActivityDesigner.cs
- TabControl.cs
- BufferModesCollection.cs
- Propagator.JoinPropagator.cs
- selecteditemcollection.cs
- BackgroundWorker.cs
- XLinq.cs
- BuilderElements.cs
- GridViewColumnCollectionChangedEventArgs.cs
- DataServiceQueryException.cs
- DataGridViewRowContextMenuStripNeededEventArgs.cs
- PlatformNotSupportedException.cs
- HeaderCollection.cs
- RoutedUICommand.cs
- ComNativeDescriptor.cs
- VirtualizedContainerService.cs
- CheckBoxFlatAdapter.cs
- DeviceSpecificChoice.cs
- XmlSchemaInferenceException.cs
- FullTrustAssembliesSection.cs
- EpmCustomContentDeSerializer.cs
- GridEntry.cs
- NativeMethods.cs
- RowToParametersTransformer.cs
- MembershipUser.cs
- FormViewModeEventArgs.cs
- CodeIndexerExpression.cs
- SecurityTokenReferenceStyle.cs
- Utils.cs
- RecipientInfo.cs
- _ProxyChain.cs
- HitTestWithPointDrawingContextWalker.cs
- SignedXml.cs
- XsdDuration.cs
- EntityDataSourceDesigner.cs
- Label.cs
- MetadataHelper.cs
- TemplateInstanceAttribute.cs
- TextBox.cs
- ZoomComboBox.cs
- IndentTextWriter.cs
- IArgumentProvider.cs
- SafeViewOfFileHandle.cs
- ServiceHttpModule.cs
- EmptyImpersonationContext.cs
- Separator.cs
- InvalidProgramException.cs
- BufferedWebEventProvider.cs
- EditCommandColumn.cs
- DbConnectionPoolGroup.cs
- XmlLanguageConverter.cs
- NumberEdit.cs
- Visual3D.cs
- HttpListenerContext.cs
- DbProviderSpecificTypePropertyAttribute.cs
- MetadataSerializer.cs
- XmlReturnReader.cs
- SchemaCollectionCompiler.cs
- SynchronousChannelMergeEnumerator.cs
- TreeNodeClickEventArgs.cs
- ResourceCollectionInfo.cs
- CustomPopupPlacement.cs
- UInt64Converter.cs
- RegexFCD.cs
- DefaultEventAttribute.cs
- GraphicsPathIterator.cs
- PackWebRequest.cs
- Int16.cs
- EFTableProvider.cs
- TreeNodeStyle.cs
- MailSettingsSection.cs
- EmbeddedObject.cs
- CheckBoxList.cs
- PlatformNotSupportedException.cs
- ProfileSection.cs
- SendActivity.cs
- Rfc2898DeriveBytes.cs
- CultureInfo.cs
- SafePipeHandle.cs
- VerificationException.cs
- CommonProperties.cs
- SvcMapFile.cs
- MetabaseSettingsIis7.cs
- TableRowCollection.cs
- ControlLocalizer.cs
- PartitionResolver.cs
- SimpleWebHandlerParser.cs
- CellConstant.cs
- BitStream.cs
- MetafileEditor.cs
- ToolStripDropDownMenu.cs
- AsymmetricSecurityProtocolFactory.cs
- AutomationElement.cs