public static final class OAuth2TokenClaimsSet.Builder
extends java.lang.Object
OAuth2TokenClaimsSet.| Modifier and Type | Method and Description |
|---|---|
OAuth2TokenClaimsSet.Builder |
audience(java.util.List<java.lang.String> audience)
Sets the audience
(aud) claim, which identifies the recipient(s) that the OAuth 2.0 Token is intended for. |
OAuth2TokenClaimsSet |
build()
Builds a new
OAuth2TokenClaimsSet. |
OAuth2TokenClaimsSet.Builder |
claim(java.lang.String name,
java.lang.Object value)
Sets the claim.
|
OAuth2TokenClaimsSet.Builder |
claims(java.util.function.Consumer<java.util.Map<java.lang.String,java.lang.Object>> claimsConsumer)
A
Consumer to be provided access to the claims allowing the ability to add, replace, or remove. |
OAuth2TokenClaimsSet.Builder |
expiresAt(java.time.Instant expiresAt)
Sets the expiration time
(exp) claim, which identifies the time on or after
which the OAuth 2.0 Token MUST NOT be accepted for processing. |
OAuth2TokenClaimsSet.Builder |
id(java.lang.String jti)
Sets the ID
(jti) claim, which provides a unique identifier for the OAuth 2.0 Token. |
OAuth2TokenClaimsSet.Builder |
issuedAt(java.time.Instant issuedAt)
Sets the issued at
(iat) claim, which identifies the time at which the OAuth 2.0 Token was issued. |
OAuth2TokenClaimsSet.Builder |
issuer(java.lang.String issuer)
Sets the issuer
(iss) claim, which identifies the principal that issued the OAuth 2.0 Token. |
OAuth2TokenClaimsSet.Builder |
notBefore(java.time.Instant notBefore)
Sets the not before
(nbf) claim, which identifies the time before
which the OAuth 2.0 Token MUST NOT be accepted for processing. |
OAuth2TokenClaimsSet.Builder |
subject(java.lang.String subject)
Sets the subject
(sub) claim, which identifies the principal that is the subject of the OAuth 2.0 Token. |
public OAuth2TokenClaimsSet.Builder issuer(java.lang.String issuer)
(iss) claim, which identifies the principal that issued the OAuth 2.0 Token.issuer - the issuer identifierOAuth2TokenClaimsSet.Builderpublic OAuth2TokenClaimsSet.Builder subject(java.lang.String subject)
(sub) claim, which identifies the principal that is the subject of the OAuth 2.0 Token.subject - the subject identifierOAuth2TokenClaimsSet.Builderpublic OAuth2TokenClaimsSet.Builder audience(java.util.List<java.lang.String> audience)
(aud) claim, which identifies the recipient(s) that the OAuth 2.0 Token is intended for.audience - the audience that this OAuth 2.0 Token is intended forOAuth2TokenClaimsSet.Builderpublic OAuth2TokenClaimsSet.Builder expiresAt(java.time.Instant expiresAt)
(exp) claim, which identifies the time on or after
which the OAuth 2.0 Token MUST NOT be accepted for processing.expiresAt - the time on or after which the OAuth 2.0 Token MUST NOT be accepted for processingOAuth2TokenClaimsSet.Builderpublic OAuth2TokenClaimsSet.Builder notBefore(java.time.Instant notBefore)
(nbf) claim, which identifies the time before
which the OAuth 2.0 Token MUST NOT be accepted for processing.notBefore - the time before which the OAuth 2.0 Token MUST NOT be accepted for processingOAuth2TokenClaimsSet.Builderpublic OAuth2TokenClaimsSet.Builder issuedAt(java.time.Instant issuedAt)
(iat) claim, which identifies the time at which the OAuth 2.0 Token was issued.issuedAt - the time at which the OAuth 2.0 Token was issuedOAuth2TokenClaimsSet.Builderpublic OAuth2TokenClaimsSet.Builder id(java.lang.String jti)
(jti) claim, which provides a unique identifier for the OAuth 2.0 Token.jti - the unique identifier for the OAuth 2.0 TokenOAuth2TokenClaimsSet.Builderpublic OAuth2TokenClaimsSet.Builder claim(java.lang.String name, java.lang.Object value)
name - the claim namevalue - the claim valueOAuth2TokenClaimsSet.Builderpublic OAuth2TokenClaimsSet.Builder claims(java.util.function.Consumer<java.util.Map<java.lang.String,java.lang.Object>> claimsConsumer)
Consumer to be provided access to the claims allowing the ability to add, replace, or remove.claimsConsumer - a Consumer of the claimspublic OAuth2TokenClaimsSet build()
OAuth2TokenClaimsSet.OAuth2TokenClaimsSet