Class GrantBlock
java.lang.Object
co.ankatech.keymanagement.client.keymanagement.model.GrantBlock
@Generated(value="org.openapitools.codegen.languages.JavaClientCodegen",
comments="Generator version: 7.23.0")
public class GrantBlock
extends Object
Capability Grant embedded summary. capabilities mirrors the grant's JSONB capabilities array. Every grant the orchestrator emits carries exactly ONE capability: a use case declaring [ENCRYPT, DECRYPT] yields TWO grants, [\"ENCRYPT\"] and [\"DECRYPT\"], not one grant carrying both. A cross-kid use case yields one grant carrying [\"REENCRYPT\"] (or [\"RESIGN\"]) over the kid pair.
-
Nested Class Summary
Nested Classes -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionaddCapabilitiesItem(String capabilitiesItem) capabilities(List<String> capabilities) booleanstatic GrantBlockCreate an instance of GrantBlock given an JSON stringGet capabilitiesGet grantIdinthashCode()voidsetCapabilities(List<String> capabilities) voidsetGrantId(UUID grantId) toJson()Convert an instance of GrantBlock to an JSON stringtoString()static voidvalidateJsonElement(com.google.gson.JsonElement jsonElement) Validates the JSON Element and throws an exception if issues foundstatic voidvalidateJsonElementAsCandidate(com.google.gson.JsonElement jsonElement) Validates the JSON Element as a candidate of a oneOf schema: the checks ofvalidateJsonElement(JsonElement), and the element carries no member this model does not declare.
-
Field Details
-
SERIALIZED_NAME_CAPABILITIES
- See Also:
-
SERIALIZED_NAME_GRANT_ID
- See Also:
-
openapiFields
-
openapiRequiredFields
-
-
Constructor Details
-
GrantBlock
public GrantBlock()
-
-
Method Details
-
capabilities
-
addCapabilitiesItem
-
getCapabilities
Get capabilities- Returns:
- capabilities
-
setCapabilities
-
grantId
-
getGrantId
Get grantId- Returns:
- grantId
-
setGrantId
-
equals
-
hashCode
public int hashCode() -
toString
-
validateJsonElement
Validates the JSON Element and throws an exception if issues found- Parameters:
jsonElement- JSON Element- Throws:
IOException- if the JSON Element is invalid with respect to GrantBlock
-
validateJsonElementAsCandidate
public static void validateJsonElementAsCandidate(com.google.gson.JsonElement jsonElement) throws IOException Validates the JSON Element as a candidate of a oneOf schema: the checks ofvalidateJsonElement(JsonElement), and the element carries no member this model does not declare. A oneOf schema without a discriminator tells its candidates apart by their member sets, so a candidate is matched on its closed member set.- Parameters:
jsonElement- JSON Element- Throws:
IOException- if the JSON Element is not a GrantBlock
-
fromJson
Create an instance of GrantBlock given an JSON string- Parameters:
jsonString- JSON string- Returns:
- An instance of GrantBlock
- Throws:
IOException- if the JSON string is invalid with respect to GrantBlock
-
toJson
Convert an instance of GrantBlock to an JSON string- Returns:
- JSON string
-