Code:
/ Dotnetfx_Vista_SP2 / Dotnetfx_Vista_SP2 / 8.0.50727.4016 / DEVDIV / depot / DevDiv / releases / whidbey / NetFxQFE / ndp / fx / src / CompMod / System / Diagnostics / SourceFilter.cs / 1 / SourceFilter.cs
//------------------------------------------------------------------------------
//
// Copyright (c) Microsoft Corporation. All rights reserved.
//
//-----------------------------------------------------------------------------
using System;
using System.Collections;
namespace System.Diagnostics {
public class SourceFilter : TraceFilter {
private string src;
public SourceFilter(string source) {
Source = source;
}
public override bool ShouldTrace(TraceEventCache cache, string source, TraceEventType eventType, int id, string formatOrMessage,
object[] args, object data1, object[] data) {
if (source == null)
throw new ArgumentNullException("source");
return String.Equals(src, source);
}
public String Source {
get {
return src;
}
set {
if (value == null)
throw new ArgumentNullException("source");
src = value;
}
}
}
}
// File provided for Reference Use Only by Microsoft Corporation (c) 2007.
//------------------------------------------------------------------------------
//
// Copyright (c) Microsoft Corporation. All rights reserved.
//
//-----------------------------------------------------------------------------
using System;
using System.Collections;
namespace System.Diagnostics {
public class SourceFilter : TraceFilter {
private string src;
public SourceFilter(string source) {
Source = source;
}
public override bool ShouldTrace(TraceEventCache cache, string source, TraceEventType eventType, int id, string formatOrMessage,
object[] args, object data1, object[] data) {
if (source == null)
throw new ArgumentNullException("source");
return String.Equals(src, source);
}
public String Source {
get {
return src;
}
set {
if (value == null)
throw new ArgumentNullException("source");
src = 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
- DataSetMappper.cs
- SqlBulkCopyColumnMapping.cs
- VirtualPathExtension.cs
- ProfileServiceManager.cs
- LifetimeManager.cs
- ComplexBindingPropertiesAttribute.cs
- SyndicationSerializer.cs
- CellPartitioner.cs
- CallSiteBinder.cs
- Simplifier.cs
- ImageCollectionEditor.cs
- TimeoutValidationAttribute.cs
- GeneralTransform3DCollection.cs
- ZipIOZip64EndOfCentralDirectoryLocatorBlock.cs
- EntityDataSourceStatementEditorForm.cs
- XmlSigningNodeWriter.cs
- LocationUpdates.cs
- ExpressionStringBuilder.cs
- WebPartCloseVerb.cs
- FixedNode.cs
- OdbcConnectionHandle.cs
- ErrorTableItemStyle.cs
- Base64Encoding.cs
- DeferredBinaryDeserializerExtension.cs
- StdValidatorsAndConverters.cs
- ExpressionVisitor.cs
- DoubleLink.cs
- SystemIPv4InterfaceProperties.cs
- TextParagraphView.cs
- ResourcesBuildProvider.cs
- KeyPressEvent.cs
- EmbeddedMailObject.cs
- XpsSerializerFactory.cs
- ThrowHelper.cs
- MemberMaps.cs
- HMACMD5.cs
- DbUpdateCommandTree.cs
- SamlSecurityToken.cs
- GroupBox.cs
- Tokenizer.cs
- Polyline.cs
- Timer.cs
- ReadingWritingEntityEventArgs.cs
- CorrelationQuery.cs
- rsa.cs
- XmlChildNodes.cs
- UnSafeCharBuffer.cs
- BrowserCapabilitiesFactory.cs
- AddInProcess.cs
- WsdlParser.cs
- SafeCryptHandles.cs
- CommonDialog.cs
- FindResponse.cs
- PerformanceCounterNameAttribute.cs
- DesignerForm.cs
- RegexCaptureCollection.cs
- SystemBrushes.cs
- HttpProfileGroupBase.cs
- XmlRootAttribute.cs
- Nodes.cs
- ErrorRuntimeConfig.cs
- TextTreeInsertUndoUnit.cs
- TrustManagerMoreInformation.cs
- Activator.cs
- TextViewDesigner.cs
- DefaultAssemblyResolver.cs
- shaperfactoryquerycacheentry.cs
- InvokeGenerator.cs
- EventOpcode.cs
- FormsAuthenticationCredentials.cs
- ProcessInputEventArgs.cs
- DesigntimeLicenseContextSerializer.cs
- CompoundFileStorageReference.cs
- CfgRule.cs
- TypedTableBase.cs
- BinaryUtilClasses.cs
- ShutDownListener.cs
- COM2Enum.cs
- ImageList.cs
- TextServicesManager.cs
- WindowsToolbarItemAsMenuItem.cs
- EntityDataSourceValidationException.cs
- SingleObjectCollection.cs
- WsdlHelpGeneratorElement.cs
- DebugHandleTracker.cs
- XsltOutput.cs
- PermissionToken.cs
- Command.cs
- SqlNodeAnnotations.cs
- DynamicValueConverter.cs
- SymLanguageType.cs
- SpecialNameAttribute.cs
- FileInfo.cs
- CaretElement.cs
- WebServiceClientProxyGenerator.cs
- EntityDataReader.cs
- DependencyPropertyValueSerializer.cs
- UIElement.cs
- FixedSOMPage.cs
- RemotingException.cs