Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / Net / System / Net / Configuration / SchemeSettingElement.cs / 1305376 / SchemeSettingElement.cs
using System; using System.Diagnostics; namespace System.Configuration { public sealed class SchemeSettingElement : ConfigurationElement { private static readonly ConfigurationPropertyCollection properties; private static readonly ConfigurationProperty name; private static readonly ConfigurationProperty genericUriParserOptions; static SchemeSettingElement() { name = new ConfigurationProperty(CommonConfigurationStrings.SchemeName, typeof(string), null, ConfigurationPropertyOptions.IsRequired | ConfigurationPropertyOptions.IsKey); genericUriParserOptions = new ConfigurationProperty(CommonConfigurationStrings.GenericUriParserOptions, typeof(GenericUriParserOptions), GenericUriParserOptions.Default, ConfigurationPropertyOptions.IsRequired); properties = new ConfigurationPropertyCollection(); properties.Add(name); properties.Add(genericUriParserOptions); } [ConfigurationProperty(CommonConfigurationStrings.SchemeName, DefaultValue = null, IsRequired = true, IsKey = true)] public string Name { get { return (string)this[name]; } } [ConfigurationProperty(CommonConfigurationStrings.GenericUriParserOptions, DefaultValue = ConfigurationPropertyOptions.None, IsRequired = true)] public GenericUriParserOptions GenericUriParserOptions { get { return (GenericUriParserOptions)this[genericUriParserOptions]; } } protected override ConfigurationPropertyCollection Properties { get { return properties; } } } internal sealed class SchemeSettingInternal { private string name; private GenericUriParserOptions options; public SchemeSettingInternal(string name, GenericUriParserOptions options) { Debug.Assert(name != null, "'name' must not be null."); this.name = name.ToLowerInvariant(); this.options = options; } public string Name { get { return name; } } public GenericUriParserOptions Options { get { return options; } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved. using System; using System.Diagnostics; namespace System.Configuration { public sealed class SchemeSettingElement : ConfigurationElement { private static readonly ConfigurationPropertyCollection properties; private static readonly ConfigurationProperty name; private static readonly ConfigurationProperty genericUriParserOptions; static SchemeSettingElement() { name = new ConfigurationProperty(CommonConfigurationStrings.SchemeName, typeof(string), null, ConfigurationPropertyOptions.IsRequired | ConfigurationPropertyOptions.IsKey); genericUriParserOptions = new ConfigurationProperty(CommonConfigurationStrings.GenericUriParserOptions, typeof(GenericUriParserOptions), GenericUriParserOptions.Default, ConfigurationPropertyOptions.IsRequired); properties = new ConfigurationPropertyCollection(); properties.Add(name); properties.Add(genericUriParserOptions); } [ConfigurationProperty(CommonConfigurationStrings.SchemeName, DefaultValue = null, IsRequired = true, IsKey = true)] public string Name { get { return (string)this[name]; } } [ConfigurationProperty(CommonConfigurationStrings.GenericUriParserOptions, DefaultValue = ConfigurationPropertyOptions.None, IsRequired = true)] public GenericUriParserOptions GenericUriParserOptions { get { return (GenericUriParserOptions)this[genericUriParserOptions]; } } protected override ConfigurationPropertyCollection Properties { get { return properties; } } } internal sealed class SchemeSettingInternal { private string name; private GenericUriParserOptions options; public SchemeSettingInternal(string name, GenericUriParserOptions options) { Debug.Assert(name != null, "'name' must not be null."); this.name = name.ToLowerInvariant(); this.options = options; } public string Name { get { return name; } } public GenericUriParserOptions Options { get { return options; } } } } // 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
- ConfigurationPropertyCollection.cs
- CompileLiteralTextParser.cs
- WebEvents.cs
- SimpleTableProvider.cs
- EntityParameterCollection.cs
- MoveSizeWinEventHandler.cs
- _ProxyRegBlob.cs
- EarlyBoundInfo.cs
- ObservableDictionary.cs
- DnsCache.cs
- MobileErrorInfo.cs
- ImportCatalogPart.cs
- arclist.cs
- TextEditorSelection.cs
- ExceptionTrace.cs
- Configuration.cs
- RegexWriter.cs
- DataTemplateKey.cs
- WebBrowserContainer.cs
- KnownBoxes.cs
- _OverlappedAsyncResult.cs
- RectangleConverter.cs
- ProfileInfo.cs
- UmAlQuraCalendar.cs
- GroupPartitionExpr.cs
- AlternateView.cs
- WindowsGraphicsWrapper.cs
- BamlStream.cs
- TextEvent.cs
- TextRenderer.cs
- XmlSchema.cs
- UserInitiatedNavigationPermission.cs
- TextServicesCompartmentContext.cs
- CharAnimationUsingKeyFrames.cs
- SafeNativeMethods.cs
- SHA384.cs
- printdlgexmarshaler.cs
- DirectionalAction.cs
- PhysicalAddress.cs
- FileDialogPermission.cs
- DataDesignUtil.cs
- NetSectionGroup.cs
- TransactionBehavior.cs
- EntityContainerEmitter.cs
- KeyGestureConverter.cs
- DecoderExceptionFallback.cs
- _SslState.cs
- OdbcCommand.cs
- LinqDataSourceContextEventArgs.cs
- Int32Rect.cs
- PropertyGridCommands.cs
- ResourcePropertyMemberCodeDomSerializer.cs
- XmlnsDictionary.cs
- arabicshape.cs
- PenLineCapValidation.cs
- RedistVersionInfo.cs
- WebServicesInteroperability.cs
- X509Chain.cs
- NonPrimarySelectionGlyph.cs
- ClientUtils.cs
- ClientBuildManagerCallback.cs
- BamlBinaryWriter.cs
- InputProviderSite.cs
- Int32EqualityComparer.cs
- PropertyCollection.cs
- ValueUnavailableException.cs
- RoutedEventConverter.cs
- FileDialog_Vista_Interop.cs
- TextProperties.cs
- WebPartZone.cs
- JpegBitmapDecoder.cs
- DataServiceStreamProviderWrapper.cs
- Environment.cs
- InputScopeAttribute.cs
- SqlGatherConsumedAliases.cs
- TypeForwardedToAttribute.cs
- DocumentReferenceCollection.cs
- AnimationStorage.cs
- ClaimTypes.cs
- ProvidersHelper.cs
- FixedSOMElement.cs
- SqlReorderer.cs
- HMAC.cs
- SQLRoleProvider.cs
- ProviderConnectionPoint.cs
- ChangeBlockUndoRecord.cs
- Missing.cs
- NetCodeGroup.cs
- DateTimeValueSerializer.cs
- Brush.cs
- APCustomTypeDescriptor.cs
- EnumBuilder.cs
- MimeMultiPart.cs
- MostlySingletonList.cs
- SliderAutomationPeer.cs
- AtomServiceDocumentSerializer.cs
- InvalidPropValue.cs
- DeploymentSectionCache.cs
- DesignerHelpers.cs
- DefaultParameterValueAttribute.cs