Class ConstraintPolicyResponse

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

@Generated(value="org.openapitools.codegen.languages.JavaClientCodegen", comments="Generator version: 7.23.0") public class ConstraintPolicyResponse extends Object
Usage restrictions attached to Capability Grants. rateLimitPerMinute=0 means fully blocked (emergency freeze); null means no rate limit. The policy is a template: every write is an immutable version, and a grant enforces the version current when it was issued, so an edit applies only to grants issued afterwards.
  • Field Details

  • Constructor Details

    • ConstraintPolicyResponse

      public ConstraintPolicyResponse()
  • Method Details

    • createdAt

      public ConstraintPolicyResponse createdAt(@Nullable OffsetDateTime createdAt)
    • getCreatedAt

      @Nullable public OffsetDateTime getCreatedAt()
      Get createdAt
      Returns:
      createdAt
    • setCreatedAt

      public void setCreatedAt(@Nullable OffsetDateTime createdAt)
    • description

      public ConstraintPolicyResponse description(@Nullable String description)
    • getDescription

      @Nullable public String getDescription()
      Get description
      Returns:
      description
    • setDescription

      public void setDescription(@Nullable String description)
    • id

      public ConstraintPolicyResponse id(@Nullable UUID id)
    • getId

      @Nullable public UUID getId()
      Get id
      Returns:
      id
    • setId

      public void setId(@Nullable UUID id)
    • maxUsage

      public ConstraintPolicyResponse maxUsage(@Nullable Long maxUsage)
    • getMaxUsage

      @Nullable public Long getMaxUsage()
      Total invocation ceiling per grant; null = unlimited. Consumption is counted per grant by the cryptographic service and is not published on this resource.
      Returns:
      maxUsage
    • setMaxUsage

      public void setMaxUsage(@Nullable Long maxUsage)
    • name

      public ConstraintPolicyResponse name(@Nullable String name)
    • getName

      @Nullable public String getName()
      Get name
      Returns:
      name
    • setName

      public void setName(@Nullable String name)
    • rateLimitPerMinute

      public ConstraintPolicyResponse rateLimitPerMinute(@Nullable Integer rateLimitPerMinute)
    • getRateLimitPerMinute

      @Nullable public Integer getRateLimitPerMinute()
      Get rateLimitPerMinute
      Returns:
      rateLimitPerMinute
    • setRateLimitPerMinute

      public void setRateLimitPerMinute(@Nullable Integer rateLimitPerMinute)
    • revokeOnUse

      public ConstraintPolicyResponse revokeOnUse(@Nullable Boolean revokeOnUse)
    • getRevokeOnUse

      @Nullable public Boolean getRevokeOnUse()
      Get revokeOnUse
      Returns:
      revokeOnUse
    • setRevokeOnUse

      public void setRevokeOnUse(@Nullable Boolean revokeOnUse)
    • tenantId

      public ConstraintPolicyResponse tenantId(@Nullable UUID tenantId)
    • getTenantId

      @Nullable public UUID getTenantId()
      Get tenantId
      Returns:
      tenantId
    • setTenantId

      public void setTenantId(@Nullable UUID tenantId)
    • updatedAt

      public ConstraintPolicyResponse updatedAt(@Nullable OffsetDateTime updatedAt)
    • getUpdatedAt

      @Nullable public OffsetDateTime getUpdatedAt()
      Get updatedAt
      Returns:
      updatedAt
    • setUpdatedAt

      public void setUpdatedAt(@Nullable OffsetDateTime updatedAt)
    • validFrom

      public ConstraintPolicyResponse validFrom(@Nullable OffsetDateTime validFrom)
    • getValidFrom

      @Nullable public OffsetDateTime getValidFrom()
      Get validFrom
      Returns:
      validFrom
    • setValidFrom

      public void setValidFrom(@Nullable OffsetDateTime validFrom)
    • validUntil

      public ConstraintPolicyResponse validUntil(@Nullable OffsetDateTime validUntil)
    • getValidUntil

      @Nullable public OffsetDateTime getValidUntil()
      Get validUntil
      Returns:
      validUntil
    • setValidUntil

      public void setValidUntil(@Nullable OffsetDateTime validUntil)
    • version

      public ConstraintPolicyResponse version(@Nonnull Integer version)
    • getVersion

      @Nonnull public Integer getVersion()
      The policy's current version. Create writes version 1 and every edit writes the next one; a grant issued now pins this version and keeps its limits after later edits.
      Returns:
      version
    • setVersion

      public void setVersion(@Nonnull Integer version)
    • 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 ConstraintPolicyResponse
    • 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 ConstraintPolicyResponse
    • fromJson

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

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