class AccessToken extends User
AccessToken extension to the User interface
- Alphabetic
- By Inheritance
- AccessToken
- User
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Instance Constructors
- new AccessToken(_asJava: AnyRef)
Value Members
-
final
def
!=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
def
accessToken(): JsonObject
The Access Token if present parsed as a JsonObject * @return JSON
-
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
-
def
asJava: AnyRef
- Definition Classes
- User
-
def
clearCache(): User
The User object will cache any authorities that it knows it has to avoid hitting the underlying auth provider each time.
The User object will cache any authorities that it knows it has to avoid hitting the underlying auth provider each time. Use this method if you want to clear this cache. * @return the User to enable fluent use
- Definition Classes
- User
-
def
clone(): AnyRef
- Attributes
- protected[java.lang]
- Definition Classes
- AnyRef
- Annotations
- @native() @throws( ... )
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
equals(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
def
expired(): Boolean
Check if the access token is expired or not.
-
def
fetch(method: HttpMethod, resource: String, headers: JsonObject, payload: Buffer, callback: Handler[AsyncResult[OAuth2Response]]): AccessToken
Fetches a JSON resource using this Access Token.
Fetches a JSON resource using this Access Token. * @param method - the HTTP method to user.
- resource
- the resource to fetch.
- headers
- extra headers to pass to the request.
- payload
- payload to send to the server.
- callback
- The callback function returning the results.
-
def
fetch(resource: String, callback: Handler[AsyncResult[OAuth2Response]]): AccessToken
Fetches a JSON resource using this Access Token.
Fetches a JSON resource using this Access Token. * @param resource - the resource to fetch.
- callback
- The callback function returning the results.
-
def
fetchFuture(method: HttpMethod, resource: String, headers: JsonObject, payload: Buffer): Future[OAuth2Response]
Like fetch but returns a scala.concurrent.Future instead of taking an AsyncResultHandler.
-
def
fetchFuture(resource: String): Future[OAuth2Response]
Like fetch but returns a scala.concurrent.Future instead of taking an AsyncResultHandler.
-
def
finalize(): Unit
- Attributes
- protected[java.lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( classOf[java.lang.Throwable] )
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
def
hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
def
idToken(): JsonObject
The Id Token if present parsed as a JsonObject * @return JSON
-
def
introspect(tokenType: String, callback: Handler[AsyncResult[Unit]]): AccessToken
Introspect access token.
Introspect access token. This is an OAuth2 extension that allow to verify if an access token is still valid. * @param tokenType - A String containing the type of token to revoke. Should be either "access_token" or "refresh_token".
- callback
- The callback function returning the results.
-
def
introspect(callback: Handler[AsyncResult[Unit]]): AccessToken
Introspect access token.
Introspect access token. This is an OAuth2 extension that allow to verify if an access token is still valid. * @param callback - The callback function returning the results.
-
def
introspectFuture(tokenType: String): Future[Unit]
Like introspect but returns a scala.concurrent.Future instead of taking an AsyncResultHandler.
-
def
introspectFuture(): Future[Unit]
Like introspect but returns a scala.concurrent.Future instead of taking an AsyncResultHandler.
-
def
isAuthorised(authority: String, resultHandler: Handler[AsyncResult[Boolean]]): User
- Definition Classes
- User
-
def
isAuthorisedFuture(authority: String): Future[Boolean]
Like isAuthorised but returns a scala.concurrent.Future instead of taking an AsyncResultHandler.
Like isAuthorised but returns a scala.concurrent.Future instead of taking an AsyncResultHandler.
- Definition Classes
- User
-
def
isAuthorized(authority: String, resultHandler: Handler[AsyncResult[Boolean]]): User
Is the user authorised to * @param authority the authority - what this really means is determined by the specific implementation.
Is the user authorised to * @param authority the authority - what this really means is determined by the specific implementation. It might represent a permission to access a resource e.g.
printers:printer34
or it might represent authority to a role in a roles based model, e.g.role:admin
.- resultHandler
handler that will be called with an io.vertx.lang.scala.AsyncResult containing the value
true
if the they has the authority orfalse
otherwise.- returns
the User to enable fluent use
- Definition Classes
- User
-
def
isAuthorizedFuture(authority: String): Future[Boolean]
Like isAuthorized but returns a scala.concurrent.Future instead of taking an AsyncResultHandler.
Like isAuthorized but returns a scala.concurrent.Future instead of taking an AsyncResultHandler.
- Definition Classes
- User
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
-
def
logout(callback: Handler[AsyncResult[Unit]]): AccessToken
Revoke refresh token and calls the logout endpoint.
Revoke refresh token and calls the logout endpoint. This is a openid-connect extension and might not be available on all providers. * @param callback - The callback function returning the results.
-
def
logoutFuture(): Future[Unit]
Like logout but returns a scala.concurrent.Future instead of taking an AsyncResultHandler.
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
def
opaqueAccessToken(): String
The RAW String if available for the Access Token * @return String
-
def
opaqueIdToken(): String
The RAW String if available for the Id Token * @return String
-
def
opaqueRefreshToken(): String
The RAW String if available for the Refresh Token * @return String
-
def
principal(): JsonObject
Get the underlying principal for the User.
Get the underlying principal for the User. What this actually returns depends on the implementation. For a simple user/password based auth, it's likely to contain a JSON object with the following structure:
{ "username", "tim" `
* @return JSON representation of the Principal- Definition Classes
- User
-
def
refresh(callback: Handler[AsyncResult[Unit]]): AccessToken
Refresh the access token * @param callback - The callback function returning the results.
-
def
refreshFuture(): Future[Unit]
Like refresh but returns a scala.concurrent.Future instead of taking an AsyncResultHandler.
-
def
refreshToken(): JsonObject
The Refresh Token if present parsed as a JsonObject * @return JSON
-
def
revoke(token_type: String, callback: Handler[AsyncResult[Unit]]): AccessToken
Revoke access or refresh token * @param token_type - A String containing the type of token to revoke.
Revoke access or refresh token * @param token_type - A String containing the type of token to revoke. Should be either "access_token" or "refresh_token".
- callback
- The callback function returning the results.
-
def
revokeFuture(token_type: String): Future[Unit]
Like revoke but returns a scala.concurrent.Future instead of taking an AsyncResultHandler.
-
def
setAuthProvider(authProvider: AuthProvider): Unit
Set the auth provider for the User.
Set the auth provider for the User. This is typically used to reattach a detached User with an AuthProvider, e.g. after it has been deserialized. * @param authProvider the AuthProvider - this must be the same type of AuthProvider that originally created the User
- Definition Classes
- User
- def setTrustJWT(trust: Boolean): AccessToken
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
-
def
toString(): String
- Definition Classes
- AnyRef → Any
- def tokenType(): String
-
def
userInfo(callback: Handler[AsyncResult[JsonObject]]): AccessToken
Load the user info as per OIDC spec.
Load the user info as per OIDC spec. * @param callback - The callback function returning the results.
-
def
userInfoFuture(): Future[JsonObject]
Like userInfo but returns a scala.concurrent.Future instead of taking an AsyncResultHandler.
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @throws( ... )