Class CapabilityGrantEffectiveRestrictions

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

@Generated(value="org.openapitools.codegen.languages.JavaClientCodegen", comments="Generator version: 7.23.0") public class CapabilityGrantEffectiveRestrictions extends Object
The Constraint Policy version that governed a Capability Grant at the instant asked about, with its limits and schedule. Every version member is null when no version was pinned to the grant at that instant: the grant was then unlimited. The schedule time zone is the platform setting's current value.
  • Field Details

  • Constructor Details

    • CapabilityGrantEffectiveRestrictions

      public CapabilityGrantEffectiveRestrictions()
  • Method Details

    • assignedAt

      public CapabilityGrantEffectiveRestrictions assignedAt(@Nullable OffsetDateTime assignedAt)
    • getAssignedAt

      @Nullable public OffsetDateTime getAssignedAt()
      When that assignment took effect; null when no version was pinned.
      Returns:
      assignedAt
    • setAssignedAt

      public void setAssignedAt(@Nullable OffsetDateTime assignedAt)
    • assignmentId

      public CapabilityGrantEffectiveRestrictions assignmentId(@Nullable UUID assignmentId)
    • getAssignmentId

      @Nullable public UUID getAssignmentId()
      The assignment in force at that instant; null when no version was pinned.
      Returns:
      assignmentId
    • setAssignmentId

      public void setAssignmentId(@Nullable UUID assignmentId)
    • at

    • getAt

      @Nonnull public OffsetDateTime getAt()
      The instant asked about.
      Returns:
      at
    • setAt

      public void setAt(@Nonnull OffsetDateTime at)
    • constraintPolicyId

      public CapabilityGrantEffectiveRestrictions constraintPolicyId(@Nullable UUID constraintPolicyId)
    • getConstraintPolicyId

      @Nullable public UUID getConstraintPolicyId()
      The Constraint Policy of the version in force; null when none.
      Returns:
      constraintPolicyId
    • setConstraintPolicyId

      public void setConstraintPolicyId(@Nullable UUID constraintPolicyId)
    • constraintPolicyVersion

      public CapabilityGrantEffectiveRestrictions constraintPolicyVersion(@Nullable Integer constraintPolicyVersion)
    • getConstraintPolicyVersion

      @Nullable public Integer getConstraintPolicyVersion()
      The number of the version in force; null when none.
      Returns:
      constraintPolicyVersion
    • setConstraintPolicyVersion

      public void setConstraintPolicyVersion(@Nullable Integer constraintPolicyVersion)
    • constraintPolicyVersionId

      public CapabilityGrantEffectiveRestrictions constraintPolicyVersionId(@Nullable UUID constraintPolicyVersionId)
    • getConstraintPolicyVersionId

      @Nullable public UUID getConstraintPolicyVersionId()
      The Constraint Policy version in force; null when none.
      Returns:
      constraintPolicyVersionId
    • setConstraintPolicyVersionId

      public void setConstraintPolicyVersionId(@Nullable UUID constraintPolicyVersionId)
    • grantId

      public CapabilityGrantEffectiveRestrictions grantId(@Nonnull UUID grantId)
    • getGrantId

      @Nonnull public UUID getGrantId()
      The Capability Grant.
      Returns:
      grantId
    • setGrantId

      public void setGrantId(@Nonnull UUID grantId)
    • maxUsage

      public CapabilityGrantEffectiveRestrictions maxUsage(@Nullable Long maxUsage)
    • getMaxUsage

      @Nullable public Long getMaxUsage()
      Total invocation ceiling of the grant; null = unlimited.
      Returns:
      maxUsage
    • setMaxUsage

      public void setMaxUsage(@Nullable Long maxUsage)
    • rateLimitPerMinute

      public CapabilityGrantEffectiveRestrictions rateLimitPerMinute(@Nullable Integer rateLimitPerMinute)
    • getRateLimitPerMinute

      @Nullable public Integer getRateLimitPerMinute()
      Ceiling per minute; 0 = fully blocked, null = no rate limit.
      Returns:
      rateLimitPerMinute
    • setRateLimitPerMinute

      public void setRateLimitPerMinute(@Nullable Integer rateLimitPerMinute)
    • revokeOnUse

      public CapabilityGrantEffectiveRestrictions revokeOnUse(@Nonnull Boolean revokeOnUse)
    • getRevokeOnUse

      @Nonnull public Boolean getRevokeOnUse()
      When true, the grant is consumed by its first admitted invocation.
      Returns:
      revokeOnUse
    • setRevokeOnUse

      public void setRevokeOnUse(@Nonnull Boolean revokeOnUse)
    • scheduleEnd

      public CapabilityGrantEffectiveRestrictions scheduleEnd(@Nullable String scheduleEnd)
    • getScheduleEnd

      @Nullable public String getScheduleEnd()
      End of the daily window, HH:mm, exclusive; earlier than the start for an overnight window; null when the version has no schedule.
      Returns:
      scheduleEnd
    • setScheduleEnd

      public void setScheduleEnd(@Nullable String scheduleEnd)
    • scheduleStart

      public CapabilityGrantEffectiveRestrictions scheduleStart(@Nullable String scheduleStart)
    • getScheduleStart

      @Nullable public String getScheduleStart()
      Start of the daily window, HH:mm, inclusive; null when the version has no schedule.
      Returns:
      scheduleStart
    • setScheduleStart

      public void setScheduleStart(@Nullable String scheduleStart)
    • scheduleTimeZone

      public CapabilityGrantEffectiveRestrictions scheduleTimeZone(@Nonnull String scheduleTimeZone)
    • getScheduleTimeZone

      @Nonnull public String getScheduleTimeZone()
      The time zone in which the schedule is evaluated: the platform setting authorization.schedule.timezone, an IANA region zone or UTC. One platform value governs every schedule.
      Returns:
      scheduleTimeZone
    • setScheduleTimeZone

      public void setScheduleTimeZone(@Nonnull String scheduleTimeZone)
    • scheduleWeekdays

      public CapabilityGrantEffectiveRestrictions scheduleWeekdays(@Nullable List<Integer> scheduleWeekdays)
    • addScheduleWeekdaysItem

      public CapabilityGrantEffectiveRestrictions addScheduleWeekdaysItem(Integer scheduleWeekdaysItem)
    • getScheduleWeekdays

      @Nullable public List<Integer> getScheduleWeekdays()
      ISO weekdays (1 = Monday .. 7 = Sunday) on which the daily window opens, ascending; null when the version has no schedule.
      Returns:
      scheduleWeekdays
    • setScheduleWeekdays

      public void setScheduleWeekdays(@Nullable List<Integer> scheduleWeekdays)
    • validFrom

      public CapabilityGrantEffectiveRestrictions validFrom(@Nullable OffsetDateTime validFrom)
    • getValidFrom

      @Nullable public OffsetDateTime getValidFrom()
      Start of validity; null = effective immediately.
      Returns:
      validFrom
    • setValidFrom

      public void setValidFrom(@Nullable OffsetDateTime validFrom)
    • validUntil

      public CapabilityGrantEffectiveRestrictions validUntil(@Nullable OffsetDateTime validUntil)
    • getValidUntil

      @Nullable public OffsetDateTime getValidUntil()
      End of validity; null = never expires.
      Returns:
      validUntil
    • setValidUntil

      public void setValidUntil(@Nullable OffsetDateTime validUntil)
    • 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 CapabilityGrantEffectiveRestrictions
    • 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 CapabilityGrantEffectiveRestrictions
    • fromJson

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

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