Code:
/ Dotnetfx_Win7_3.5.1 / Dotnetfx_Win7_3.5.1 / 3.5.1 / DEVDIV / depot / DevDiv / releases / whidbey / NetFXspW7 / ndp / fx / src / CompMod / System / Diagnostics / SeverityFilter.cs / 1 / SeverityFilter.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- using System; namespace System.Diagnostics { public class EventTypeFilter : TraceFilter { private SourceLevels level; public EventTypeFilter(SourceLevels level) { this.level = level; } public override bool ShouldTrace(TraceEventCache cache, string source, TraceEventType eventType, int id, string formatOrMessage, object[] args, object data1, object[] data) { return ((int) eventType & (int) level) != 0; } public SourceLevels EventType { get { return level; } set { level = value; } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- using System; namespace System.Diagnostics { public class EventTypeFilter : TraceFilter { private SourceLevels level; public EventTypeFilter(SourceLevels level) { this.level = level; } public override bool ShouldTrace(TraceEventCache cache, string source, TraceEventType eventType, int id, string formatOrMessage, object[] args, object data1, object[] data) { return ((int) eventType & (int) level) != 0; } public SourceLevels EventType { get { return level; } set { level = value; } } } } // 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
- XmlAttribute.cs
- NoneExcludedImageIndexConverter.cs
- URIFormatException.cs
- RuntimeTrackingProfile.cs
- MessagePropertyDescriptionCollection.cs
- OneToOneMappingSerializer.cs
- CharacterString.cs
- ArrayElementGridEntry.cs
- MasterPageBuildProvider.cs
- DependencyProperty.cs
- PrintPreviewControl.cs
- WSUtilitySpecificationVersion.cs
- SessionSwitchEventArgs.cs
- PKCS1MaskGenerationMethod.cs
- Tag.cs
- MobileControlDesigner.cs
- MruCache.cs
- ToolStripSeparatorRenderEventArgs.cs
- WindowsHyperlink.cs
- SoapIncludeAttribute.cs
- entitydatasourceentitysetnameconverter.cs
- HyperLink.cs
- Translator.cs
- Properties.cs
- DataGridViewRowErrorTextNeededEventArgs.cs
- AccessViolationException.cs
- DeclarativeConditionsCollection.cs
- UIPermission.cs
- RuntimeHelpers.cs
- PeerContact.cs
- SimpleHandlerFactory.cs
- BStrWrapper.cs
- CalendarAutoFormat.cs
- PolicyManager.cs
- WizardStepBase.cs
- DeviceOverridableAttribute.cs
- RouteItem.cs
- UnsafeNetInfoNativeMethods.cs
- XmlSignatureManifest.cs
- JsonXmlDataContract.cs
- ApplicationGesture.cs
- AssemblyBuilderData.cs
- QilDataSource.cs
- MetadataUtilsSmi.cs
- XmlSerializationGeneratedCode.cs
- SrgsSubset.cs
- AnnouncementEventArgs.cs
- LinqDataSourceContextData.cs
- ViewLoader.cs
- ProfileManager.cs
- DataAdapter.cs
- PropertyToken.cs
- DataControlCommands.cs
- Binding.cs
- FunctionDescription.cs
- HostProtectionPermission.cs
- SequenceDesigner.xaml.cs
- sortedlist.cs
- SizeAnimation.cs
- XmlKeywords.cs
- DataGridSortCommandEventArgs.cs
- PerformanceCountersElement.cs
- ActiveXHelper.cs
- HandleRef.cs
- DataGridViewCellEventArgs.cs
- iisPickupDirectory.cs
- ISCIIEncoding.cs
- Expander.cs
- Brush.cs
- LoadWorkflowByKeyAsyncResult.cs
- BamlCollectionHolder.cs
- CommaDelimitedStringAttributeCollectionConverter.cs
- TemplateInstanceAttribute.cs
- SkinBuilder.cs
- ITreeGenerator.cs
- TypeSystemHelpers.cs
- XPathArrayIterator.cs
- SqlGatherProducedAliases.cs
- ExtractCollection.cs
- ToolStripPanel.cs
- InvalidDataException.cs
- MonthChangedEventArgs.cs
- DatatypeImplementation.cs
- CommandValueSerializer.cs
- Win32Interop.cs
- UIElement.cs
- CodeSnippetExpression.cs
- WebBrowsableAttribute.cs
- TextDecorationCollection.cs
- COM2ColorConverter.cs
- TypeDescriptor.cs
- WebPartVerb.cs
- RegistrationServices.cs
- TreeViewCancelEvent.cs
- HebrewCalendar.cs
- SrgsSubset.cs
- METAHEADER.cs
- JsonObjectDataContract.cs
- DataServiceQuery.cs
- ColorMap.cs