Code:
/ WCF / WCF / 3.5.30729.1 / untmp / Orcas / SP / ndp / cdf / src / WCF / SMDiagnostics / System / ServiceModel / Diagnostics / MachineSettingsSection.cs / 1 / MachineSettingsSection.cs
//------------------------------------------------------------------------------ // Copyright (c) Microsoft Corporation. All rights reserved. //----------------------------------------------------------------------------- namespace System.ServiceModel.Configuration { using System.Configuration; internal class MachineSettingsSection : ConfigurationSection { static bool enableLoggingKnownPii; static bool hasInitialized = false; static object syncRoot = new object(); const string enableLoggingKnownPiiKey = "enableLoggingKnownPii"; ConfigurationPropertyCollection properties; protected override ConfigurationPropertyCollection Properties { get { if (this.properties == null) { ConfigurationPropertyCollection properties = new ConfigurationPropertyCollection(); properties.Add(new ConfigurationProperty(MachineSettingsSection.enableLoggingKnownPiiKey, typeof(System.Boolean), false, null, null, System.Configuration.ConfigurationPropertyOptions.None)); this.properties = properties; } return this.properties; } } public static bool EnableLoggingKnownPii { get { if (!hasInitialized) { lock (syncRoot) { if (!hasInitialized) { MachineSettingsSection machineSettingsSection = (MachineSettingsSection)ConfigurationManager.GetSection("system.serviceModel/machineSettings"); enableLoggingKnownPii = (bool)machineSettingsSection[MachineSettingsSection.enableLoggingKnownPiiKey]; hasInitialized = true; } } } return enableLoggingKnownPii; } } } } // 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
- OperationInvokerTrace.cs
- ListView.cs
- SiteMembershipCondition.cs
- RC2.cs
- HttpDebugHandler.cs
- WasHostedComPlusFactory.cs
- SlotInfo.cs
- ImageListDesigner.cs
- PublisherIdentityPermission.cs
- BindingContext.cs
- PostBackTrigger.cs
- XPathScanner.cs
- PointLight.cs
- SynchronousChannelMergeEnumerator.cs
- HostExecutionContextManager.cs
- SqlCachedBuffer.cs
- SystemColorTracker.cs
- XsdBuildProvider.cs
- DoubleLink.cs
- FlowStep.cs
- StringCollection.cs
- ProviderMetadataCachedInformation.cs
- SessionParameter.cs
- CreateUserErrorEventArgs.cs
- glyphs.cs
- ZoneIdentityPermission.cs
- ActiveXContainer.cs
- RegexParser.cs
- SpotLight.cs
- Internal.cs
- RegexTypeEditor.cs
- PropertyRef.cs
- PipeStream.cs
- DeploymentSectionCache.cs
- latinshape.cs
- IgnoreSectionHandler.cs
- OutputCacheProviderCollection.cs
- PnrpPeerResolverElement.cs
- BooleanKeyFrameCollection.cs
- BuildDependencySet.cs
- MarshalByValueComponent.cs
- XmlWriter.cs
- XmlSchemaAppInfo.cs
- ProfileGroupSettingsCollection.cs
- TaiwanLunisolarCalendar.cs
- SingleKeyFrameCollection.cs
- XmlSchemaCollection.cs
- GridSplitterAutomationPeer.cs
- MetadataException.cs
- ItemTypeToolStripMenuItem.cs
- Array.cs
- Tuple.cs
- DependentTransaction.cs
- WindowsFormsSectionHandler.cs
- Converter.cs
- String.cs
- IISMapPath.cs
- BindableAttribute.cs
- RIPEMD160Managed.cs
- AsyncSerializedWorker.cs
- AdPostCacheSubstitution.cs
- RotateTransform3D.cs
- AddInStore.cs
- ApplicationManager.cs
- EntityExpressionVisitor.cs
- AssemblyInfo.cs
- XPathScanner.cs
- GlobalProxySelection.cs
- NumberAction.cs
- ToolStripRenderEventArgs.cs
- ThreadStateException.cs
- XamlSerializer.cs
- UserControl.cs
- StickyNoteAnnotations.cs
- BinHexDecoder.cs
- ResourceSet.cs
- EntityKeyElement.cs
- DataShape.cs
- HttpRawResponse.cs
- ScriptingAuthenticationServiceSection.cs
- SystemMulticastIPAddressInformation.cs
- SmiXetterAccessMap.cs
- ActiveXHelper.cs
- SettingsPropertyWrongTypeException.cs
- FamilyMapCollection.cs
- SqlSupersetValidator.cs
- AstTree.cs
- ConnectionStringsExpressionBuilder.cs
- GenericWebPart.cs
- OdbcHandle.cs
- NotSupportedException.cs
- TypeConverterMarkupExtension.cs
- CustomValidator.cs
- DataReceivedEventArgs.cs
- SyncMethodInvoker.cs
- Logging.cs
- SecurityManager.cs
- XmlElement.cs
- SBCSCodePageEncoding.cs
- DeploymentSection.cs