Development · Native API migration preview · Coverage validation in progress Published release →

API Browser

Class

AttributeUsageAttribute

class AttributeUsageAttribute

Module: System
Assembly: System.Runtime.dll
Source file: AttributeUsageAttribute.rvn

Inheritance: Object → Attribute → AttributeUsageAttribute

Describes the declaration targets, repetition and inheritance policy of an attribute class.

Constructors

1 item
AttributeUsageAttribute(validOn: AttributeTargets) Initializes a usage policy with repetition disabled and inheritance enabled.

Properties

3 items
AllowMultiple: bool Gets or sets whether the attribute may occur more than once on a declaration.
Inherited: bool Gets or sets whether inherited queries should consider the attribute.
ValidOn: AttributeTargets Gets the declaration categories to which the attribute may be applied.

Methods

4 items
Equals(other: object?) -> bool Tests reference identity by default; an ordinary class may override equality. Inherited from Object.Equals
GetHashCode() -> int Returns a stable identity hash by default; an ordinary class may override it consistently with equality. Inherited from Object.GetHashCode
GetType() -> TypeInfo Returns metadata for the concrete runtime type of this instance. Inherited from Object.GetType
ToString() -> string Returns the concrete runtime type name for supported references, or display text from a class or boxed-struct override. Inherited from Object.ToString