ModuleBuilder.SetCustomAttribute 메서드

정의

이 모듈에 사용자 지정 특성을 적용합니다.

오버로드

SetCustomAttribute(CustomAttributeBuilder)

사용자 지정 특성 작성기를 사용하여 이 모듈에 사용자 지정 특성을 적용합니다.

SetCustomAttribute(ConstructorInfo, Byte[])

특성을 나타내는 지정된 BLOB(Binary Large Object)를 사용하여 이 모듈에 사용자 지정 특성을 적용합니다.

SetCustomAttribute(CustomAttributeBuilder)

Source:
ModuleBuilder.cs
Source:
ModuleBuilder.cs
Source:
ModuleBuilder.cs

사용자 지정 특성 작성기를 사용하여 이 모듈에 사용자 지정 특성을 적용합니다.

public:
 void SetCustomAttribute(System::Reflection::Emit::CustomAttributeBuilder ^ customBuilder);
public void SetCustomAttribute (System.Reflection.Emit.CustomAttributeBuilder customBuilder);
member this.SetCustomAttribute : System.Reflection.Emit.CustomAttributeBuilder -> unit
Public Sub SetCustomAttribute (customBuilder As CustomAttributeBuilder)

매개 변수

customBuilder
CustomAttributeBuilder

적용할 사용자 지정 특성을 지정하는 도우미 클래스의 인스턴스입니다.

예외

customBuildernull입니다.

설명

참고

.NET Framework 2.0 서비스 팩 1부터 이 멤버는 ReflectionPermission 더 이상 플래그가 ReflectionPermissionFlag.ReflectionEmit 필요하지 않습니다. (리플렉션 내보내기의 보안 문제를 참조하세요.) 이 기능을 사용하려면 애플리케이션이 .NET Framework 3.5 이상을 대상으로 해야 합니다.

적용 대상

SetCustomAttribute(ConstructorInfo, Byte[])

Source:
ModuleBuilder.cs
Source:
ModuleBuilder.cs
Source:
ModuleBuilder.cs

특성을 나타내는 지정된 BLOB(Binary Large Object)를 사용하여 이 모듈에 사용자 지정 특성을 적용합니다.

public:
 void SetCustomAttribute(System::Reflection::ConstructorInfo ^ con, cli::array <System::Byte> ^ binaryAttribute);
public void SetCustomAttribute (System.Reflection.ConstructorInfo con, byte[] binaryAttribute);
[System.Runtime.InteropServices.ComVisible(true)]
public void SetCustomAttribute (System.Reflection.ConstructorInfo con, byte[] binaryAttribute);
member this.SetCustomAttribute : System.Reflection.ConstructorInfo * byte[] -> unit
[<System.Runtime.InteropServices.ComVisible(true)>]
member this.SetCustomAttribute : System.Reflection.ConstructorInfo * byte[] -> unit
Public Sub SetCustomAttribute (con As ConstructorInfo, binaryAttribute As Byte())

매개 변수

con
ConstructorInfo

사용자 지정 특성에 대한 생성자입니다.

binaryAttribute
Byte[]

특성을 나타내는 바이트 BLOB입니다.

특성

예외

con 또는 binaryAttributenull인 경우

설명

형식을 지정 binaryAttribute하는 방법에 대한 자세한 내용은 CLI(공용 언어 인프라) 설명서, 특히 "파티션 II: 메타데이터 정의 및 의미 체계"를 참조하세요. 자세한 내용은 ECMA 335 CLI(공용 언어 인프라)를 참조하세요.

참고

.NET Framework 2.0 서비스 팩 1부터 이 멤버는 ReflectionPermission 더 이상 플래그가 ReflectionPermissionFlag.ReflectionEmit 필요하지 않습니다. (리플렉션 내보내기의 보안 문제를 참조하세요.) 이 기능을 사용하려면 애플리케이션이 .NET Framework 3.5 이상을 대상으로 해야 합니다.

적용 대상