Class KeyAuthorizationReferences

java.lang.Object
co.ankatech.keymanagement.client.keymanagement.model.KeyAuthorizationReferences

@Generated(value="org.openapitools.codegen.languages.JavaClientCodegen", comments="Generator version: 7.23.0") public class KeyAuthorizationReferences extends Object
How many authorizations reference this key, by kind. This is a reading: no key command is gated on it, and every key command remains available at every count. internalUseCases counts internal crypto use cases that are not deleted, ACTIVE and SUSPENDED alike. cryptographicExchanges counts exchanges in a non-terminal status (DRAFT, READY, ACTIVE, SUSPENDED) that name the key; a DRAFT or READY exchange references the key before its grant exists. capabilityGrants counts only standalone capability grants that are not deleted: a grant owned by an exchange or an internal use case is counted under its owner, never as a standalone grant. A wildcard grant names no key and is not counted for any key. total is the sum of the three kinds.
  • Field Details

  • Constructor Details

    • KeyAuthorizationReferences

      public KeyAuthorizationReferences()
  • Method Details

    • capabilityGrants

      public KeyAuthorizationReferences capabilityGrants(@Nonnull Integer capabilityGrants)
    • getCapabilityGrants

      @Nonnull public Integer getCapabilityGrants()
      Standalone capability grants that reference the key and are not deleted. A grant owned by an exchange or an internal use case is counted under its owner, and a wildcard grant is not counted. minimum: 0
      Returns:
      capabilityGrants
    • setCapabilityGrants

      public void setCapabilityGrants(@Nonnull Integer capabilityGrants)
    • cryptographicExchanges

      public KeyAuthorizationReferences cryptographicExchanges(@Nonnull Integer cryptographicExchanges)
    • getCryptographicExchanges

      @Nonnull public Integer getCryptographicExchanges()
      Cryptographic exchanges in a non-terminal status (DRAFT, READY, ACTIVE, SUSPENDED) that reference the key and are not deleted. minimum: 0
      Returns:
      cryptographicExchanges
    • setCryptographicExchanges

      public void setCryptographicExchanges(@Nonnull Integer cryptographicExchanges)
    • internalUseCases

      public KeyAuthorizationReferences internalUseCases(@Nonnull Integer internalUseCases)
    • getInternalUseCases

      @Nonnull public Integer getInternalUseCases()
      Internal crypto use cases that reference the key and are not deleted (ACTIVE or SUSPENDED). minimum: 0
      Returns:
      internalUseCases
    • setInternalUseCases

      public void setInternalUseCases(@Nonnull Integer internalUseCases)
    • total

      public KeyAuthorizationReferences total(@Nonnull Integer total)
    • getTotal

      @Nonnull public Integer getTotal()
      The sum of internalUseCases, cryptographicExchanges and capabilityGrants. Zero means nothing references the key. minimum: 0
      Returns:
      total
    • setTotal

      public void setTotal(@Nonnull Integer total)
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • validateJsonElement

      public static void validateJsonElement(com.google.gson.JsonElement jsonElement) throws IOException
      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 KeyAuthorizationReferences
    • 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 of validateJsonElement(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 KeyAuthorizationReferences
    • fromJson

      public static KeyAuthorizationReferences fromJson(String jsonString) throws IOException
      Create an instance of KeyAuthorizationReferences given an JSON string
      Parameters:
      jsonString - JSON string
      Returns:
      An instance of KeyAuthorizationReferences
      Throws:
      IOException - if the JSON string is invalid with respect to KeyAuthorizationReferences
    • toJson

      public String toJson()
      Convert an instance of KeyAuthorizationReferences to an JSON string
      Returns:
      JSON string