KeyTypeAttribute Třída

Definice

Povolit, aby člen byl označen jako KeyDataViewType.

[System.AttributeUsage(System.AttributeTargets.Field | System.AttributeTargets.Property, AllowMultiple=false, Inherited=true)]
public sealed class KeyTypeAttribute : Attribute
[<System.AttributeUsage(System.AttributeTargets.Field | System.AttributeTargets.Property, AllowMultiple=false, Inherited=true)>]
type KeyTypeAttribute = class
    inherit Attribute
Public NotInheritable Class KeyTypeAttribute
Inherits Attribute
Dědičnost
KeyTypeAttribute
Atributy

Poznámky

Lze použít pouze pro člena následujících typů: Byte, , UInt16, UInt32UInt64

Konstruktory

KeyTypeAttribute()

Označí člena jako KeyDataViewType.

KeyTypeAttribute(UInt64)

Označí člena jako KeyDataViewType kardinalitu a určuje KeyDataViewType kardinalitu. V případě, že se atribut používá s typy int, count by měl být nastaven na jednu více než maximální hodnotu pro účet pro počítání od 1 (0 je vyhrazeno pro chybějící typ klíče). Například kardinalita rozsahu 0–9 je 10. Pokud jsou hodnoty mimo zadanou kardinalitu, budou mapovány na chybějící reprezentaci hodnot: 0.

Platí pro