Code:
/ Dotnetfx_Vista_SP2 / Dotnetfx_Vista_SP2 / 8.0.50727.4016 / DEVDIV / depot / DevDiv / releases / whidbey / NetFxQFE / ndp / fx / src / CompMod / System / Diagnostics / SystemDiagnosticsSection.cs / 1 / SystemDiagnosticsSection.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- using System.Configuration; namespace System.Diagnostics { internal class SystemDiagnosticsSection : ConfigurationSection { private static readonly ConfigurationPropertyCollection _properties; private static readonly ConfigurationProperty _propAssert = new ConfigurationProperty("assert", typeof(AssertSection), new AssertSection(), ConfigurationPropertyOptions.None); private static readonly ConfigurationProperty _propPerfCounters = new ConfigurationProperty("performanceCounters", typeof(PerfCounterSection), new PerfCounterSection(), ConfigurationPropertyOptions.None); private static readonly ConfigurationProperty _propSources = new ConfigurationProperty("sources", typeof(SourceElementsCollection), new SourceElementsCollection(), ConfigurationPropertyOptions.None); private static readonly ConfigurationProperty _propSharedListeners = new ConfigurationProperty("sharedListeners", typeof(SharedListenerElementsCollection), new SharedListenerElementsCollection(), ConfigurationPropertyOptions.None); private static readonly ConfigurationProperty _propSwitches = new ConfigurationProperty("switches", typeof(SwitchElementsCollection), new SwitchElementsCollection(), ConfigurationPropertyOptions.None); private static readonly ConfigurationProperty _propTrace = new ConfigurationProperty("trace", typeof(TraceSection), new TraceSection(), ConfigurationPropertyOptions.None); static SystemDiagnosticsSection() { _properties = new ConfigurationPropertyCollection(); _properties.Add(_propAssert); _properties.Add(_propPerfCounters); _properties.Add(_propSources); _properties.Add(_propSharedListeners); _properties.Add(_propSwitches); _properties.Add(_propTrace); } [ConfigurationProperty("assert")] public AssertSection Assert { get { return (AssertSection) base[_propAssert]; } } [ConfigurationProperty("performanceCounters")] public PerfCounterSection PerfCounters { get { return (PerfCounterSection) base[_propPerfCounters]; } } protected override ConfigurationPropertyCollection Properties { get { return _properties; } } [ConfigurationProperty("sources")] public SourceElementsCollection Sources { get { return (SourceElementsCollection ) base[_propSources]; } } [ConfigurationProperty("sharedListeners")] public ListenerElementsCollection SharedListeners { get { return (ListenerElementsCollection) base[_propSharedListeners]; } } [ConfigurationProperty("switches")] public SwitchElementsCollection Switches { get { return (SwitchElementsCollection) base[_propSwitches]; } } [ConfigurationProperty("trace")] public TraceSection Trace { get { return (TraceSection) base[_propTrace]; } } protected override void InitializeDefault() { Trace.Listeners.InitializeDefaultInternal(); } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- using System.Configuration; namespace System.Diagnostics { internal class SystemDiagnosticsSection : ConfigurationSection { private static readonly ConfigurationPropertyCollection _properties; private static readonly ConfigurationProperty _propAssert = new ConfigurationProperty("assert", typeof(AssertSection), new AssertSection(), ConfigurationPropertyOptions.None); private static readonly ConfigurationProperty _propPerfCounters = new ConfigurationProperty("performanceCounters", typeof(PerfCounterSection), new PerfCounterSection(), ConfigurationPropertyOptions.None); private static readonly ConfigurationProperty _propSources = new ConfigurationProperty("sources", typeof(SourceElementsCollection), new SourceElementsCollection(), ConfigurationPropertyOptions.None); private static readonly ConfigurationProperty _propSharedListeners = new ConfigurationProperty("sharedListeners", typeof(SharedListenerElementsCollection), new SharedListenerElementsCollection(), ConfigurationPropertyOptions.None); private static readonly ConfigurationProperty _propSwitches = new ConfigurationProperty("switches", typeof(SwitchElementsCollection), new SwitchElementsCollection(), ConfigurationPropertyOptions.None); private static readonly ConfigurationProperty _propTrace = new ConfigurationProperty("trace", typeof(TraceSection), new TraceSection(), ConfigurationPropertyOptions.None); static SystemDiagnosticsSection() { _properties = new ConfigurationPropertyCollection(); _properties.Add(_propAssert); _properties.Add(_propPerfCounters); _properties.Add(_propSources); _properties.Add(_propSharedListeners); _properties.Add(_propSwitches); _properties.Add(_propTrace); } [ConfigurationProperty("assert")] public AssertSection Assert { get { return (AssertSection) base[_propAssert]; } } [ConfigurationProperty("performanceCounters")] public PerfCounterSection PerfCounters { get { return (PerfCounterSection) base[_propPerfCounters]; } } protected override ConfigurationPropertyCollection Properties { get { return _properties; } } [ConfigurationProperty("sources")] public SourceElementsCollection Sources { get { return (SourceElementsCollection ) base[_propSources]; } } [ConfigurationProperty("sharedListeners")] public ListenerElementsCollection SharedListeners { get { return (ListenerElementsCollection) base[_propSharedListeners]; } } [ConfigurationProperty("switches")] public SwitchElementsCollection Switches { get { return (SwitchElementsCollection) base[_propSwitches]; } } [ConfigurationProperty("trace")] public TraceSection Trace { get { return (TraceSection) base[_propTrace]; } } protected override void InitializeDefault() { Trace.Listeners.InitializeDefaultInternal(); } } } // 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
- WebPart.cs
- XmlSchemaElement.cs
- RetrieveVirtualItemEventArgs.cs
- XPathException.cs
- LexicalChunk.cs
- MetricEntry.cs
- PrintingPermissionAttribute.cs
- QilName.cs
- MetadataPropertyvalue.cs
- DeclarationUpdate.cs
- RankException.cs
- PersonalizationProviderHelper.cs
- WindowsHyperlink.cs
- DetailsViewDeletedEventArgs.cs
- ListChangedEventArgs.cs
- TransactionBehavior.cs
- SqlTypeSystemProvider.cs
- SqlUDTStorage.cs
- ListControl.cs
- EdmMember.cs
- ListViewItemMouseHoverEvent.cs
- CharUnicodeInfo.cs
- IDataContractSurrogate.cs
- WebPartMenuStyle.cs
- TextFormatterHost.cs
- FormViewDeleteEventArgs.cs
- WebEvents.cs
- Point4DConverter.cs
- CompiledIdentityConstraint.cs
- IndexingContentUnit.cs
- CodeTypeDeclarationCollection.cs
- SymLanguageType.cs
- MarkupCompiler.cs
- StoryFragments.cs
- Profiler.cs
- RemoteArgument.cs
- RadioButtonBaseAdapter.cs
- TypeConverter.cs
- CodeAttachEventStatement.cs
- XmlIgnoreAttribute.cs
- XmlNamedNodeMap.cs
- WebPageTraceListener.cs
- QueryParameter.cs
- WindowExtensionMethods.cs
- FormatException.cs
- Menu.cs
- SslStream.cs
- DateTimeOffset.cs
- HtmlInputPassword.cs
- TextTreeNode.cs
- TypeDefinition.cs
- ZoneLinkButton.cs
- XmlFileEditor.cs
- XmlTextWriter.cs
- ipaddressinformationcollection.cs
- Models.cs
- TypeDefinition.cs
- DataServiceRequestOfT.cs
- ControlBuilderAttribute.cs
- ObjectStateManagerMetadata.cs
- TypefaceCollection.cs
- xmlsaver.cs
- RequestNavigateEventArgs.cs
- X509ChainElement.cs
- SrgsOneOf.cs
- ByeOperation11AsyncResult.cs
- InfoCardSymmetricAlgorithm.cs
- LineServicesRun.cs
- FontInfo.cs
- Expression.cs
- ColumnReorderedEventArgs.cs
- EventData.cs
- ObjectParameterCollection.cs
- AutomationPatternInfo.cs
- GlobalEventManager.cs
- MdiWindowListItemConverter.cs
- NativeMethods.cs
- ToggleButtonAutomationPeer.cs
- TextParagraph.cs
- ContextMenuService.cs
- EdmConstants.cs
- ConfigXmlElement.cs
- CheckBoxBaseAdapter.cs
- XamlTreeBuilder.cs
- SafeBitVector32.cs
- TrackingWorkflowEventArgs.cs
- RankException.cs
- TextSearch.cs
- StateChangeEvent.cs
- MulticastDelegate.cs
- XPathBinder.cs
- FontInfo.cs
- System.Data_BID.cs
- LassoSelectionBehavior.cs
- VsPropertyGrid.cs
- ServiceReference.cs
- MenuItemStyle.cs
- BamlLocalizationDictionary.cs
- TransformedBitmap.cs
- PixelShader.cs