Class RouteMetadataAttribute
Represents metadata associated with a route. This attribute can be applied to classes or methods to add key-value pairs to the Bag dictionary.
[AttributeUsage(AttributeTargets.Class|AttributeTargets.Method, AllowMultiple = true, Inherited = true)]
public sealed class RouteMetadataAttribute : Attribute
- Inheritance
-
RouteMetadataAttribute
- Inherited Members
Remarks
This attribute allows for the extensibility of route definitions by providing a mechanism to attach arbitrary metadata. The metadata can be used for various purposes, such as authorization checks, logging, or custom route processing logic.
Constructors
- RouteMetadataAttribute(string, object?)
Initializes a new instance of the RouteMetadataAttribute class with the specified key and value.
Properties
- Key
Gets the key of the metadata.
- Value
Gets the value of the metadata.
English
Русский
Português
Español
Deutsch
中文 (简体)
日本語