Class KeycloakAuthorization
- All Implemented Interfaces:
MutinyDelegate,AuthorizationProvider
NOTE: This class has been automatically generated from the original non Mutiny-ified interface.
- Author:
- Paulo Lopes.
- See Also:
-
KeycloakAuthorization
-
Nested Class Summary
Nested classes/interfaces inherited from interface io.vertx.mutiny.ext.auth.authorization.AuthorizationProvider
AuthorizationProvider.AuthorizationProviderImpl -
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionKeycloakAuthorization(io.vertx.ext.auth.oauth2.authorization.KeycloakAuthorization delegate) Create a new instance ofKeycloakAuthorizationdelegating to the given (non-null) instance ofKeycloakAuthorization.KeycloakAuthorization(Object delegate) -
Method Summary
Modifier and TypeMethodDescriptionstatic KeycloakAuthorizationcreate()Factory method to create an Authorization Provider for tokens adhering to the Keycloak token format.booleanio.smallrye.mutiny.Uni<Void>getAuthorizations(User user) Updates the user with the set of authorizations.voidUpdates the user with the set of authorizations.Updates the user with the set of authorizations.io.vertx.ext.auth.oauth2.authorization.KeycloakAuthorizationGet the delegate instance.getId()returns the id of the authorization providerinthashCode()static KeycloakAuthorizationnewInstance(io.vertx.ext.auth.oauth2.authorization.KeycloakAuthorization delegate) Creates a new instance of theKeycloakAuthorization.toString()
-
Field Details
-
__TYPE_ARG
-
-
Constructor Details
-
KeycloakAuthorization
public KeycloakAuthorization(io.vertx.ext.auth.oauth2.authorization.KeycloakAuthorization delegate) Create a new instance ofKeycloakAuthorizationdelegating to the given (non-null) instance ofKeycloakAuthorization. -
KeycloakAuthorization
-
-
Method Details
-
getDelegate
public io.vertx.ext.auth.oauth2.authorization.KeycloakAuthorization getDelegate()Get the delegate instance.This method returns the instance on which this shim is delegating the calls. And so, give you access to the bare API.
- Specified by:
getDelegatein interfaceAuthorizationProvider- Specified by:
getDelegatein interfaceMutinyDelegate- Returns:
- the delegate instance
-
getAuthorizations
Updates the user with the set of authorizations.Unlike the bare Vert.x variant, this method returns a
Uni. The uni emits the result of the operation as item. If the operation fails, the uni emits the failure.Don't forget to subscribe on it to trigger the operation.
- Specified by:
getAuthorizationsin interfaceAuthorizationProvider- Parameters:
user- user to lookup and update.- Returns:
- A
Unirepresenting the asynchronous result of this operation. - See Also:
-
io.vertx.ext.auth.oauth2.authorization.KeycloakAuthorization#getAuthorizations(User)
-
getAuthorizationsAndAwait
Updates the user with the set of authorizations.Unlike the bare Vert.x variant, this method returns a
Void. This method awaits indefinitely for the completion of the underlying asynchronous operation. If the operation completes successfully, the result is returned, otherwise the failure is thrown (potentially wrapped in aRuntimeException).- Parameters:
user- user to lookup and update.- See Also:
-
io.vertx.ext.auth.oauth2.authorization.KeycloakAuthorization#getAuthorizations(User)
-
getAuthorizationsAndForget
Updates the user with the set of authorizations.Unlike the bare Vert.x variant, this method ignores the
Voidresult or any failure.- Parameters:
user- user to lookup and update.- Returns:
- The current instance to chain operations if needed.
- See Also:
-
io.vertx.ext.auth.oauth2.authorization.KeycloakAuthorization#getAuthorizations(User)
-
create
Factory method to create an Authorization Provider for tokens adhering to the Keycloak token format. When the user is known to not be a JWT, (e.g.: a OAuth2 response token) then the root claim is expected to be the extracted from the userUser.attributes()under the key:accessToken.- Returns:
- a AuthorizationProvider
-
getId
returns the id of the authorization provider- Specified by:
getIdin interfaceAuthorizationProvider- Returns:
-
newInstance
public static KeycloakAuthorization newInstance(io.vertx.ext.auth.oauth2.authorization.KeycloakAuthorization delegate) Creates a new instance of theKeycloakAuthorization. -
hashCode
public int hashCode() -
equals
-
toString
-