NGWS SDK Documentation  

This is preliminary documentation and subject to change.
To comment on this topic, please send us email at ngwssdk@microsoft.com. Thanks!

AttributeUsage

Describes how a custom attribute class can be used.

[AttributeUsage(
   validon,
   AllowMultiple=allowmultiple,
   Inherited=inherited
)]

Parameters

validon
Specifies the language elements on which the attribute may be placed; a combination of AttributeTargets values. Default value is AttributeTargets.All.
allowmultiple (Optional)
A bool; if true, the attribute is multi-use. Default is false (single-use).
inherited (Optional)
A bool; if true, the attribute is inherited by derived classes. If AllowMultiple is true, the attribute accumulates on the derived member; if AllowMultiple is false, the attribute will override (or replace) in inheritance. Default is false (not inherited).

Applies To

Class declarations.

Remarks

AttributeUsage is a single-use attribute. AttributeUsage is an alias for System.AttributeUsageAttribute.

Example

See the example in Introduction to Attributes.

See Also

C# Attributes | Attributes Tutorial