CorrelationManager.StartLogicalOperation 메서드

정의

스레드에서 논리 작업을 시작합니다.

오버로드

StartLogicalOperation()

스레드에서 논리 작업을 시작합니다.

StartLogicalOperation(Object)

스레드에서 지정된 ID를 사용하여 논리 작업을 시작합니다.

StartLogicalOperation()

Source:
CorrelationManager.cs
Source:
CorrelationManager.cs
Source:
CorrelationManager.cs

스레드에서 논리 작업을 시작합니다.

public:
 void StartLogicalOperation();
public void StartLogicalOperation ();
member this.StartLogicalOperation : unit -> unit
Public Sub StartLogicalOperation ()

설명

논리 작업은 논리 작업 식별자에 대해 자동으로 생성된 GUID를 사용하여 시작됩니다.

적용 대상

StartLogicalOperation(Object)

Source:
CorrelationManager.cs
Source:
CorrelationManager.cs
Source:
CorrelationManager.cs

스레드에서 지정된 ID를 사용하여 논리 작업을 시작합니다.

public:
 void StartLogicalOperation(System::Object ^ operationId);
public void StartLogicalOperation (object operationId);
member this.StartLogicalOperation : obj -> unit
Public Sub StartLogicalOperation (operationId As Object)

매개 변수

operationId
Object

연산을 식별하는 개체입니다.

예외

operationId 매개 변수가 null인 경우

예제

다음 코드 예제에서는 기본 스레드와 연결 될 논리 작업을 초기화 하 여 메서드를 사용 StartLogicalOperation(Object) 하는 방법을 보여 줍니다. 전체 코드 예제는 클래스를 참조하세요 CorrelationManager .

TraceSource ts = new TraceSource("MyApp");
int i = ts.Listeners.Add(new ConsoleTraceListener());
ts.Listeners[i].TraceOutputOptions = TraceOptions.LogicalOperationStack;
ts.Switch = new SourceSwitch("MyAPP", "Verbose");
// Start the logical operation on the Main thread.
Trace.CorrelationManager.StartLogicalOperation("MainThread");
Dim ts As New TraceSource("MyApp")
Dim i As Integer = ts.Listeners.Add(New ConsoleTraceListener())
ts.Listeners(i).TraceOutputOptions = TraceOptions.LogicalOperationStack
ts.Switch = New SourceSwitch("MyAPP", "Verbose")
' Start the logical operation on the Main thread.
Trace.CorrelationManager.StartLogicalOperation("MainThread")

설명

매개 변수는 operationId 추적 목적으로 작업을 식별할 수 있는 와 같은 String 모든 개체일 수 있습니다. 가 operationId 나타내는 개체가 속성에 추가됩니다 LogicalOperationStack .

적용 대상