Class: Google::Apis::StoragebatchoperationsV1::ObjectRetention

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/storagebatchoperations_v1/classes.rb,
lib/google/apis/storagebatchoperations_v1/representations.rb,
lib/google/apis/storagebatchoperations_v1/representations.rb

Overview

Describes options for object retention update.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ ObjectRetention

Returns a new instance of ObjectRetention.



803
804
805
# File 'lib/google/apis/storagebatchoperations_v1/classes.rb', line 803

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#retain_until_timeString

Required. The time when the object will be retained until. UNSET will clear the retention. Must be specified in RFC 3339 format e.g. YYYY-MM-DD'T'HH:MM:SS. SS'Z' or YYYY-MM-DD'T'HH:MM:SS'Z'. Corresponds to the JSON property retainUntilTime

Returns:

  • (String)


796
797
798
# File 'lib/google/apis/storagebatchoperations_v1/classes.rb', line 796

def retain_until_time
  @retain_until_time
end

#retention_modeString

Required. The retention mode of the object. Corresponds to the JSON property retentionMode

Returns:

  • (String)


801
802
803
# File 'lib/google/apis/storagebatchoperations_v1/classes.rb', line 801

def retention_mode
  @retention_mode
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



808
809
810
811
# File 'lib/google/apis/storagebatchoperations_v1/classes.rb', line 808

def update!(**args)
  @retain_until_time = args[:retain_until_time] if args.key?(:retain_until_time)
  @retention_mode = args[:retention_mode] if args.key?(:retention_mode)
end