MethodImplAttributes 열거형
메서드 구현의 특성에 대한 플래그를 지정합니다.
네임스페이스: System.Reflection
어셈블리: mscorlib(mscorlib.dll)
구문
‘선언
<SerializableAttribute> _
<ComVisibleAttribute(True)> _
Public Enumeration MethodImplAttributes
‘사용 방법
Dim instance As MethodImplAttributes
[SerializableAttribute]
[ComVisibleAttribute(true)]
public enum MethodImplAttributes
[SerializableAttribute]
[ComVisibleAttribute(true)]
public enum class MethodImplAttributes
/** @attribute SerializableAttribute() */
/** @attribute ComVisibleAttribute(true) */
public enum MethodImplAttributes
SerializableAttribute
ComVisibleAttribute(true)
public enum MethodImplAttributes
멤버
멤버 이름 | 설명 | |
---|---|---|
CodeTypeMask | 코드 형식에 대한 플래그를 지정합니다. | |
ForwardRef | 메서드가 정의되지 않도록 지정합니다. | |
IL | MSIL(Microsoft Intermediate Language)로 메서드를 구현하도록 지정합니다. | |
InternalCall | 내부 호출을 지정합니다. | |
Managed | 메서드 구현은 관리되고 다른 것은 관리되지 않도록 지정합니다. | |
ManagedMask | 코드 관리 여부를 지정합니다. | |
MaxMethodImplVal | 범위 확인 값을 지정합니다. | |
Native | 네이티브 메서드 구현으로 지정합니다. | |
NoInlining | 메서드가 인라인되지 않도록 지정합니다. | |
OPTIL | OPTIL(Optimized Intermediate Language)로 메서드를 구현하도록 지정합니다. | |
PreserveSig | 메서드 시그니처를 선언한 대로 정확하게 내보내도록 지정합니다. | |
Runtime | 런타임에 메서드가 구현되도록 지정합니다. | |
Synchronized | 본문을 통해 단일 스레드 메서드가 되도록 지정합니다. Static(Visual Basic에서는 Shared) 메서드는 형식을 잠그고 인스턴스 메서드는 인스턴스를 잠급니다. 또한 C# lock 문(C# 참조) 또는 Visual Basic Lock, Unlock 함수를 사용해도 같은 결과를 얻을 수 있습니다. | |
Unmanaged | 메서드 구현은 관리되지 않고 다른 것은 관리되도록 지정합니다. |
설명
특성은 다음과 같이 비트 OR 연산을 사용하여 결합됩니다.
Code Implementation Masks
CodeTypeMask
IL
Native
OPTIL
Runtime
Managed Masks
ManagedMask
Unmanaged
Managed
Implementation Information and Interop Masks
ForwardRef
PreserveSig
InternalCall
Synchronized
NoInlining
MaxMethodImplVal
참고
직접 작성한 코드가 아닌 코드에서는 public 형식과 인스턴스의 잠금을 사용할 수 있기 때문에 Synchronized 플래그의 경우와 마찬가지로 인스턴스나 형식을 잠그는 것은 public 형식에 권장되지 않습니다. 이렇게 하면 교착 상태나 다른 동기화 문제가 발생할 수 있습니다.
플랫폼
Windows 98, Windows 2000 SP4, Windows CE, Windows Millennium Edition, Windows Mobile for Pocket PC, Windows Mobile for Smartphone, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition
.NET Framework에서 모든 플래폼의 모든 버전을 지원하지는 않습니다. 지원되는 버전의 목록은 시스템 요구 사항을 참조하십시오.
버전 정보
.NET Framework
2.0, 1.1, 1.0에서 지원
.NET Compact Framework
2.0, 1.0에서 지원