Skip to content

EnabledByAttribute Class

Marker attribute that indicates a controller or action is enabled by a specific OIDC endpoint configuration. Controllers or actions marked with this attribute will be removed from the application model if the specified endpoint is not enabled in EnabledEndpoints.

C#
public class EnabledByAttribute : System.Attribute

Inheritance System.ObjectSystem.Attribute → EnabledByAttribute

Remarks

This attribute is processed at application startup by EnabledByConvention, which removes controllers or actions from the application model if their endpoint is disabled. This prevents the controller/action from being registered at all, rather than checking at runtime.

Constructors

EnabledByAttribute(OidcEndpoints) Constructor

Initializes a new instance of the EnabledByAttribute class.

C#
public EnabledByAttribute(Abblix.Oidc.Server.Common.Configuration.OidcEndpoints endpoint);

Parameters

endpoint OidcEndpoints

The OIDC endpoint configuration flag that controls whether this controller/action is enabled.

Properties

EnabledByAttribute.Endpoint Property

The OIDC endpoint configuration flag.

C#
public Abblix.Oidc.Server.Common.Configuration.OidcEndpoints Endpoint { get; }

Property Value

OidcEndpoints