Class JsonWebToken.Payload
- java.lang.Object
-
- java.util.AbstractMap<java.lang.String,java.lang.Object>
-
- com.google.api.client.util.GenericData
-
- com.google.api.client.json.GenericJson
-
- com.google.api.client.json.webtoken.JsonWebToken.Payload
-
- All Implemented Interfaces:
java.lang.Cloneable,java.util.Map<java.lang.String,java.lang.Object>
- Enclosing class:
- JsonWebToken
public static class JsonWebToken.Payload extends GenericJson
Payload as specified in Reserved Claim Names.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.google.api.client.util.GenericData
GenericData.Flags
-
-
Field Summary
Fields Modifier and Type Field Description private java.lang.ObjectaudienceAudience claim that identifies the audience that the JWT is intended for (should either be aStringor aList<String>) ornullfor none.private java.lang.LongexpirationTimeSecondsExpiration time claim that identifies the expiration time (in seconds) on or after which the token MUST NOT be accepted for processing ornullfor none.private java.lang.LongissuedAtTimeSecondsIssued at claim that identifies the time (in seconds) at which the JWT was issued ornullfor none.private java.lang.StringissuerIssuer claim that identifies the principal that issued the JWT ornullfor none.private java.lang.StringjwtIdJWT ID claim that provides a unique identifier for the JWT ornullfor none.private java.lang.LongnotBeforeTimeSecondsNot before claim that identifies the time (in seconds) before which the token MUST NOT be accepted for processing ornullfor none.private java.lang.StringsubjectSubject claim identifying the principal that is the subject of the JWT ornullfor none.private java.lang.StringtypeType claim that is used to declare a type for the contents of this JWT Claims Set ornullfor none.
-
Constructor Summary
Constructors Constructor Description Payload()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description JsonWebToken.Payloadclone()Makes a "deep" clone of the generic data, in which the clone is completely independent of the original.java.lang.ObjectgetAudience()Returns the audience claim that identifies the audience that the JWT is intended for (should either be aStringor aList<String>) ornullfor none.java.util.List<java.lang.String>getAudienceAsList()Returns the list of audience claim that identifies the audience that the JWT is intended for or empty for none.java.lang.LonggetExpirationTimeSeconds()Returns the expiration time (in seconds) claim that identifies the expiration time on or after which the token MUST NOT be accepted for processing ornullfor none.java.lang.LonggetIssuedAtTimeSeconds()Returns the issued at claim that identifies the time (in seconds) at which the JWT was issued ornullfor none.java.lang.StringgetIssuer()Returns the issuer claim that identifies the principal that issued the JWT ornullfor none.java.lang.StringgetJwtId()Returns the JWT ID claim that provides a unique identifier for the JWT ornullfor none.java.lang.LonggetNotBeforeTimeSeconds()Returns the not before claim that identifies the time (in seconds) before which the token MUST NOT be accepted for processing ornullfor none.java.lang.StringgetSubject()Returns the subject claim identifying the principal that is the subject of the JWT ornullfor none.java.lang.StringgetType()Returns the type claim that is used to declare a type for the contents of this JWT Claims Set ornullfor none.JsonWebToken.Payloadset(java.lang.String fieldName, java.lang.Object value)Sets the given field value (may benull) for the given field name.JsonWebToken.PayloadsetAudience(java.lang.Object audience)Sets the audience claim that identifies the audience that the JWT is intended for (should either be aStringor aList<String>) ornullfor none.JsonWebToken.PayloadsetExpirationTimeSeconds(java.lang.Long expirationTimeSeconds)Sets the expiration time claim that identifies the expiration time (in seconds) on or after which the token MUST NOT be accepted for processing ornullfor none.JsonWebToken.PayloadsetIssuedAtTimeSeconds(java.lang.Long issuedAtTimeSeconds)Sets the issued at claim that identifies the time (in seconds) at which the JWT was issued ornullfor none.JsonWebToken.PayloadsetIssuer(java.lang.String issuer)Sets the issuer claim that identifies the principal that issued the JWT ornullfor none.JsonWebToken.PayloadsetJwtId(java.lang.String jwtId)Sets the JWT ID claim that provides a unique identifier for the JWT ornullfor none.JsonWebToken.PayloadsetNotBeforeTimeSeconds(java.lang.Long notBeforeTimeSeconds)Sets the not before claim that identifies the time (in seconds) before which the token MUST NOT be accepted for processing ornullfor none.JsonWebToken.PayloadsetSubject(java.lang.String subject)Sets the subject claim identifying the principal that is the subject of the JWT ornullfor none.JsonWebToken.PayloadsetType(java.lang.String type)Sets the type claim that is used to declare a type for the contents of this JWT Claims Set ornullfor none.-
Methods inherited from class com.google.api.client.json.GenericJson
getFactory, setFactory, toPrettyString, toString
-
Methods inherited from class com.google.api.client.util.GenericData
entrySet, equals, get, getClassInfo, getUnknownKeys, hashCode, put, putAll, remove, setUnknownKeys
-
Methods inherited from class java.util.AbstractMap
clear, containsKey, containsValue, isEmpty, keySet, size, values
-
-
-
-
Field Detail
-
expirationTimeSeconds
private java.lang.Long expirationTimeSeconds
Expiration time claim that identifies the expiration time (in seconds) on or after which the token MUST NOT be accepted for processing ornullfor none.
-
notBeforeTimeSeconds
private java.lang.Long notBeforeTimeSeconds
Not before claim that identifies the time (in seconds) before which the token MUST NOT be accepted for processing ornullfor none.
-
issuedAtTimeSeconds
private java.lang.Long issuedAtTimeSeconds
Issued at claim that identifies the time (in seconds) at which the JWT was issued ornullfor none.
-
issuer
private java.lang.String issuer
Issuer claim that identifies the principal that issued the JWT ornullfor none.
-
audience
private java.lang.Object audience
Audience claim that identifies the audience that the JWT is intended for (should either be aStringor aList<String>) ornullfor none.
-
jwtId
private java.lang.String jwtId
JWT ID claim that provides a unique identifier for the JWT ornullfor none.
-
type
private java.lang.String type
Type claim that is used to declare a type for the contents of this JWT Claims Set ornullfor none.
-
subject
private java.lang.String subject
Subject claim identifying the principal that is the subject of the JWT ornullfor none.
-
-
Method Detail
-
getExpirationTimeSeconds
public final java.lang.Long getExpirationTimeSeconds()
Returns the expiration time (in seconds) claim that identifies the expiration time on or after which the token MUST NOT be accepted for processing ornullfor none.
-
setExpirationTimeSeconds
public JsonWebToken.Payload setExpirationTimeSeconds(java.lang.Long expirationTimeSeconds)
Sets the expiration time claim that identifies the expiration time (in seconds) on or after which the token MUST NOT be accepted for processing ornullfor none.Overriding is only supported for the purpose of calling the super implementation and changing the return type, but nothing else.
-
getNotBeforeTimeSeconds
public final java.lang.Long getNotBeforeTimeSeconds()
Returns the not before claim that identifies the time (in seconds) before which the token MUST NOT be accepted for processing ornullfor none.
-
setNotBeforeTimeSeconds
public JsonWebToken.Payload setNotBeforeTimeSeconds(java.lang.Long notBeforeTimeSeconds)
Sets the not before claim that identifies the time (in seconds) before which the token MUST NOT be accepted for processing ornullfor none.Overriding is only supported for the purpose of calling the super implementation and changing the return type, but nothing else.
-
getIssuedAtTimeSeconds
public final java.lang.Long getIssuedAtTimeSeconds()
Returns the issued at claim that identifies the time (in seconds) at which the JWT was issued ornullfor none.
-
setIssuedAtTimeSeconds
public JsonWebToken.Payload setIssuedAtTimeSeconds(java.lang.Long issuedAtTimeSeconds)
Sets the issued at claim that identifies the time (in seconds) at which the JWT was issued ornullfor none.Overriding is only supported for the purpose of calling the super implementation and changing the return type, but nothing else.
-
getIssuer
public final java.lang.String getIssuer()
Returns the issuer claim that identifies the principal that issued the JWT ornullfor none.
-
setIssuer
public JsonWebToken.Payload setIssuer(java.lang.String issuer)
Sets the issuer claim that identifies the principal that issued the JWT ornullfor none.Overriding is only supported for the purpose of calling the super implementation and changing the return type, but nothing else.
-
getAudience
public final java.lang.Object getAudience()
Returns the audience claim that identifies the audience that the JWT is intended for (should either be aStringor aList<String>) ornullfor none.
-
getAudienceAsList
public final java.util.List<java.lang.String> getAudienceAsList()
Returns the list of audience claim that identifies the audience that the JWT is intended for or empty for none.
-
setAudience
public JsonWebToken.Payload setAudience(java.lang.Object audience)
Sets the audience claim that identifies the audience that the JWT is intended for (should either be aStringor aList<String>) ornullfor none.Overriding is only supported for the purpose of calling the super implementation and changing the return type, but nothing else.
-
getJwtId
public final java.lang.String getJwtId()
Returns the JWT ID claim that provides a unique identifier for the JWT ornullfor none.
-
setJwtId
public JsonWebToken.Payload setJwtId(java.lang.String jwtId)
Sets the JWT ID claim that provides a unique identifier for the JWT ornullfor none.Overriding is only supported for the purpose of calling the super implementation and changing the return type, but nothing else.
-
getType
public final java.lang.String getType()
Returns the type claim that is used to declare a type for the contents of this JWT Claims Set ornullfor none.
-
setType
public JsonWebToken.Payload setType(java.lang.String type)
Sets the type claim that is used to declare a type for the contents of this JWT Claims Set ornullfor none.Overriding is only supported for the purpose of calling the super implementation and changing the return type, but nothing else.
-
getSubject
public final java.lang.String getSubject()
Returns the subject claim identifying the principal that is the subject of the JWT ornullfor none.
-
setSubject
public JsonWebToken.Payload setSubject(java.lang.String subject)
Sets the subject claim identifying the principal that is the subject of the JWT ornullfor none.Overriding is only supported for the purpose of calling the super implementation and changing the return type, but nothing else.
-
set
public JsonWebToken.Payload set(java.lang.String fieldName, java.lang.Object value)
Description copied from class:GenericDataSets the given field value (may benull) for the given field name. Any existing value for the field will be overwritten. It may be more slightly more efficient thanGenericData.put(String, Object)because it avoids accessing the field's original value.Overriding is only supported for the purpose of calling the super implementation and changing the return type, but nothing else.
- Overrides:
setin classGenericJson
-
clone
public JsonWebToken.Payload clone()
Description copied from class:GenericDataMakes a "deep" clone of the generic data, in which the clone is completely independent of the original.- Overrides:
clonein classGenericJson
-
-