public class XsuaaToken extends AbstractToken implements AccessToken
tokenBody, tokenHeader| Constructor and Description |
|---|
XsuaaToken(DecodedJwt decodedJwt)
Creates an instance.
|
XsuaaToken(String accessToken)
Creates an instance.
|
| Modifier and Type | Method and Description |
|---|---|
GrantType |
getGrantType() |
Principal |
getPrincipal() |
Set<String> |
getScopes() |
Service |
getService() |
String |
getSubaccountId()
Returns subaccount identifier which is in most cases same like the identity
zone.
|
String |
getSubdomain()
Returns the value of the subdomain (zdn) from the external attribute ext_attr
(ext_attr) claim.
|
String |
getZoneId() |
boolean |
hasLocalScope(String scope)
Check if a local scope is available in the authentication token.
|
boolean |
hasScope(String scope) |
XsuaaToken |
withScopeConverter(ScopeConverter converter)
Configures a scope converter, e.g.
|
createPrincipalByName, equals, getAudiences, getClaimAsJsonObject, getClaimAsString, getClaimAsStringList, getExpiration, getHeaderParameterAsString, getNotBefore, getTokenValue, hasClaim, hashCode, hasHeaderParameter, isExpired, toStringclone, finalize, getClass, notify, notifyAll, wait, wait, waitgetAttributeFromClaimAsString, getAttributeFromClaimAsStringListgetAudiences, getClaimAsJsonObject, getClaimAsString, getClaimAsStringList, getExpiration, getHeaderParameterAsString, getNotBefore, getTokenValue, hasClaim, hasHeaderParameter, isExpiredpublic XsuaaToken(@Nonnull DecodedJwt decodedJwt)
decodedJwt - the decoded jwtpublic XsuaaToken withScopeConverter(@Nullable ScopeConverter converter)
hasLocalScope(String)converter - the scope converter, e.g. XsuaaScopeConverterpublic Set<String> getScopes()
getScopes in interface AccessTokenpublic Principal getPrincipal()
getPrincipal in interface Tokenpublic Service getService()
getService in interface Tokenpublic boolean hasScope(String scope)
hasScope in interface AccessTokenpublic boolean hasLocalScope(@Nonnull String scope)
ScopeConverter to be configured with
withScopeConverter(ScopeConverter).hasLocalScope in interface AccessTokenscope - name of local scope (without the appId)public GrantType getGrantType()
getGrantType in interface AccessToken@Nullable public String getSubdomain()
null.null@Nullable public String getSubaccountId()
getZoneId().nullpublic String getZoneId()
getZoneId in interface TokengetZoneId in class AbstractTokenCopyright © 2020. All rights reserved.