Code:
/ DotNET / DotNET / 8.0 / untmp / whidbey / REDBITS / ndp / fx / src / xsp / System / Web / ProcessInfo.cs / 1 / ProcessInfo.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- /* * ProcessInfo class */ namespace System.Web { using System.Threading; using System.Security.Permissions; ////// public enum ProcessStatus { ///Provides enumerated values representing status of a process. ////// Alive = 1, ///Specifies that the process is running. ////// ShuttingDown = 2, ///Specifies that the process has begun shutting down. ////// ShutDown = 3, ///Specifies the the process has been shut down. ////// Terminated = 4 } ///Specifies that the process has been terminated. ////// public enum ProcessShutdownReason { ///Provides enumerated values representing the reason a process has shut /// down. ////// None = 0, // alive ///Specifies that the process has not been shut down. ////// Unexpected = 1, ///Specifies that the process has been shut down unexpectedly. ////// RequestsLimit = 2, ///Specifies that the process request exceeded the limit on number of /// processes. ////// RequestQueueLimit = 3, ///Specifies that the process request exceeded the limit on number of /// processes in que. ////// Timeout = 4, ///Specifies that the process timed out. ////// IdleTimeout = 5, ///Specifies that the process exceeded the limit on process idle time. ////// MemoryLimitExceeded = 6, PingFailed = 7, DeadlockSuspected = 8 } ///Specifies that the process exceeded the limit of memory available per process. ////// [AspNetHostingPermission(SecurityAction.LinkDemand, Level=AspNetHostingPermissionLevel.Minimal)] [AspNetHostingPermission(SecurityAction.InheritanceDemand, Level=AspNetHostingPermissionLevel.Minimal)] public class ProcessInfo { ///Provides information on processes. ////// public DateTime StartTime { get { return _StartTime;}} ///Indicates the time a process was started. ////// public TimeSpan Age { get { return _Age;}} ///Indicates the length of time the process has been running. ////// public int ProcessID { get { return _ProcessID;}} public int RequestCount { get { return _RequestCount;}} ///Indicates the process id of the process. ////// public ProcessStatus Status { get { return _Status;}} ///Indicates the current status of the process. ////// public ProcessShutdownReason ShutdownReason { get { return _ShutdownReason;}} ///Indicates the reason the process shut down. ////// public int PeakMemoryUsed { get { return _PeakMemoryUsed;}} private DateTime _StartTime; private TimeSpan _Age; private int _ProcessID; private int _RequestCount; private ProcessStatus _Status; private ProcessShutdownReason _ShutdownReason; private int _PeakMemoryUsed; ///Indicates the maximum amount of memory the process has used. ////// public void SetAll (DateTime startTime, TimeSpan age, int processID, int requestCount, ProcessStatus status, ProcessShutdownReason shutdownReason, int peakMemoryUsed) { _StartTime = startTime; _Age = age; _ProcessID = processID; _RequestCount = requestCount; _Status = status; _ShutdownReason = shutdownReason; _PeakMemoryUsed = peakMemoryUsed; } ///Sets internal information indicating the status of the process. ////// public ProcessInfo (DateTime startTime, TimeSpan age, int processID, int requestCount, ProcessStatus status, ProcessShutdownReason shutdownReason, int peakMemoryUsed) { _StartTime = startTime; _Age = age; _ProcessID = processID; _RequestCount = requestCount; _Status = status; _ShutdownReason = shutdownReason; _PeakMemoryUsed = peakMemoryUsed; } public ProcessInfo() { } } }Initializes a new instance of the ///class and sets internal information /// indicating the status of the process.
Link Menu

This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- ProviderMetadataCachedInformation.cs
- AuthStoreRoleProvider.cs
- Parser.cs
- SetIterators.cs
- TextModifierScope.cs
- ToolStripPanelCell.cs
- CommandHelper.cs
- Asn1IntegerConverter.cs
- RuleInfoComparer.cs
- SignerInfo.cs
- LineUtil.cs
- ComponentChangedEvent.cs
- PointAnimationUsingKeyFrames.cs
- TrustLevelCollection.cs
- X500Name.cs
- TimeSpan.cs
- ChannelServices.cs
- FlowPosition.cs
- ControlDesigner.cs
- RectangleGeometry.cs
- UnsettableComboBox.cs
- SupportsEventValidationAttribute.cs
- FileStream.cs
- XmlTextReader.cs
- LifetimeServices.cs
- CompilationAssemblyInstallComponent.cs
- DrawItemEvent.cs
- DrawingBrush.cs
- FontWeight.cs
- ErrorFormatterPage.cs
- ACL.cs
- XmlSchemaImporter.cs
- InputMethodStateTypeInfo.cs
- DataKey.cs
- Int64KeyFrameCollection.cs
- Stopwatch.cs
- TypeReference.cs
- DrawingAttributeSerializer.cs
- SQLBoolean.cs
- SpellerError.cs
- SoapSchemaExporter.cs
- BuildDependencySet.cs
- loginstatus.cs
- AnnotationComponentChooser.cs
- Delegate.cs
- CopyNamespacesAction.cs
- Parser.cs
- Graph.cs
- SafeCertificateStore.cs
- QilValidationVisitor.cs
- EncodingInfo.cs
- HtmlEmptyTagControlBuilder.cs
- RIPEMD160.cs
- SerializationObjectManager.cs
- FastPropertyAccessor.cs
- InterleavedZipPartStream.cs
- StyleTypedPropertyAttribute.cs
- ContainerActivationHelper.cs
- TraceHwndHost.cs
- TypeUsageBuilder.cs
- CharacterBuffer.cs
- CommandID.cs
- TableRowCollection.cs
- Font.cs
- CollectionChangeEventArgs.cs
- ContentPresenter.cs
- DataViewSetting.cs
- ToolStripItemTextRenderEventArgs.cs
- ActivityContext.cs
- HandlerFactoryWrapper.cs
- Compiler.cs
- NetworkInterface.cs
- Funcletizer.cs
- FixedSOMPageConstructor.cs
- AssemblyCollection.cs
- TextTreeText.cs
- DesignRelationCollection.cs
- BufferAllocator.cs
- ValidationHelper.cs
- RewritingSimplifier.cs
- login.cs
- Adorner.cs
- StringFunctions.cs
- AtomicFile.cs
- BaseCollection.cs
- SqlMethodAttribute.cs
- TemplateBaseAction.cs
- PropVariant.cs
- ParsedRoute.cs
- WpfKnownTypeInvoker.cs
- CanonicalFormWriter.cs
- Facet.cs
- TitleStyle.cs
- DateTimeUtil.cs
- BulletedList.cs
- LoggedException.cs
- WebConfigurationHost.cs
- SQLInt16Storage.cs
- ListDictionaryInternal.cs
- WebCategoryAttribute.cs