Class TeaPieAuthenticationExtensions
public static class TeaPieAuthenticationExtensions
- Inheritance
-
TeaPieAuthenticationExtensions
- Inherited Members
Methods
RegisterAuthProvider(TeaPie, string, IAuthProvider)
Registers an authentication provider with the specified name.
public static void RegisterAuthProvider(this TeaPie teaPie, string name, IAuthProvider authenticationProvider)
Parameters
teaPieTeaPieThe current context instance.
namestringThe name under which the authentication provider will be registered.
authenticationProviderIAuthProviderThe authentication provider to register.
RegisterDefaultAuthProvider(TeaPie, string, IAuthProvider)
Registers an authentication provider with the specified name and sets it as the default provider.
public static void RegisterDefaultAuthProvider(this TeaPie teaPie, string name, IAuthProvider authenticationProvider)
Parameters
teaPieTeaPieThe current context instance.
namestringThe name under which the authentication provider will be registered.
authenticationProviderIAuthProviderThe authentication provider to register.
SetDefaultAuthProvider(TeaPie, string)
Sets the default authentication provider for all requests. A different authentication provider can still be specified for individual requests using a directive.
public static void SetDefaultAuthProvider(this TeaPie teaPie, string name)
Parameters
teaPieTeaPieThe current context instance.
namestringThe name of a previously registered authentication provider to set as default.
Exceptions
- InvalidOperationException
Thrown if no authentication provider is registered with the specified
name.