EnumBuilder.GetEvent(String, BindingFlags) 메서드

정의

지정된 이름의 이벤트를 반환합니다.

public:
 override System::Reflection::EventInfo ^ GetEvent(System::String ^ name, System::Reflection::BindingFlags bindingAttr);
public override System.Reflection.EventInfo? GetEvent (string name, System.Reflection.BindingFlags bindingAttr);
public override System.Reflection.EventInfo GetEvent (string name, System.Reflection.BindingFlags bindingAttr);
override this.GetEvent : string * System.Reflection.BindingFlags -> System.Reflection.EventInfo
Public Overrides Function GetEvent (name As String, bindingAttr As BindingFlags) As EventInfo

매개 변수

name
String

가져올 이벤트의 이름입니다.

bindingAttr
BindingFlags

이 호출의 특성입니다. 이것은 InvokeMethod, NonPublic 등과 같은 BindingFlags의 비트 플래그여야 합니다.

반환

지정한 이름을 가진 이 형식이 선언하거나 상속한 이벤트를 나타내는 EventInfo 개체를 반환합니다. 일치하는 항목이 없는 경우 null 이 반환됩니다.

예외

이 메서드는 완전하지 않은 형식에서 현재 지원되지 않습니다.

설명

해결 방법으로 완성된 형식의 이벤트를 검색하려면 또는 Assembly.GetType 을 사용하여 Type.GetType 형식을 검색하고 검색된 형식에서 리플렉션을 사용합니다.

적용 대상