Class AuthorizationProvider
- java.lang.Object
-
- io.vertx.mutiny.ext.auth.authorization.AuthorizationProvider
-
- Direct Known Subclasses:
JDBCAuthorization
,JWTAuthorization
,KeycloakAuthorization
,MicroProfileAuthorization
,MongoAuthorization
,PropertyFileAuthorization
,ScopeAuthorization
,SqlAuthorization
public class AuthorizationProvider extends Object
The role of an AuthorizationProvider is to return a set of Authorization. Note that each AuthorizationProvider must provide its own unique Id NOTE: This class has been automatically generated from theoriginal
non Mutiny-ified interface using Vert.x codegen.
-
-
Field Summary
Fields Modifier and Type Field Description static TypeArg<AuthorizationProvider>
__TYPE_ARG
-
Constructor Summary
Constructors Constructor Description AuthorizationProvider(io.vertx.ext.auth.authorization.AuthorizationProvider delegate)
AuthorizationProvider(Object delegate)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static AuthorizationProvider
create(String id, Set<Authorization> authorizations)
boolean
equals(Object o)
io.smallrye.mutiny.Uni<Void>
getAuthorizations(User user)
Updates the user with the set of authorizations.Void
getAuthorizationsAndAwait(User user)
Blocking variant ofgetAuthorizations(io.vertx.mutiny.ext.auth.User)
.void
getAuthorizationsAndForget(User user)
Variant ofgetAuthorizations(io.vertx.mutiny.ext.auth.User)
that ignores the result of the operation.io.vertx.ext.auth.authorization.AuthorizationProvider
getDelegate()
String
getId()
int
hashCode()
static AuthorizationProvider
newInstance(io.vertx.ext.auth.authorization.AuthorizationProvider arg)
String
toString()
-
-
-
Field Detail
-
__TYPE_ARG
public static final TypeArg<AuthorizationProvider> __TYPE_ARG
-
-
Constructor Detail
-
AuthorizationProvider
public AuthorizationProvider(io.vertx.ext.auth.authorization.AuthorizationProvider delegate)
-
AuthorizationProvider
public AuthorizationProvider(Object delegate)
-
-
Method Detail
-
getDelegate
public io.vertx.ext.auth.authorization.AuthorizationProvider getDelegate()
-
create
public static AuthorizationProvider create(String id, Set<Authorization> authorizations)
- Parameters:
id
-authorizations
-- Returns:
-
getId
public String getId()
- Returns:
-
getAuthorizations
public io.smallrye.mutiny.Uni<Void> getAuthorizations(User user)
Updates the user with the set of authorizations.Unlike the bare Vert.x variant, this method returns a
Uni
. Don't forget to subscribe on it to trigger the operation.- Parameters:
user
- user to lookup and update- Returns:
- the
uni
firing the result of the operation when completed, or a failure if the operation failed.
-
getAuthorizationsAndAwait
public Void getAuthorizationsAndAwait(User user)
Blocking variant ofgetAuthorizations(io.vertx.mutiny.ext.auth.User)
.This method waits 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 a RuntimeException).
- Parameters:
user
- user to lookup and update- Returns:
- the Void instance produced by the operation.
-
getAuthorizationsAndForget
public void getAuthorizationsAndForget(User user)
Variant ofgetAuthorizations(io.vertx.mutiny.ext.auth.User)
that ignores the result of the operation.This method subscribes on the result of
getAuthorizations(io.vertx.mutiny.ext.auth.User)
, but discards the outcome (item or failure). This method is useful to trigger the asynchronous operation fromgetAuthorizations(io.vertx.mutiny.ext.auth.User)
but you don't need to compose it with other operations.- Parameters:
user
- user to lookup and update
-
newInstance
public static AuthorizationProvider newInstance(io.vertx.ext.auth.authorization.AuthorizationProvider arg)
-
-