TraceListener.TraceEvent 메서드

정의

추적 및 이벤트 정보를 수신기별 출력에 씁니다.

오버로드

TraceEvent(TraceEventCache, String, TraceEventType, Int32)

추적 및 이벤트 정보를 수신기별 출력에 씁니다.

TraceEvent(TraceEventCache, String, TraceEventType, Int32, String)

추적 정보, 메시지 및 이벤트 정보를 수신기별 출력에 씁니다.

TraceEvent(TraceEventCache, String, TraceEventType, Int32, String, Object[])

추적 정보, 서식 지정된 개체 배열 및 이벤트 정보를 수신기별 출력에 씁니다.

TraceEvent(TraceEventCache, String, TraceEventType, Int32)

Source:
TraceListener.cs
Source:
TraceListener.cs
Source:
TraceListener.cs

추적 및 이벤트 정보를 수신기별 출력에 씁니다.

public:
 virtual void TraceEvent(System::Diagnostics::TraceEventCache ^ eventCache, System::String ^ source, System::Diagnostics::TraceEventType eventType, int id);
public virtual void TraceEvent (System.Diagnostics.TraceEventCache? eventCache, string source, System.Diagnostics.TraceEventType eventType, int id);
public virtual void TraceEvent (System.Diagnostics.TraceEventCache eventCache, string source, System.Diagnostics.TraceEventType eventType, int id);
[System.Runtime.InteropServices.ComVisible(false)]
public virtual void TraceEvent (System.Diagnostics.TraceEventCache eventCache, string source, System.Diagnostics.TraceEventType eventType, int id);
abstract member TraceEvent : System.Diagnostics.TraceEventCache * string * System.Diagnostics.TraceEventType * int -> unit
override this.TraceEvent : System.Diagnostics.TraceEventCache * string * System.Diagnostics.TraceEventType * int -> unit
[<System.Runtime.InteropServices.ComVisible(false)>]
abstract member TraceEvent : System.Diagnostics.TraceEventCache * string * System.Diagnostics.TraceEventType * int -> unit
override this.TraceEvent : System.Diagnostics.TraceEventCache * string * System.Diagnostics.TraceEventType * int -> unit
Public Overridable Sub TraceEvent (eventCache As TraceEventCache, source As String, eventType As TraceEventType, id As Integer)

매개 변수

eventCache
TraceEventCache

현재 프로세스 ID, 스레드 ID 및 스택 추적 정보가 포함된 TraceEventCache 개체입니다.

source
String

출력을 식별하는 데 사용되는 이름이며 일반적으로 추적 이벤트를 생성한 애플리케이션의 이름입니다.

eventType
TraceEventType

추적을 발생시킨 이벤트의 형식을 지정하는 TraceEventType 값 중 하나입니다.

id
Int32

이벤트의 숫자 식별자입니다.

특성

설명

중요

이 메서드는 애플리케이션 코드에서 직접 하지만의 회원과 호출할 수 없습니다는 Debug, Trace, 및 TraceSource 추적 데이터를 출력을 작성 하는 클래스입니다.

기본 구현은 및 eventTypeid 매개 변수의 source값을 헤더로 씁니다. 데이터는 eventCache 바닥글로 작성되며, 출력 데이터의 특성은 속성 값 TraceOutputOptions 에 따라 달라집니다.

추가 정보

적용 대상

TraceEvent(TraceEventCache, String, TraceEventType, Int32, String)

Source:
TraceListener.cs
Source:
TraceListener.cs
Source:
TraceListener.cs

추적 정보, 메시지 및 이벤트 정보를 수신기별 출력에 씁니다.

public:
 virtual void TraceEvent(System::Diagnostics::TraceEventCache ^ eventCache, System::String ^ source, System::Diagnostics::TraceEventType eventType, int id, System::String ^ message);
public virtual void TraceEvent (System.Diagnostics.TraceEventCache? eventCache, string source, System.Diagnostics.TraceEventType eventType, int id, string? message);
public virtual void TraceEvent (System.Diagnostics.TraceEventCache eventCache, string source, System.Diagnostics.TraceEventType eventType, int id, string message);
[System.Runtime.InteropServices.ComVisible(false)]
public virtual void TraceEvent (System.Diagnostics.TraceEventCache eventCache, string source, System.Diagnostics.TraceEventType eventType, int id, string message);
abstract member TraceEvent : System.Diagnostics.TraceEventCache * string * System.Diagnostics.TraceEventType * int * string -> unit
override this.TraceEvent : System.Diagnostics.TraceEventCache * string * System.Diagnostics.TraceEventType * int * string -> unit
[<System.Runtime.InteropServices.ComVisible(false)>]
abstract member TraceEvent : System.Diagnostics.TraceEventCache * string * System.Diagnostics.TraceEventType * int * string -> unit
override this.TraceEvent : System.Diagnostics.TraceEventCache * string * System.Diagnostics.TraceEventType * int * string -> unit
Public Overridable Sub TraceEvent (eventCache As TraceEventCache, source As String, eventType As TraceEventType, id As Integer, message As String)

매개 변수

eventCache
TraceEventCache

현재 프로세스 ID, 스레드 ID 및 스택 추적 정보가 포함된 TraceEventCache 개체입니다.

source
String

출력을 식별하는 데 사용되는 이름이며 일반적으로 추적 이벤트를 생성한 애플리케이션의 이름입니다.

eventType
TraceEventType

추적을 발생시킨 이벤트의 형식을 지정하는 TraceEventType 값 중 하나입니다.

id
Int32

이벤트의 숫자 식별자입니다.

message
String

쓸 메시지입니다.

특성

설명

중요

이 메서드는 애플리케이션 코드에서 직접 하지만의 회원과 호출할 수 없습니다는 Debug, Trace, 및 TraceSource 추적 데이터를 출력을 작성 하는 클래스입니다.

기본 구현은 및 eventTypeid 매개 변수의 source값을 헤더로 쓴 다음 message 데이터를 씁니다. 데이터는 eventCache 바닥글로 작성되며, 출력 데이터의 특성은 속성 값 TraceOutputOptions 에 따라 달라집니다.

추가 정보

적용 대상

TraceEvent(TraceEventCache, String, TraceEventType, Int32, String, Object[])

Source:
TraceListener.cs
Source:
TraceListener.cs
Source:
TraceListener.cs

추적 정보, 서식 지정된 개체 배열 및 이벤트 정보를 수신기별 출력에 씁니다.

public:
 virtual void TraceEvent(System::Diagnostics::TraceEventCache ^ eventCache, System::String ^ source, System::Diagnostics::TraceEventType eventType, int id, System::String ^ format, ... cli::array <System::Object ^> ^ args);
public virtual void TraceEvent (System.Diagnostics.TraceEventCache? eventCache, string source, System.Diagnostics.TraceEventType eventType, int id, string format, params object?[]? args);
public virtual void TraceEvent (System.Diagnostics.TraceEventCache? eventCache, string source, System.Diagnostics.TraceEventType eventType, int id, string? format, params object?[]? args);
public virtual void TraceEvent (System.Diagnostics.TraceEventCache eventCache, string source, System.Diagnostics.TraceEventType eventType, int id, string format, params object[] args);
[System.Runtime.InteropServices.ComVisible(false)]
public virtual void TraceEvent (System.Diagnostics.TraceEventCache eventCache, string source, System.Diagnostics.TraceEventType eventType, int id, string format, params object[] args);
abstract member TraceEvent : System.Diagnostics.TraceEventCache * string * System.Diagnostics.TraceEventType * int * string * obj[] -> unit
override this.TraceEvent : System.Diagnostics.TraceEventCache * string * System.Diagnostics.TraceEventType * int * string * obj[] -> unit
[<System.Runtime.InteropServices.ComVisible(false)>]
abstract member TraceEvent : System.Diagnostics.TraceEventCache * string * System.Diagnostics.TraceEventType * int * string * obj[] -> unit
override this.TraceEvent : System.Diagnostics.TraceEventCache * string * System.Diagnostics.TraceEventType * int * string * obj[] -> unit
Public Overridable Sub TraceEvent (eventCache As TraceEventCache, source As String, eventType As TraceEventType, id As Integer, format As String, ParamArray args As Object())

매개 변수

eventCache
TraceEventCache

현재 프로세스 ID, 스레드 ID 및 스택 추적 정보가 포함된 TraceEventCache 개체입니다.

source
String

출력을 식별하는 데 사용되는 이름이며 일반적으로 추적 이벤트를 생성한 애플리케이션의 이름입니다.

eventType
TraceEventType

추적을 발생시킨 이벤트의 형식을 지정하는 TraceEventType 값 중 하나입니다.

id
Int32

이벤트의 숫자 식별자입니다.

format
String

args 배열에 들어 있는 개체에 해당하는 0개 이상의 형식 항목이 포함된 형식 문자열입니다.

args
Object[]

형식을 지정할 개체가 0개 이상 포함된 object 배열입니다.

특성

설명

중요

이 메서드는 애플리케이션 코드에서 직접 하지만의 회원과 호출할 수 없습니다는 Debug, Trace, 및 TraceSource 추적 데이터를 출력을 작성 하는 클래스입니다.

기본 구현은 및 eventTypeid 매개 변수의 source값을 헤더로 씁니다. 개체 배열은 args 메서드를 사용하여 Format 문자열로 변환되고 문자열과 args 배열을 format 전달하여 문자열을 추적의 메시지 부분으로 서식을 지정합니다. 데이터는 eventCache 바닥글로 작성되며, 출력 데이터의 특성은 속성 값 TraceOutputOptions 에 따라 달라집니다.

추가 정보

적용 대상