Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / Core / System / Diagnostics / Eventing / EventDescriptor.cs / 1305376 / EventDescriptor.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- using System; using System.Runtime.InteropServices; using System.Diagnostics.CodeAnalysis; namespace System.Diagnostics.Eventing { [StructLayout(LayoutKind.Explicit, Size = 16)] [System.Security.Permissions.HostProtection(MayLeakOnAbort = true)] public struct EventDescriptor { [FieldOffset(0)] private ushort m_id; [FieldOffset(2)] private byte m_version; [FieldOffset(3)] private byte m_channel; [FieldOffset(4)] private byte m_level; [FieldOffset(5)] private byte m_opcode; [FieldOffset(6)] private ushort m_task; [FieldOffset(8)] private long m_keywords; [SuppressMessage("Microsoft.Naming", "CA1702:CompoundWordsShouldBeCasedCorrectly", MessageId = "opcode", Justification = "[....]: Shipped public in 3.5, breaking change to fix now.")] public EventDescriptor( int id, byte version, byte channel, byte level, byte opcode, int task, long keywords ) { if (id < 0) { throw new ArgumentOutOfRangeException("id", SR.GetString(SR.ArgumentOutOfRange_NeedNonNegNum)); } if (id > ushort.MaxValue) { throw new ArgumentOutOfRangeException("id", SR.GetString(SR.ArgumentOutOfRange_NeedValidId, 1, ushort.MaxValue)); } m_id = (ushort)id; m_version = version; m_channel = channel; m_level = level; m_opcode = opcode; m_keywords = keywords; if (task < 0) { throw new ArgumentOutOfRangeException("task", SR.GetString(SR.ArgumentOutOfRange_NeedNonNegNum)); } if (task > ushort.MaxValue) { throw new ArgumentOutOfRangeException("task", SR.GetString(SR.ArgumentOutOfRange_NeedValidId, 1, ushort.MaxValue)); } m_task = (ushort)task; } public int EventId { get { return m_id; } } public byte Version { get { return m_version; } } public byte Channel { get { return m_channel; } } public byte Level { get { return m_level; } } [SuppressMessage("Microsoft.Naming", "CA1702:CompoundWordsShouldBeCasedCorrectly", MessageId = "Opcode", Justification = "[....]: Shipped public in 3.5, breaking change to fix now.")] public byte Opcode { get { return m_opcode; } } public int Task { get { return m_task; } } public long Keywords { get { return m_keywords; } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007.
Link Menu
![Network programming in C#, Network Programming in VB.NET, Network Programming in .NET](/images/book.jpg)
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- Rights.cs
- AssertFilter.cs
- AutoGeneratedField.cs
- SqlDelegatedTransaction.cs
- MsmqHostedTransportManager.cs
- DbProviderSpecificTypePropertyAttribute.cs
- DateTimeSerializationSection.cs
- UpdatePanelTriggerCollection.cs
- HttpCapabilitiesEvaluator.cs
- Code.cs
- KeyConstraint.cs
- MailHeaderInfo.cs
- ContainerSelectorGlyph.cs
- TextAction.cs
- IsolationInterop.cs
- SecurityDocument.cs
- HighContrastHelper.cs
- CommandEventArgs.cs
- Crypto.cs
- KernelTypeValidation.cs
- SqlBuilder.cs
- QilFactory.cs
- PageTextBox.cs
- OperatingSystemVersionCheck.cs
- SrgsElementFactoryCompiler.cs
- XsdBuildProvider.cs
- UniqueCodeIdentifierScope.cs
- sqlinternaltransaction.cs
- TextInfo.cs
- JsonMessageEncoderFactory.cs
- DeferrableContent.cs
- TemplateInstanceAttribute.cs
- RawStylusInputCustomDataList.cs
- CompressStream.cs
- MetadataItemCollectionFactory.cs
- BufferedGraphicsManager.cs
- SchemaElementDecl.cs
- ApplicationCommands.cs
- iisPickupDirectory.cs
- PersonalizationStateInfoCollection.cs
- EncodingNLS.cs
- App.cs
- DataListItem.cs
- ScriptingJsonSerializationSection.cs
- SessionIDManager.cs
- TogglePattern.cs
- TypeCollectionDesigner.xaml.cs
- MetadataProperty.cs
- BuildResultCache.cs
- UmAlQuraCalendar.cs
- HtmlTableRowCollection.cs
- counter.cs
- GridViewEditEventArgs.cs
- diagnosticsswitches.cs
- MultidimensionalArrayItemReference.cs
- WindowsTitleBar.cs
- FileDialogCustomPlacesCollection.cs
- TypeConverterHelper.cs
- ControlOperationBehavior.cs
- Scheduler.cs
- RijndaelManagedTransform.cs
- ChannelManager.cs
- OdbcUtils.cs
- Compiler.cs
- XmlNodeReader.cs
- DiagnosticTraceSource.cs
- DesignBindingPicker.cs
- DataSysAttribute.cs
- _LocalDataStoreMgr.cs
- StreamingContext.cs
- Glyph.cs
- PageContentAsyncResult.cs
- RectAnimationClockResource.cs
- WCFModelStrings.Designer.cs
- nulltextnavigator.cs
- XmlSchemas.cs
- UnsignedPublishLicense.cs
- Material.cs
- SystemKeyConverter.cs
- GB18030Encoding.cs
- DataGridViewCellCancelEventArgs.cs
- PropertyPathConverter.cs
- _ChunkParse.cs
- AlternationConverter.cs
- ResourcePermissionBaseEntry.cs
- PrimitiveXmlSerializers.cs
- SqlClientFactory.cs
- XmlEncoding.cs
- SchemaEntity.cs
- BitmapScalingModeValidation.cs
- SettingsProperty.cs
- TrustLevel.cs
- OLEDB_Util.cs
- XmlReaderSettings.cs
- XPathItem.cs
- AppSettings.cs
- ClientFormsIdentity.cs
- BufferModesCollection.cs
- LineServicesRun.cs
- GraphicsContainer.cs