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
- LicenseContext.cs
- ActiveXMessageFormatter.cs
- ToolboxItemFilterAttribute.cs
- TextTreeUndo.cs
- SoapHeaders.cs
- PeerEndPoint.cs
- WebAdminConfigurationHelper.cs
- XmlTextEncoder.cs
- CopyOnWriteList.cs
- BinaryUtilClasses.cs
- EUCJPEncoding.cs
- CommandField.cs
- FigureHelper.cs
- TextElementEditingBehaviorAttribute.cs
- ExpressionBindingCollection.cs
- InputProviderSite.cs
- peernodeimplementation.cs
- ValidationError.cs
- AssociationType.cs
- DataGridCheckBoxColumn.cs
- UserPersonalizationStateInfo.cs
- CodeMemberEvent.cs
- HtmlTextViewAdapter.cs
- BamlRecordWriter.cs
- XmlSerializerFactory.cs
- TextWriterTraceListener.cs
- TableItemPattern.cs
- RtfToken.cs
- COM2ComponentEditor.cs
- Ipv6Element.cs
- HtmlSelect.cs
- WaitHandle.cs
- SingleKeyFrameCollection.cs
- ToolStripDropDownItemDesigner.cs
- cache.cs
- ReachPrintTicketSerializerAsync.cs
- DrawingContextDrawingContextWalker.cs
- ElapsedEventArgs.cs
- SendKeys.cs
- SoapConverter.cs
- EnumUnknown.cs
- WebProxyScriptElement.cs
- QuadraticBezierSegment.cs
- PrivateUnsafeNativeCompoundFileMethods.cs
- OdbcConnection.cs
- ImmutableObjectAttribute.cs
- CompoundFileStorageReference.cs
- CalendarDataBindingHandler.cs
- UidManager.cs
- TypeElement.cs
- SelectedDatesCollection.cs
- Select.cs
- MulticastNotSupportedException.cs
- BuildProvidersCompiler.cs
- AutomationElement.cs
- Empty.cs
- DataMember.cs
- StringExpressionSet.cs
- EnterpriseServicesHelper.cs
- DataFormats.cs
- SqlTransaction.cs
- DefaultAsyncDataDispatcher.cs
- DataSpaceManager.cs
- Stream.cs
- Event.cs
- WebPartZoneCollection.cs
- IItemContainerGenerator.cs
- AssociationType.cs
- AppDomain.cs
- AdRotator.cs
- ReadOnlyDataSource.cs
- _ListenerAsyncResult.cs
- WebConfigurationHost.cs
- CookieProtection.cs
- ImportStoreException.cs
- PriorityChain.cs
- WmlLinkAdapter.cs
- RectangleF.cs
- OLEDB_Enum.cs
- storagemappingitemcollection.viewdictionary.cs
- InvalidFilterCriteriaException.cs
- OutputCacheSettingsSection.cs
- Send.cs
- XDRSchema.cs
- IndexingContentUnit.cs
- TableRowGroup.cs
- WebBrowserNavigatingEventHandler.cs
- StateManager.cs
- HttpListenerException.cs
- EnumMember.cs
- TabControl.cs
- SchemaCollectionCompiler.cs
- TextFormatter.cs
- SafeNativeMethods.cs
- Terminate.cs
- AssemblyAssociatedContentFileAttribute.cs
- _UncName.cs
- Property.cs
- TextTreeRootTextBlock.cs
- PropertyInfoSet.cs