PostSharp6.2/API Reference/Post­Sharp.​Patterns.​Diagnostics Namespace/Logger Class/Logger Methods/Logger.​Open­Activity Method/Logger.​Open­Activity(T1) Method (String, T1)

Logger.OpenActivity<T1> Method (String, T1)

Opens a custom activity with a description containing 1 parameter.

Namespace:  PostSharp.Patterns.Diagnostics
Assembly:  PostSharp.Patterns.Common (in PostSharp.Patterns.Common.dll) Version: 6.2.13.0 (6.2.13.0)
Syntax
C#
public LogActivity OpenActivity<T1>(
	string formattingString,
	T1 arg1
)

Parameters

formattingString
Type: System.String
The description of the activity, including parameters (e.g. Writing {LineCount} line(s) in file {Path}).
arg1
Type: T1
Value of the first parameter.

Type Parameters

T1
Type of the first parameter.

Return Value

Type: LogActivity
A Logger representing the new activity.
Remarks
The activity must be closed using SetSuccess(String), SetFailure(String) or SetException(Exception).
See Also