Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / Core / System / Diagnostics / Eventing / Reader / EventBookmark.cs / 1305376 / EventBookmark.cs
// ==++== // // Copyright (c) Microsoft Corporation. All rights reserved. // // ==--== /*============================================================ ** ** Class: EventBookmark ** ** Purpose: ** This public class represents an opaque Event Bookmark obtained ** from an EventRecord. The bookmark denotes a unique identifier ** for the event instance as well as marks the location in the ** the result set of the EventReader that the event instance was ** obtained from. ** ============================================================*/ using System.Runtime.InteropServices; using System.Security.Permissions; using System.Runtime.Serialization; namespace System.Diagnostics.Eventing.Reader { // // NOTE: This class must be generic enough to be used across // eventing base implementations. Cannot add anything // that ties it to one particular implementation. // ////// Represents an opaque Event Bookmark obtained from an EventRecord. /// The bookmark denotes a unique identifier for the event instance as /// well as marks the location in the the result set of the EventReader /// that the event instance was obtained from. /// [Serializable] [System.Security.Permissions.HostProtection(MayLeakOnAbort = true)] public class EventBookmark : ISerializable { string bookmark; internal EventBookmark(string bookmarkText) { if (bookmarkText == null) throw new ArgumentNullException("bookmarkText"); this.bookmark = bookmarkText; } protected EventBookmark(SerializationInfo info, StreamingContext context) { if (info == null) throw new ArgumentNullException("info"); this.bookmark = info.GetString("BookmarkText"); } // SecurityCritical due to inherited link demand for GetObjectData. [System.Security.SecurityCritical,SecurityPermissionAttribute(SecurityAction.LinkDemand,Flags = SecurityPermissionFlag.SerializationFormatter)] void ISerializable.GetObjectData(SerializationInfo info, StreamingContext context) { GetObjectData( info, context ); } // SecurityCritical due to inherited link demand for GetObjectData. [System.Security.SecurityCritical,SecurityPermissionAttribute(SecurityAction.LinkDemand, Flags = SecurityPermissionFlag.SerializationFormatter)] protected virtual void GetObjectData(SerializationInfo info, StreamingContext context) { if (info == null) throw new ArgumentNullException("info"); info.AddValue("BookmarkText", this.bookmark); } internal string BookmarkText { get { return bookmark; } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // ==++== // // Copyright (c) Microsoft Corporation. All rights reserved. // // ==--== /*============================================================ ** ** Class: EventBookmark ** ** Purpose: ** This public class represents an opaque Event Bookmark obtained ** from an EventRecord. The bookmark denotes a unique identifier ** for the event instance as well as marks the location in the ** the result set of the EventReader that the event instance was ** obtained from. ** ============================================================*/ using System.Runtime.InteropServices; using System.Security.Permissions; using System.Runtime.Serialization; namespace System.Diagnostics.Eventing.Reader { // // NOTE: This class must be generic enough to be used across // eventing base implementations. Cannot add anything // that ties it to one particular implementation. // ////// Represents an opaque Event Bookmark obtained from an EventRecord. /// The bookmark denotes a unique identifier for the event instance as /// well as marks the location in the the result set of the EventReader /// that the event instance was obtained from. /// [Serializable] [System.Security.Permissions.HostProtection(MayLeakOnAbort = true)] public class EventBookmark : ISerializable { string bookmark; internal EventBookmark(string bookmarkText) { if (bookmarkText == null) throw new ArgumentNullException("bookmarkText"); this.bookmark = bookmarkText; } protected EventBookmark(SerializationInfo info, StreamingContext context) { if (info == null) throw new ArgumentNullException("info"); this.bookmark = info.GetString("BookmarkText"); } // SecurityCritical due to inherited link demand for GetObjectData. [System.Security.SecurityCritical,SecurityPermissionAttribute(SecurityAction.LinkDemand,Flags = SecurityPermissionFlag.SerializationFormatter)] void ISerializable.GetObjectData(SerializationInfo info, StreamingContext context) { GetObjectData( info, context ); } // SecurityCritical due to inherited link demand for GetObjectData. [System.Security.SecurityCritical,SecurityPermissionAttribute(SecurityAction.LinkDemand, Flags = SecurityPermissionFlag.SerializationFormatter)] protected virtual void GetObjectData(SerializationInfo info, StreamingContext context) { if (info == null) throw new ArgumentNullException("info"); info.AddValue("BookmarkText", this.bookmark); } internal string BookmarkText { get { return bookmark; } } } } // 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
- TextProperties.cs
- CompilerTypeWithParams.cs
- NativeCompoundFileAPIs.cs
- DataTable.cs
- XmlSchemas.cs
- CompilerParameters.cs
- MorphHelper.cs
- InspectionWorker.cs
- EntityClassGenerator.cs
- ServiceContractListItemList.cs
- IndependentAnimationStorage.cs
- MenuTracker.cs
- WeakRefEnumerator.cs
- AdjustableArrowCap.cs
- FileAuthorizationModule.cs
- WindowsAuthenticationEventArgs.cs
- RuleSettings.cs
- EncoderNLS.cs
- CalendarAutoFormatDialog.cs
- DataMemberFieldConverter.cs
- DefaultAssemblyResolver.cs
- StylusCaptureWithinProperty.cs
- Focus.cs
- SerializationInfoEnumerator.cs
- ToolStripContentPanel.cs
- ReferencedAssembly.cs
- SingleAnimationBase.cs
- PostBackOptions.cs
- DiagnosticTraceSource.cs
- wgx_exports.cs
- Activator.cs
- GridErrorDlg.cs
- ConfigurationValue.cs
- isolationinterop.cs
- ElementUtil.cs
- XmlSchemaSet.cs
- StylusDownEventArgs.cs
- WindowsGraphics.cs
- ValueUtilsSmi.cs
- MetadataItem_Static.cs
- ParagraphResult.cs
- WebBrowserHelper.cs
- KeyValuePair.cs
- HwndSubclass.cs
- EdmProviderManifest.cs
- DataGridPagerStyle.cs
- ImageClickEventArgs.cs
- DataColumnCollection.cs
- TextDpi.cs
- QuaternionRotation3D.cs
- HelloMessageApril2005.cs
- RegistrationServices.cs
- translator.cs
- ZoomPercentageConverter.cs
- HostProtectionPermission.cs
- input.cs
- XmlSignatureProperties.cs
- TextBlockAutomationPeer.cs
- streamingZipPartStream.cs
- SqlXml.cs
- DataObjectPastingEventArgs.cs
- SqlNotificationEventArgs.cs
- X509PeerCertificateAuthentication.cs
- ToolStripSettings.cs
- AnimatedTypeHelpers.cs
- WebPartZoneBase.cs
- SoapMessage.cs
- NumberFormatInfo.cs
- ListViewGroupItemCollection.cs
- DocumentPageHost.cs
- AttachedPropertyMethodSelector.cs
- Line.cs
- TileBrush.cs
- HostVisual.cs
- DataGridViewCellFormattingEventArgs.cs
- InvalidAsynchronousStateException.cs
- ObjectQuery_EntitySqlExtensions.cs
- AdRotatorDesigner.cs
- XamlHostingConfiguration.cs
- SymbolType.cs
- StrokeCollectionDefaultValueFactory.cs
- MetroSerializationManager.cs
- OuterGlowBitmapEffect.cs
- CacheChildrenQuery.cs
- DoubleLinkListEnumerator.cs
- TreeView.cs
- DataGridViewColumnStateChangedEventArgs.cs
- FactoryRecord.cs
- PageHandlerFactory.cs
- UnsafeNativeMethodsMilCoreApi.cs
- RequestCacheManager.cs
- Operand.cs
- AspNetSynchronizationContext.cs
- XPathAxisIterator.cs
- DBSqlParserTable.cs
- FontFamilyIdentifier.cs
- DataViewSettingCollection.cs
- GradientStop.cs
- HyperLink.cs
- ActivationServices.cs