Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / Services / Monitoring / system / Diagnosticts / EventData.cs / 1305376 / EventData.cs
using System.ComponentModel; using System.Security.Permissions; using System.Security; namespace System.Diagnostics { public class EventInstance { private int _categoryNumber; private EventLogEntryType _entryType = EventLogEntryType.Information; private long _instanceId; public EventInstance(long instanceId, int categoryId) { CategoryId = categoryId; InstanceId = instanceId; } public EventInstance(long instanceId, int categoryId, EventLogEntryType entryType) : this (instanceId, categoryId) { EntryType = entryType; } public int CategoryId { get { return _categoryNumber; } set { if (value > UInt16.MaxValue || value < 0) throw new ArgumentOutOfRangeException("value"); _categoryNumber = value; } } public EventLogEntryType EntryType { get { return _entryType; } set { if (!Enum.IsDefined(typeof(EventLogEntryType), value)) throw new InvalidEnumArgumentException("value", (int)value, typeof(EventLogEntryType)); _entryType = value; } } public long InstanceId { get { return _instanceId; } set { if (value > UInt32.MaxValue || value < 0) throw new ArgumentOutOfRangeException("value"); _instanceId = value; } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved.
Link Menu

This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- AttachedAnnotation.cs
- ReadOnlyActivityGlyph.cs
- TagMapInfo.cs
- ListViewItem.cs
- SqlVisitor.cs
- ReplyChannelBinder.cs
- DummyDataSource.cs
- CompoundFileStorageReference.cs
- XmlDocumentFragment.cs
- WizardPanelChangingEventArgs.cs
- ModuleConfigurationInfo.cs
- CustomPopupPlacement.cs
- TreeNode.cs
- DataObject.cs
- ToolStripLabel.cs
- PropertyGridView.cs
- FileChangesMonitor.cs
- FixedPageAutomationPeer.cs
- XappLauncher.cs
- RuleConditionDialog.cs
- DefaultTraceListener.cs
- DropSource.cs
- Native.cs
- ProfileGroupSettings.cs
- UMPAttributes.cs
- ValueUnavailableException.cs
- PenLineJoinValidation.cs
- Point3DCollection.cs
- HtmlSelect.cs
- ObjectViewListener.cs
- cookieexception.cs
- safesecurityhelperavalon.cs
- Timer.cs
- HatchBrush.cs
- MenuItemAutomationPeer.cs
- LiteralControl.cs
- SimpleWebHandlerParser.cs
- ComNativeDescriptor.cs
- ToolboxItemLoader.cs
- PropertyGeneratedEventArgs.cs
- RootBuilder.cs
- XmlSchemaSimpleTypeList.cs
- TagPrefixCollection.cs
- RegexCaptureCollection.cs
- MobileControlsSectionHelper.cs
- TypedDatasetGenerator.cs
- HwndSourceKeyboardInputSite.cs
- ListViewGroupItemCollection.cs
- ServiceChannel.cs
- HttpCookieCollection.cs
- OrderByQueryOptionExpression.cs
- ImportException.cs
- ToolStripMenuItem.cs
- LocalBuilder.cs
- MouseBinding.cs
- DoubleCollection.cs
- TextAutomationPeer.cs
- OledbConnectionStringbuilder.cs
- ValueHandle.cs
- ThreadPool.cs
- XhtmlTextWriter.cs
- SerializationFieldInfo.cs
- ExpressionBuilder.cs
- DesignTimeXamlWriter.cs
- SizeF.cs
- Vector3D.cs
- NetworkCredential.cs
- XmlnsCache.cs
- ConditionChanges.cs
- Rules.cs
- StringReader.cs
- AuthenticationService.cs
- PassportPrincipal.cs
- AuthenticodeSignatureInformation.cs
- ColumnClickEvent.cs
- CoTaskMemHandle.cs
- XmlUnspecifiedAttribute.cs
- SslStream.cs
- DesignTimeParseData.cs
- XpsFilter.cs
- ColorConvertedBitmap.cs
- TableLayoutSettingsTypeConverter.cs
- DeferredElementTreeState.cs
- UpdateExpressionVisitor.cs
- altserialization.cs
- DataTableTypeConverter.cs
- PublisherIdentityPermission.cs
- MinimizableAttributeTypeConverter.cs
- GlyphTypeface.cs
- ChannelListenerBase.cs
- _UncName.cs
- ValuePattern.cs
- ChannelToken.cs
- WebPart.cs
- DiscriminatorMap.cs
- DefaultWorkflowLoaderService.cs
- ComponentResourceKey.cs
- WeakReferenceList.cs
- DispatcherExceptionFilterEventArgs.cs
- WebSysDefaultValueAttribute.cs