public class RequestData extends JWTClaim
| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
CLAIM_NAME |
protected java.time.Clock |
clock |
protected java.time.Instant |
requestDate |
protected byte[] |
significantData |
| Constructor and Description |
|---|
RequestData()
Empty Constructor
|
RequestData(byte[] significantData)
Constructor setting request data to current instant.
|
RequestData(byte[] significantData,
java.time.Instant requestDate)
Default Constructor
|
RequestData(javax.json.JsonObject jsonObject)
JSON Parseable constructor
|
RequestData(org.jose4j.jwt.JwtClaims jwtClaims)
Parse from JWTClaims constructor
|
| Modifier and Type | Method and Description |
|---|---|
void |
convertToJson(javax.json.JsonObjectBuilder jsonObjectBuilder)
Method that should set the objects property to Json representation.
|
boolean |
equals(java.lang.Object o)
Equals checks significantData only.
|
java.lang.String |
getClaimName() |
java.time.Instant |
getRequestDate() |
byte[] |
getSignificantData() |
int |
hashCode() |
void |
parseJson(javax.json.JsonObject jsonObject)
Method to read all properties from a JsonObject into this value object.
|
void |
setRequestDate(java.time.Instant requestDate) |
void |
setSignificantData(byte[] significantData) |
add, addB58, addNotRequired, addNotRequiredB58, getBoolean, getBooleanIfSet, getByteArrayFromB58, getByteArrayFromB58IfSet, getByteArrayFromB64, getByteArrayFromB64IfSet, getByteArrayFromHex, getByteArrayFromHexIfSet, getDate, getDateIfSet, getDouble, getDoubleIfSet, getInt, getIntIfSet, getJsonArray, getJsonArrayIfSet, getJsonObject, getJsonObjectIfSet, getLong, getLongIfSet, getString, getStringIfSet, toJson, toJsonAsString, toStringprotected java.time.Clock clock
public static final java.lang.String CLAIM_NAME
protected byte[] significantData
protected java.time.Instant requestDate
public RequestData()
public RequestData(byte[] significantData,
java.time.Instant requestDate)
significantData - significant request data, which is a hash of the parts of a request that makes it uniquely
identifiable.requestDate - the date the request was generated.public RequestData(byte[] significantData)
significantData - significant request data, which is a hash of the parts of a request that makes it uniquely
identifiable.public RequestData(javax.json.JsonObject jsonObject)
throws javax.json.JsonException
jsonObject - the json object to parsejavax.json.JsonExceptionpublic RequestData(org.jose4j.jwt.JwtClaims jwtClaims)
jwtClaims - the JWT Tokens Claim set to extract data from.public byte[] getSignificantData()
public void setSignificantData(byte[] significantData)
significantData - significant request data, which is a hash of the parts of a request that makes it uniquelypublic java.time.Instant getRequestDate()
public void setRequestDate(java.time.Instant requestDate)
requestDate - the date the request was generated.public void convertToJson(javax.json.JsonObjectBuilder jsonObjectBuilder)
throws javax.json.JsonException
convertToJson in class JSONParsablejsonObjectBuilder - the json object build to use to set key/values in jsonjavax.json.JsonException - if problems occurred converting object to JSON.public void parseJson(javax.json.JsonObject jsonObject)
throws javax.json.JsonException
parseJson in class JSONParsablejsonObject - the json object to read key and values from and set object properties.javax.json.JsonException - if problems occurred converting object from JSON.public java.lang.String getClaimName()
getClaimName in class JWTClaimpublic boolean equals(java.lang.Object o)
equals in class java.lang.Objecto - other objectpublic int hashCode()
hashCode in class java.lang.Object