Class ObjectRetentionEventData

java.lang.Object
software.amazon.awssdk.eventnotifications.s3.model.ObjectRetentionEventData

@SdkPublicApi public class ObjectRetentionEventData extends Object
The ObjectRetentionEventData is only visible for s3:ObjectRetention:Put events, which fire on the explicit PutObjectRetention API call. The eventHold and eventHoldDuration fields are only present when variable (event-hold) retention is used; they are absent for fixed retention.
  • Constructor Details

  • Method Details

    • getMode

      public String getMode()
      Returns:
      the retention mode, COMPLIANCE or GOVERNANCE.
    • getRetainUntilDate

      public String getRetainUntilDate()
      Returns:
      the retain-until-date in ISO-8601 format after the operation completed. For variable retention with event hold ON, this is dynamically computed as now + duration.
    • getEventHold

      public String getEventHold()
      Returns:
      the event hold state, ON or OFF. Only present when variable retention is used; absent for fixed retention.
    • getEventHoldDuration

      public EventHoldDuration getEventHoldDuration()
      Returns:
      the event hold duration. Only present when variable retention is used; absent for fixed retention.
    • 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