Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / Core / System / Diagnostics / Eventing / Reader / EventLogQuery.cs / 1305376 / EventLogQuery.cs
// ==++== // // Copyright (c) Microsoft Corporation. All rights reserved. // // ==--== /*============================================================ ** ** Class: EventLogQuery ** ** Purpose: ** This public class allows a user to define events of interest. ** An instance of this class is passed to an EventReader to actually ** obtain the EventRecords. The EventLogQuery can be as ** simple specifying that all events are of interest, or it can contain ** query / xpath expressions that indicate exactly what characteristics ** events should have. ** ============================================================*/ using System; using System.Collections.Generic; using System.Runtime.InteropServices; namespace System.Diagnostics.Eventing.Reader { ////// Allows a user to define events of interest. An instance of this /// class is passed to an EventReader to actually obtain the EventRecords. /// The EventLogQuery can be as simple specifying that all events are of /// interest, or it can contain query / xpath expressions that indicate exactly /// what characteristics events should have. /// public class EventLogQuery { private string query; private string path; private EventLogSession session; private PathType pathType; private bool tolerateErrors = false; private bool reverseDirection = false; public EventLogQuery(string path, PathType pathType) : this(path, pathType, null) { } public EventLogQuery(string path, PathType pathType, string query) { this.session = EventLogSession.GlobalSession; this.path = path; // can be null this.pathType = pathType; if (query == null) { if (path == null) throw new ArgumentNullException("path"); } else { this.query = query; } } public EventLogSession Session { get { return this.session; } set { this.session = value; } } public bool TolerateQueryErrors { get { return this.tolerateErrors; } set { this.tolerateErrors = value; } } public bool ReverseDirection { get { return this.reverseDirection; } set { this.reverseDirection = value; } } internal string Path { get { return this.path; } } internal PathType ThePathType { get { return this.pathType; } } internal string Query { get { return this.query; } } } } // 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
- NavigationWindowAutomationPeer.cs
- StyleSheet.cs
- RawUIStateInputReport.cs
- TransactionException.cs
- ComponentFactoryHelpers.cs
- XmlnsCompatibleWithAttribute.cs
- SqlClientFactory.cs
- AssertFilter.cs
- BasicHttpMessageSecurityElement.cs
- SecurityManager.cs
- WebPartAddingEventArgs.cs
- FormsAuthenticationEventArgs.cs
- HtmlInputSubmit.cs
- FixedHighlight.cs
- DesignTimeTemplateParser.cs
- ItemCollection.cs
- Configuration.cs
- ConfigXmlElement.cs
- WpfPayload.cs
- FieldBuilder.cs
- MethodRental.cs
- PublishLicense.cs
- GeometryHitTestParameters.cs
- GridViewCancelEditEventArgs.cs
- ProfileGroupSettings.cs
- XmlAttributeCache.cs
- ExpressionEditor.cs
- PrivilegedConfigurationManager.cs
- View.cs
- TextRunCacheImp.cs
- QueryOperationResponseOfT.cs
- ComponentChangingEvent.cs
- BrowserTree.cs
- KeyTimeConverter.cs
- GregorianCalendar.cs
- MetaType.cs
- DescendantOverDescendantQuery.cs
- PersonalizationProviderHelper.cs
- FullTextState.cs
- TitleStyle.cs
- FilterableAttribute.cs
- FieldAccessException.cs
- HtmlInputReset.cs
- pingexception.cs
- ValueType.cs
- BrowserCapabilitiesCodeGenerator.cs
- CryptoKeySecurity.cs
- Visual.cs
- RootProjectionNode.cs
- ConfigXmlWhitespace.cs
- XmlQueryContext.cs
- XmlQualifiedName.cs
- FixUpCollection.cs
- mediaclock.cs
- SQLGuid.cs
- QueryStack.cs
- DataSourceControl.cs
- HtmlInputCheckBox.cs
- XmlResolver.cs
- SqlDataSourceSelectingEventArgs.cs
- PackagingUtilities.cs
- ConnectionConsumerAttribute.cs
- ContextMenu.cs
- HttpPostClientProtocol.cs
- StickyNoteHelper.cs
- PointAnimationUsingPath.cs
- TransactionManager.cs
- EdmError.cs
- Array.cs
- SupportsEventValidationAttribute.cs
- Regex.cs
- DataGridHyperlinkColumn.cs
- documentsequencetextview.cs
- BinaryUtilClasses.cs
- ConfigurationException.cs
- ResolveMatchesMessage11.cs
- FixedTextContainer.cs
- DataChangedEventManager.cs
- JsonServiceDocumentSerializer.cs
- HtmlInputSubmit.cs
- PopupRoot.cs
- DataGridColumn.cs
- DataGridParentRows.cs
- ResourceSet.cs
- TextParaClient.cs
- JournalEntry.cs
- RoleManagerEventArgs.cs
- Transform3DCollection.cs
- GenericsInstances.cs
- DirectionalLight.cs
- ECDiffieHellmanCng.cs
- RegexWorker.cs
- DeflateEmulationStream.cs
- Vector3DIndependentAnimationStorage.cs
- Knowncolors.cs
- DataControlImageButton.cs
- SignedXmlDebugLog.cs
- Enlistment.cs
- NativeMethods.cs
- GatewayIPAddressInformationCollection.cs