Name

MethodImplAttributes

Synopsis

These flags specify how a method has been implemented. Managed, Unmanaged, and ManagedMask indicate whether the method is managed or unmanaged code. If a method allows only one thread to execute it at a time, then its Synchronized flag is set. ForwardRef specifies that the method has not been defined, and InternalCall indicates that the method is an internal call. IL and OPTIL specify that the code is IL or optimized IL. If the method is provided by the runtime, Runtime should be set, and if the method implementation is native, Native is marked. When a method should not be inlined during optimization, NoInlining is set. When the method signature should be exported exactly as specified, PreserveSig is set.

Public Enum MethodImplAttributes
                  Managed = 0
                  IL = 0
                  Native = 1
                  OPTIL = 2
                  Runtime = 3
                  CodeTypeMask = 3
                  Unmanaged = 4
                  ManagedMask = 4
                  NoInlining = 8
                  ForwardRef = 16
                  Synchronized = 32
                  PreserveSig = 128
                  InternalCall = 4096
                  MaxMethodImplVal = 65535
End Enum

Hierarchy

System.ObjectSystem.ValueType System.Enum(System.IComparable, System.IFormattable, System.IConvertible) MethodImplAttributes

Returned By

MethodBase.GetMethodImplementationFlags()

Passed To

System.Reflection.Emit.ConstructorBuilder.SetImplementationFlags(), System.Reflection.Emit.MethodBuilder.SetImplementationFlags()

Get VB.NET Core Classes in a Nutshell now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.