public class EvidenceArrayConstraint extends ArrayList<EvidenceConstraint> implements Constraint
verified_claims/verification/evidence.modCount| Constructor and Description |
|---|
EvidenceArrayConstraint() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
exists()
Check if the key that represents the constraint exists.
|
static EvidenceArrayConstraint |
extract(Map<?,?> map,
String key)
Create an
EvidenceArrayConstraint instance from an object in the given map. |
boolean |
isNull()
Check if the value of the constraint is null.
|
void |
setExists(boolean exists)
Set the existence of the constraint.
|
void |
setNull(boolean isNull)
Set the boolean flag that indicates that the value of the constraint is null.
|
String |
toJson()
Convert this object into JSON in the way conforming to the structure
defined in 5.
|
String |
toJson(boolean pretty)
Convert this object into JSON in the way conforming to the structure
defined in 5.
|
List<Map<String,Object>> |
toList()
Create a
List instance that represents this object in the way
conforming to the structure defined in 5. |
add, add, addAll, addAll, clear, clone, contains, ensureCapacity, forEach, get, indexOf, isEmpty, iterator, lastIndexOf, listIterator, listIterator, remove, remove, removeAll, removeIf, removeRange, replaceAll, retainAll, set, size, sort, spliterator, subList, toArray, toArray, trimToSizeequals, hashCodecontainsAll, toStringfinalize, getClass, notify, notifyAll, wait, wait, waitcontainsAll, equals, hashCodeparallelStream, streampublic boolean exists()
Constraint
For example, exists() method of an instance that represents
given_name in the JSON below will return true.
{
"verified_claims": {
"claims": {
"given_name": null
}
}
}
exists in interface Constrainttrue if the key that represents the constraint exists.public void setExists(boolean exists)
exists - true to indicate that the constraint exists.public boolean isNull()
Constraint
For example, isNull() method of an instance that represents
given_name in the JSON below will return true.
{
"verified_claims": {
"claims": {
"given_name": null
}
}
}
But, the method returns false in the following case.
{
"verified_claims": {
"claims": {
"given_name": {
}
}
}
}
isNull in interface Constrainttrue if the value of the constraint is null.public void setNull(boolean isNull)
isNull - true to indicate that the value of the constraint is null.public static EvidenceArrayConstraint extract(Map<?,?> map, String key) throws ConstraintException
EvidenceArrayConstraint instance from an object in the given map.map - A map that may contain "evidence".key - The key that identifies the object in the map. In normal cases,
the key is "evidence".EvidenceArrayConstraint instance that represents
"evidence". Even if the map does not contain the given
key, an instance of EvidenceArrayConstraint is returned.ConstraintException - The structure of the map does not conform to the specification
(OpenID Connect for Identity Assurance 1.0).public List<Map<String,Object>> toList()
List instance that represents this object in the way
conforming to the structure defined in 5. Requesting Verified Claims of OpenID Connect for Identity Assurance 1.0.public String toJson()
This method is an alias of toJson(false).
toList() returns
null, this method returns "null" (a String
instance which consists of 'n', 'u', 'l'
and 'l').public String toJson(boolean pretty)
pretty - true to make the output more human-readable.toList() returns
null, this method returns "null" (a String
instance which consists of 'n', 'u', 'l'
and 'l').Copyright © 2021. All rights reserved.