Class AuthorizationHeaderBuilder<TAuthorizationHeader, TAuthorizationHeaderBuilder>
- Namespace
- Cuemon.AspNetCore.Authentication
- Assembly
- Cuemon.AspNetCore.Authentication.dll
Represents the base class from which all implementations of authorization header builders should derive. Implements the AuthorizationHeaderBuilder
public abstract class AuthorizationHeaderBuilder<TAuthorizationHeader, TAuthorizationHeaderBuilder> : AuthorizationHeaderBuilder where TAuthorizationHeader : AuthorizationHeader where TAuthorizationHeaderBuilder : AuthorizationHeaderBuilder
Type Parameters
TAuthorizationHeaderThe type of the authorization header result.
TAuthorizationHeaderBuilderThe type of the authorization header builder.
- Inheritance
-
AuthorizationHeaderBuilder<TAuthorizationHeader, TAuthorizationHeaderBuilder>
- Derived
- Inherited Members
Constructors
AuthorizationHeaderBuilder(string)
Initializes a new instance of the AuthorizationHeaderBuilder<TAuthorizationHeader, TAuthorizationHeaderBuilder> class.
protected AuthorizationHeaderBuilder(string authenticationScheme)
Parameters
authenticationSchemestringThe name of the authentication scheme.
Methods
AddOrUpdate(string, string)
Attempts to add or update an existing field with the provided name with the specified value.
public TAuthorizationHeaderBuilder AddOrUpdate(string name, string value)
Parameters
namestringThe name of the field to add or update.
valuestringThe value of the field to add or update.
Returns
- TAuthorizationHeaderBuilder
TAuthorizationHeaderBuilderthat can be used to further build the header.
Build()
Builds an instance of TAuthorizationHeader that implements AuthorizationHeader.
public abstract TAuthorizationHeader Build()
Returns
- TAuthorizationHeader
TAuthorizationHeader.