Code:
/ Net / Net / 3.5.50727.3053 / DEVDIV / depot / DevDiv / releases / whidbey / netfxsp / ndp / fx / src / Configuration / System / Configuration / ConfigurationConverterBase.cs / 1 / ConfigurationConverterBase.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- using System; using System.Collections; using System.IO; using System.Reflection; using System.Security.Permissions; using System.Xml; using System.Collections.Specialized; using System.Globalization; using System.ComponentModel; using System.Security; using System.Text; namespace System.Configuration { public abstract class ConfigurationConverterBase : TypeConverter { public override bool CanConvertTo(ITypeDescriptorContext ctx, Type type) { return (type == typeof(string)); } public override bool CanConvertFrom(ITypeDescriptorContext ctx, Type type) { return (type == typeof(string)); } internal void ValidateType(object value, Type expected) { if ((value != null) && (value.GetType() != expected)) { throw new ArgumentException(SR.GetString(SR.Converter_unsupported_value_type, expected.Name)); } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- using System; using System.Collections; using System.IO; using System.Reflection; using System.Security.Permissions; using System.Xml; using System.Collections.Specialized; using System.Globalization; using System.ComponentModel; using System.Security; using System.Text; namespace System.Configuration { public abstract class ConfigurationConverterBase : TypeConverter { public override bool CanConvertTo(ITypeDescriptorContext ctx, Type type) { return (type == typeof(string)); } public override bool CanConvertFrom(ITypeDescriptorContext ctx, Type type) { return (type == typeof(string)); } internal void ValidateType(object value, Type expected) { if ((value != null) && (value.GetType() != expected)) { throw new ArgumentException(SR.GetString(SR.Converter_unsupported_value_type, expected.Name)); } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- DataGridViewRowsAddedEventArgs.cs
- DrawingImage.cs
- Lasso.cs
- GeneralTransform.cs
- CalloutQueueItem.cs
- TextEndOfLine.cs
- DetectRunnableInstancesTask.cs
- XmlMtomWriter.cs
- UInt64.cs
- ValuePatternIdentifiers.cs
- ExpressionBuilder.cs
- NetworkInformationPermission.cs
- CompilerHelpers.cs
- SQLStringStorage.cs
- PageAsyncTask.cs
- TailCallAnalyzer.cs
- ActivityPreviewDesigner.cs
- UpdateProgress.cs
- NetCodeGroup.cs
- FileDialogCustomPlace.cs
- SchemaDeclBase.cs
- TypeSource.cs
- CompensatableSequenceActivity.cs
- ExpressionLexer.cs
- DropShadowEffect.cs
- LinearKeyFrames.cs
- CodeVariableDeclarationStatement.cs
- PrintPreviewControl.cs
- FlagsAttribute.cs
- IItemProperties.cs
- InputBinding.cs
- CharacterMetricsDictionary.cs
- ContentOperations.cs
- ByteArrayHelperWithString.cs
- ConfigXmlWhitespace.cs
- X509UI.cs
- ShutDownListener.cs
- WebDescriptionAttribute.cs
- PathData.cs
- OleDbRowUpdatedEvent.cs
- ManifestResourceInfo.cs
- TemplateKey.cs
- SerialPort.cs
- WindowsListBox.cs
- CodePageUtils.cs
- MissingFieldException.cs
- Function.cs
- WebPartAuthorizationEventArgs.cs
- OdbcConnection.cs
- SocketException.cs
- InkCanvas.cs
- WindowsIdentity.cs
- CornerRadiusConverter.cs
- ListViewDataItem.cs
- HttpServerUtilityBase.cs
- indexingfiltermarshaler.cs
- ToolStripSeparator.cs
- Stopwatch.cs
- NameValueFileSectionHandler.cs
- AuthenticationServiceManager.cs
- EllipticalNodeOperations.cs
- oledbmetadatacollectionnames.cs
- PageCache.cs
- storepermission.cs
- LoginView.cs
- Stylesheet.cs
- PublisherIdentityPermission.cs
- ActivityTrace.cs
- DetailsViewDeletedEventArgs.cs
- PKCS1MaskGenerationMethod.cs
- Rfc4050KeyFormatter.cs
- ImagingCache.cs
- WinFormsComponentEditor.cs
- BufferAllocator.cs
- TypeSystem.cs
- ConfigXmlDocument.cs
- OracleNumber.cs
- GroupBox.cs
- KeyboardDevice.cs
- StoreContentChangedEventArgs.cs
- XmlSchemaFacet.cs
- InstanceDescriptor.cs
- ColorContextHelper.cs
- HtmlShim.cs
- ProjectionPathSegment.cs
- UidManager.cs
- TemplateAction.cs
- FaultCode.cs
- SoapAttributeAttribute.cs
- UniqueIdentifierService.cs
- EventLogPermissionHolder.cs
- Stack.cs
- InstalledFontCollection.cs
- Automation.cs
- SpellerStatusTable.cs
- Journaling.cs
- UidManager.cs
- BeginSelectCardRequest.cs
- ResolveNameEventArgs.cs
- DataConnectionHelper.cs