Class LogActivity<TActivityDescription>
Represents a logged custom activity, i.e. something that has a beginning and an end with a specific outcome.
This class is instantiated by the new API of the LogSource class.
Inheritance
LogActivity<TActivityDescription>
Assembly: PostSharp.Patterns.Common.dll
Syntax
[RequirePostSharp("PostSharp.Patterns.Common.Weaver", "AddCallerInfoTask", AnyTypeReference = true)]
public sealed class LogActivity<TActivityDescription> : ValueType, ILogActivity where TActivityDescription : IMessage
Type Parameters
Name |
Description |
TActivityDescription |
|
Properties
Methods
Name |
Description |
Dispose()
|
Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.
|
Resume()
|
Resumes the current async activity after it has been suspended by a call to Suspend(). There is typically no need
to invoke this method in user code because all async methods that use the Logger class are automatically instrumented.
|
Resume(ref CallerInfo)
|
|
SetException(Exception, in CloseActivityOptions)
|
|
SetException(Exception, in CloseActivityOptions, ref CallerInfo)
|
|
SetOutcome<TMessage>(LogLevel, in TMessage, Exception, in CloseActivityOptions)
|
|
SetOutcome<TMessage>(LogLevel, in TMessage, Exception, in CloseActivityOptions, ref CallerInfo)
|
|
SetResult<TResult>(TResult, in CloseActivityOptions)
|
|
SetResult<TResult>(TResult, in CloseActivityOptions, ref CallerInfo)
|
|
SetSuccess(in CloseActivityOptions)
|
|
SetSuccess(in CloseActivityOptions, ref CallerInfo)
|
|
Suspend()
|
Suspends the current async activity.
The activity must than be resumed by a call of the Resume() method.
There is typically no need to invoke this method in user code because all async methods that use the Logger class are automatically instrumented.
|
Suspend(ref CallerInfo)
|
|
Explicit Interface Implementations
Name |
Description |
ILogActivity.SetException(Exception, in CloseActivityOptions)
|
|
ILogActivity.SetException(Exception, in CloseActivityOptions, ref CallerInfo)
|
|
ILogActivity.SetOutcome<TMessage>(LogLevel, in TMessage, Exception, in CloseActivityOptions)
|
|
ILogActivity.SetOutcome<TMessage>(LogLevel, in TMessage, Exception, in CloseActivityOptions, ref CallerInfo)
|
|
ILogActivity.SetResult<TResult>(TResult, in CloseActivityOptions)
|
|
ILogActivity.SetResult<TResult>(TResult, in CloseActivityOptions, ref CallerInfo)
|
|
ILogActivity.SetSuccess(in CloseActivityOptions)
|
|
ILogActivity.SetSuccess(in CloseActivityOptions, ref CallerInfo)
|
|