Class KeyRotationScheduleView

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

@Generated(value="org.openapitools.codegen.languages.JavaClientCodegen", comments="Generator version: 7.23.0") public class KeyRotationScheduleView extends Object
The key's effective automatic-rotation schedule: its enablement, the cadence it follows and where that comes from, its usage options, the ceilings applied, and the next instant the key is due.
  • Field Details

  • Constructor Details

    • KeyRotationScheduleView

      public KeyRotationScheduleView()
  • Method Details

    • getClampedByAsString

      public String getClampedByAsString()
      The wire value of clampedBy: what the server sent, verbatim.
      • For a value this release declares, the same wire value the enum names.
      • For a value it does not declare (one a later server added), the server's wire value verbatim, while getClampedBy() reads UNKNOWN_DEFAULT_OPEN_API; writing this model sends that wire value back, never the sentinel.
      • For an absent member, null.
      Returns:
      the wire value, or null when the member is absent
    • getSourceAsString

      public String getSourceAsString()
      The wire value of source: what the server sent, verbatim.
      • For a value this release declares, the same wire value the enum names.
      • For a value it does not declare (one a later server added), the server's wire value verbatim, while getSource() reads UNKNOWN_DEFAULT_OPEN_API; writing this model sends that wire value back, never the sentinel.
      • For an absent member, null.
      Returns:
      the wire value, or null when the member is absent
    • getStateAsString

      public String getStateAsString()
      The wire value of state: what the server sent, verbatim.
      • For a value this release declares, the same wire value the enum names.
      • For a value it does not declare (one a later server added), the server's wire value verbatim, while getState() reads UNKNOWN_DEFAULT_OPEN_API; writing this model sends that wire value back, never the sentinel.
      • For an absent member, null.
      Returns:
      the wire value, or null when the member is absent
    • autoRotationEnabled

      public KeyRotationScheduleView autoRotationEnabled(@Nonnull Boolean autoRotationEnabled)
    • getAutoRotationEnabled

      @Nonnull public Boolean getAutoRotationEnabled()
      Whether automatic rotation is enabled for the key. False for a key whose schedule was never set.
      Returns:
      autoRotationEnabled
    • setAutoRotationEnabled

      public void setAutoRotationEnabled(@Nonnull Boolean autoRotationEnabled)
    • baseInstant

      public KeyRotationScheduleView baseInstant(@Nullable OffsetDateTime baseInstant)
    • getBaseInstant

      @Nullable public OffsetDateTime getBaseInstant()
      Activation of the key's primary material, from which the interval is measured. Null when the key has no primary material.
      Returns:
      baseInstant
    • setBaseInstant

      public void setBaseInstant(@Nullable OffsetDateTime baseInstant)
    • ceiling

      public KeyRotationScheduleView ceiling(@Nonnull RotationScheduleCeiling ceiling)
    • getCeiling

      @Nonnull public RotationScheduleCeiling getCeiling()
      Compliance-pack maximum cryptoperiod of the key's class.
      Returns:
      ceiling
    • setCeiling

      public void setCeiling(@Nonnull RotationScheduleCeiling ceiling)
    • clampedBy

      public KeyRotationScheduleView clampedBy(@Nonnull RotationScheduleClamp clampedBy)
    • getClampedBy

      @Nonnull public RotationScheduleClamp getClampedBy()
      Which bound brought the next rotation forward.
      Returns:
      clampedBy
    • setClampedBy

      public void setClampedBy(@Nonnull RotationScheduleClamp clampedBy)
    • configuredInterval

      public KeyRotationScheduleView configuredInterval(@Nullable String configuredInterval)
    • getConfiguredInterval

      @Nullable public String getConfiguredInterval()
      Interval of the effective TIME_BASED trigger, as an ISO-8601 period. Null when the triggers carry none.
      Returns:
      configuredInterval
    • setConfiguredInterval

      public void setConfiguredInterval(@Nullable String configuredInterval)
    • effectiveFrom

      public KeyRotationScheduleView effectiveFrom(@Nonnull OffsetDateTime effectiveFrom)
    • getEffectiveFrom

      @Nonnull public OffsetDateTime getEffectiveFrom()
      Newest instant at which one of those policies took effect; no rotation is due before it.
      Returns:
      effectiveFrom
    • setEffectiveFrom

      public void setEffectiveFrom(@Nonnull OffsetDateTime effectiveFrom)
    • effectiveInterval

      public KeyRotationScheduleView effectiveInterval(@Nullable String effectiveInterval)
    • getEffectiveInterval

      @Nullable public String getEffectiveInterval()
      Interval the next rotation is computed with, after the ceilings: the configured interval, or the bound clampedBy names. Null when there is no configured interval or the key has no primary material.
      Returns:
      effectiveInterval
    • setEffectiveInterval

      public void setEffectiveInterval(@Nullable String effectiveInterval)
    • inheritedInterval

      public KeyRotationScheduleView inheritedInterval(@Nullable String inheritedInterval)
    • getInheritedInterval

      @Nullable public String getInheritedInterval()
      Configured interval the key would follow without an interval of its own, as an ISO-8601 period, before the ceilings: the tenant default's when the tenant has a default, else the deployment default's. Null when that default sets no interval (a tenant default with no triggers included), so removing the key's own interval would leave it with no interval.
      Returns:
      inheritedInterval
    • setInheritedInterval

      public void setInheritedInterval(@Nullable String inheritedInterval)
    • intervalConstraints

      public KeyRotationScheduleView intervalConstraints(@Nonnull RotationIntervalConstraints intervalConstraints)
    • getIntervalConstraints

      @Nonnull public RotationIntervalConstraints getIntervalConstraints()
      What a write on this deployment admits beyond the interval grammar: its shortest interval. Present on every read and write answer.
      Returns:
      intervalConstraints
    • setIntervalConstraints

      public void setIntervalConstraints(@Nonnull RotationIntervalConstraints intervalConstraints)
    • kid

      public KeyRotationScheduleView kid(@Nonnull String kid)
    • getKid

      @Nonnull public String getKid()
      Stable key id.
      Returns:
      kid
    • setKid

      public void setKid(@Nonnull String kid)
    • nextDueAt

      public KeyRotationScheduleView nextDueAt(@Nullable OffsetDateTime nextDueAt)
    • getNextDueAt

      @Nullable public OffsetDateTime getNextDueAt()
      Instant the key is due for automatic rotation. Set only when state is SCHEDULED. Never earlier than effectiveFrom, except that it never passes the end of the key's maximum cryptoperiod (ceiling): then it may lie in the past, and the key is overdue.
      Returns:
      nextDueAt
    • setNextDueAt

      public void setNextDueAt(@Nullable OffsetDateTime nextDueAt)
    • policyVersions

      public KeyRotationScheduleView policyVersions(@Nonnull RotationSchedulePolicyVersions policyVersions)
    • getPolicyVersions

      @Nonnull public RotationSchedulePolicyVersions getPolicyVersions()
      Version of each policy the schedule is composed from.
      Returns:
      policyVersions
    • setPolicyVersions

      public void setPolicyVersions(@Nonnull RotationSchedulePolicyVersions policyVersions)
    • rotateOnSoftUsageLimit

      public KeyRotationScheduleView rotateOnSoftUsageLimit(@Nonnull Boolean rotateOnSoftUsageLimit)
    • getRotateOnSoftUsageLimit

      @Nonnull public Boolean getRotateOnSoftUsageLimit()
      Whether the key rotates when its usage count reaches its soft usage limit, while autoRotationEnabled is true. False for a key whose schedule was never set.
      Returns:
      rotateOnSoftUsageLimit
    • setRotateOnSoftUsageLimit

      public void setRotateOnSoftUsageLimit(@Nonnull Boolean rotateOnSoftUsageLimit)
    • rotateOnUsageExhaustion

      public KeyRotationScheduleView rotateOnUsageExhaustion(@Nonnull Boolean rotateOnUsageExhaustion)
    • getRotateOnUsageExhaustion

      @Nonnull public Boolean getRotateOnUsageExhaustion()
      Whether the key rotates when its usage count reaches its maximum usage limit, while autoRotationEnabled is true. False for a key whose schedule was never set.
      Returns:
      rotateOnUsageExhaustion
    • setRotateOnUsageExhaustion

      public void setRotateOnUsageExhaustion(@Nonnull Boolean rotateOnUsageExhaustion)
    • source

      public KeyRotationScheduleView source(@Nonnull RotationScheduleSource source)
    • getSource

      @Nonnull public RotationScheduleSource getSource()
      Which policy the triggers come from.
      Returns:
      source
    • setSource

      public void setSource(@Nonnull RotationScheduleSource source)
    • state

      public KeyRotationScheduleView state(@Nonnull KeyRotationScheduleState state)
    • getState

      @Nonnull public KeyRotationScheduleState getState()
      Where the key stands with respect to automatic rotation.
      Returns:
      state
    • setState

      public void setState(@Nonnull KeyRotationScheduleState state)
    • toleranceWindow

      public KeyRotationScheduleView toleranceWindow(@Nullable String toleranceWindow)
    • getToleranceWindow

      @Nullable public String getToleranceWindow()
      Window after nextDueAt within which the rotation may be performed, as an ISO-8601 duration: one hundredth of effectiveInterval, measured from baseInstant on the UTC calendar, at most PT6H; raising nextDueAt to effectiveFrom does not widen it. Set exactly when nextDueAt is.
      Returns:
      toleranceWindow
    • setToleranceWindow

      public void setToleranceWindow(@Nullable String toleranceWindow)
    • triggers

      public KeyRotationScheduleView triggers(@Nonnull List<TimeBasedTrigger> triggers)
    • addTriggersItem

      public KeyRotationScheduleView addTriggersItem(TimeBasedTrigger triggersItem)
    • getTriggers

      @Nonnull public List<TimeBasedTrigger> getTriggers()
      Effective triggers: the key's override, else the tenant default, else the deployment default. Empty when none sets a cadence.
      Returns:
      triggers
    • setTriggers

      public void setTriggers(@Nonnull List<TimeBasedTrigger> triggers)
    • version

      public KeyRotationScheduleView version(@Nullable Long version)
    • getVersion

      @Nullable public Long getVersion()
      Optimistic-concurrency token of the key's schedule; send it back as version to refuse a stale write. Null while the key has no schedule of its own.
      Returns:
      version
    • setVersion

      public void setVersion(@Nullable Long 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 KeyRotationScheduleView
    • 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 KeyRotationScheduleView
    • fromJson

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

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