TypeBuilder.DefineEvent(String, EventAttributes, Type) 메서드

정의

지정된 이름, 특성 및 이벤트 형식을 사용하여 형식에 새 이벤트를 추가합니다.

public:
 System::Reflection::Emit::EventBuilder ^ DefineEvent(System::String ^ name, System::Reflection::EventAttributes attributes, Type ^ eventtype);
public System.Reflection.Emit.EventBuilder DefineEvent (string name, System.Reflection.EventAttributes attributes, Type eventtype);
member this.DefineEvent : string * System.Reflection.EventAttributes * Type -> System.Reflection.Emit.EventBuilder
Public Function DefineEvent (name As String, attributes As EventAttributes, eventtype As Type) As EventBuilder

매개 변수

name
String

이벤트의 이름입니다. name에는 내장된 null이 포함될 수 없습니다.

attributes
EventAttributes

이벤트의 특성입니다.

eventtype
Type

이벤트의 형식입니다.

반환

정의된 이벤트입니다.

예외

name의 길이가 0입니다.

name이(가) null인 경우

또는

eventtype이(가) null인 경우

CreateType()을 사용하여 이전에 형식을 만들었습니다.

적용 대상