Share via


IdAttribute 類別

定義

指定成員的唯一身分識別。

[System.AttributeUsage(System.AttributeTargets.Class | System.AttributeTargets.Enum | System.AttributeTargets.Field | System.AttributeTargets.Method | System.AttributeTargets.Property | System.AttributeTargets.Struct)]
public sealed class IdAttribute : Attribute
[<System.AttributeUsage(System.AttributeTargets.Class | System.AttributeTargets.Enum | System.AttributeTargets.Field | System.AttributeTargets.Method | System.AttributeTargets.Property | System.AttributeTargets.Struct)>]
type IdAttribute = class
    inherit Attribute
Public NotInheritable Class IdAttribute
Inherits Attribute
繼承
IdAttribute
屬性

備註

類型中已 GenerateSerializerAttribute 套用的每個可序列化成員都必須套用一個具有唯 IdIdAttribute 值的屬性。

建構函式

IdAttribute(UInt32)

初始化 IdAttribute 類別的新執行個體。

屬性

Id

取得識別碼。

適用於

另請參閱