SkipLocalsInitAttribute Třída

Definice

Označuje kompilátor, že příznak inicializace. Locals by neměl být nastaven v hlavičkách vnořené metody při generování metadat.Indicates to the compiler that the .locals init flag should not be set in nested method headers when emitting to metadata.

public ref class SkipLocalsInitAttribute sealed : Attribute
[System.AttributeUsage(System.AttributeTargets.Class | System.AttributeTargets.Constructor | System.AttributeTargets.Event | System.AttributeTargets.Interface | System.AttributeTargets.Method | System.AttributeTargets.Module | System.AttributeTargets.Property | System.AttributeTargets.Struct, Inherited=false)]
public sealed class SkipLocalsInitAttribute : Attribute
[<System.AttributeUsage(System.AttributeTargets.Class | System.AttributeTargets.Constructor | System.AttributeTargets.Event | System.AttributeTargets.Interface | System.AttributeTargets.Method | System.AttributeTargets.Module | System.AttributeTargets.Property | System.AttributeTargets.Struct, Inherited=false)>]
type SkipLocalsInitAttribute = class
    inherit Attribute
Public NotInheritable Class SkipLocalsInitAttribute
Inherits Attribute
Dědičnost
SkipLocalsInitAttribute
Atributy

Poznámky

Tento atribut je nebezpečný, protože může aplikaci v určitých instancích odhalit neinicializovaná paměť (například čtení z neinicializované paměti přidělené zásobníkem).This attribute is unsafe, because it may reveal uninitialized memory to the application in certain instances (for example, reading from uninitialized stack-allocated memory). Pokud je použita na metodu přímo, atribut se vztahuje na tuto metodu a všechny její vnořené funkce, včetně výrazů lambda a místních funkcí.If applied to a method directly, the attribute applies to that method and all its nested functions, including lambdas and local functions. Pokud se použije na typ nebo modul, platí pro všechny metody vnořené uvnitř.If applied to a type or module, it applies to all methods nested inside. Tento atribut není pro sestavení záměrně povolen.This attribute is intentionally not permitted on assemblies. Chcete-li použít atribut na více deklarací typu, použijte místo toho na úrovni modulu.To apply the attribute to multiple type declarations, use it at the module level instead.

Konstruktory

SkipLocalsInitAttribute()

Inicializuje novou instanci SkipLocalsInitAttribute třídy.Initializes a new instance of the SkipLocalsInitAttribute class.

Vlastnosti

TypeId

Při implementaci v odvozené třídě získá jedinečný identifikátor Attribute .When implemented in a derived class, gets a unique identifier for this Attribute.

(Zděděno od Attribute)

Metody

Equals(Object)

Vrací hodnotu, která určuje, zda je tato instance rovna zadanému objektu.Returns a value that indicates whether this instance is equal to a specified object.

(Zděděno od Attribute)
GetHashCode()

Vrátí hodnotu hash pro tuto instanci.Returns the hash code for this instance.

(Zděděno od Attribute)
GetType()

Získá Type aktuální instanci.Gets the Type of the current instance.

(Zděděno od Object)
IsDefaultAttribute()

Při přepsání v odvozené třídě označuje, zda je hodnota této instance výchozí hodnotou pro odvozenou třídu.When overridden in a derived class, indicates whether the value of this instance is the default value for the derived class.

(Zděděno od Attribute)
Match(Object)

Při přepsání v odvozené třídě vrátí hodnotu, která označuje, zda je tato instance rovna zadanému objektu.When overridden in a derived class, returns a value that indicates whether this instance equals a specified object.

(Zděděno od Attribute)
MemberwiseClone()

Vytvoří kopii aktuálního seznamu Object .Creates a shallow copy of the current Object.

(Zděděno od Object)
ToString()

Vrátí řetězec, který představuje aktuální objekt.Returns a string that represents the current object.

(Zděděno od Object)

Explicitní implementace rozhraní

_Attribute.GetIDsOfNames(Guid, IntPtr, UInt32, UInt32, IntPtr)

Mapuje sadu názvů na odpovídající sadu identifikátorů pro rozesílání.Maps a set of names to a corresponding set of dispatch identifiers.

(Zděděno od Attribute)
_Attribute.GetTypeInfo(UInt32, UInt32, IntPtr)

Načte informace o typu pro objekt, který lze použít k získání informací o typu pro rozhraní.Retrieves the type information for an object, which can be used to get the type information for an interface.

(Zděděno od Attribute)
_Attribute.GetTypeInfoCount(UInt32)

Získá počet rozhraní typu informací, které objekt poskytuje (0 nebo 1).Retrieves the number of type information interfaces that an object provides (either 0 or 1).

(Zděděno od Attribute)
_Attribute.Invoke(UInt32, Guid, UInt32, Int16, IntPtr, IntPtr, IntPtr, IntPtr)

Poskytuje přístup k vlastnostem a metodám vystaveným objektem.Provides access to properties and methods exposed by an object.

(Zděděno od Attribute)

Platí pro