Code:
/ FX-1434 / FX-1434 / 1.0 / untmp / whidbey / REDBITS / ndp / fx / src / Net / System / Net / Configuration / UriSection.cs / 1 / UriSection.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Configuration { using System.Threading; ////// Summary description for UriSection. /// public sealed class UriSection : ConfigurationSection { public UriSection(){ this.properties.Add(this.idn); this.properties.Add(this.iriParsing); } [ConfigurationProperty(CommonConfigurationStrings.Idn)] public IdnElement Idn{ get { return (IdnElement)this[this.idn]; } } [ConfigurationProperty(CommonConfigurationStrings.IriParsing)] public IriParsingElement IriParsing { get{ return (IriParsingElement)this[this.iriParsing]; } } protected override ConfigurationPropertyCollection Properties { get{ return this.properties; } } ConfigurationPropertyCollection properties = new ConfigurationPropertyCollection(); readonly ConfigurationProperty idn = new ConfigurationProperty(CommonConfigurationStrings.Idn, typeof(IdnElement), null, ConfigurationPropertyOptions.None); readonly ConfigurationProperty iriParsing = new ConfigurationProperty(CommonConfigurationStrings.IriParsing, typeof(IriParsingElement), null, ConfigurationPropertyOptions.None); } internal sealed class UriSectionInternal { internal UriSectionInternal(UriSection section) { this.idn = section.Idn.Enabled; this.iriParsing = section.IriParsing.Enabled; } internal UriIdnScope Idn { get { return this.idn; } } internal bool IriParsing { get { return this.iriParsing; } } bool iriParsing; UriIdnScope idn; internal static object ClassSyncObject { get{ if (classSyncObject == null){ Interlocked.CompareExchange(ref classSyncObject, new object(), null); } return classSyncObject; } } internal static UriSectionInternal GetSection() { lock (ClassSyncObject){ UriSection section = PrivilegedConfigurationManager.GetSection(CommonConfigurationStrings.UriSectionPath) as UriSection; if (section == null) return null; return new UriSectionInternal(section); } } private static object classSyncObject; } }
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- ImportCatalogPart.cs
- Matrix3DValueSerializer.cs
- AddInIpcChannel.cs
- RecommendedAsConfigurableAttribute.cs
- SimpleWorkerRequest.cs
- XPathNodePointer.cs
- WebServiceParameterData.cs
- OledbConnectionStringbuilder.cs
- ReferenceSchema.cs
- MetabaseServerConfig.cs
- _AutoWebProxyScriptEngine.cs
- ColorContext.cs
- AdornerLayer.cs
- XmlnsCache.cs
- InstallerTypeAttribute.cs
- PropertyIDSet.cs
- DataGridViewRowStateChangedEventArgs.cs
- BitmapData.cs
- Highlights.cs
- TypeSource.cs
- Set.cs
- KeyToListMap.cs
- QueueProcessor.cs
- DbLambda.cs
- BoundField.cs
- SqlRecordBuffer.cs
- NonSerializedAttribute.cs
- KeyTimeConverter.cs
- SqlDataRecord.cs
- _BufferOffsetSize.cs
- wgx_sdk_version.cs
- ResourceBinder.cs
- NullReferenceException.cs
- TextEncodedRawTextWriter.cs
- FormatterConverter.cs
- Storyboard.cs
- GridViewColumnHeader.cs
- WaitHandle.cs
- TerminatorSinks.cs
- BasicCommandTreeVisitor.cs
- CFStream.cs
- ComplexTypeEmitter.cs
- ApplicationHost.cs
- ShaderRenderModeValidation.cs
- ConnectorMovedEventArgs.cs
- MergeFilterQuery.cs
- Trustee.cs
- EntryPointNotFoundException.cs
- Attributes.cs
- XsdDateTime.cs
- FixedHyperLink.cs
- RtfControls.cs
- ObjectListDesigner.cs
- DbProviderSpecificTypePropertyAttribute.cs
- DataSourceConverter.cs
- SplitterEvent.cs
- RadioButtonStandardAdapter.cs
- XmlSchemaInfo.cs
- KeyTimeConverter.cs
- Thread.cs
- DataContractSerializerOperationGenerator.cs
- CompositionCommandSet.cs
- XmlAttributeCollection.cs
- RequestStatusBarUpdateEventArgs.cs
- TreeSet.cs
- DataGridItemCollection.cs
- returneventsaver.cs
- MailBnfHelper.cs
- SafeFileMappingHandle.cs
- NavigationProperty.cs
- NegotiateStream.cs
- ColumnPropertiesGroup.cs
- ImportContext.cs
- WizardForm.cs
- Panel.cs
- DataGridViewCellEventArgs.cs
- Wildcard.cs
- CodeNamespace.cs
- ParseHttpDate.cs
- Axis.cs
- HttpCacheVary.cs
- InvalidAsynchronousStateException.cs
- MenuDesigner.cs
- ClassDataContract.cs
- EntitySqlQueryCacheEntry.cs
- ExceptionList.cs
- UIInitializationException.cs
- DetailsViewPageEventArgs.cs
- DataControlCommands.cs
- EntitySqlException.cs
- SmiEventStream.cs
- SuppressIldasmAttribute.cs
- CompressionTransform.cs
- IISMapPath.cs
- AddInContractAttribute.cs
- XsltSettings.cs
- BindingNavigator.cs
- MenuCommandService.cs
- NodeFunctions.cs
- HostSecurityManager.cs