Class: Google::Apis::AndroidpublisherV3::DeferralContext

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

Overview

Deferral context of the purchases.subscriptionsv2.defer API.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ DeferralContext

Returns a new instance of DeferralContext.



3058
3059
3060
# File 'lib/google/apis/androidpublisher_v3/classes.rb', line 3058

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

Instance Attribute Details

#defer_durationString

Required. The duration by which all subscription items should be deferred. Corresponds to the JSON property deferDuration

Returns:

  • (String)


3041
3042
3043
# File 'lib/google/apis/androidpublisher_v3/classes.rb', line 3041

def defer_duration
  @defer_duration
end

#etagString

Required. The API will fail if the etag does not match the latest etag for this subscription. The etag is retrieved from purchases.subscriptionsv2.get: https://developers.google.com/android-publisher/api-ref/rest/v3/purchases. subscriptionsv2/get Corresponds to the JSON property etag

Returns:

  • (String)


3049
3050
3051
# File 'lib/google/apis/androidpublisher_v3/classes.rb', line 3049

def etag
  @etag
end

#validate_onlyBoolean Also known as: validate_only?

If set to "true", the request is a dry run to validate the effect of Defer, the subscription would not be impacted. Corresponds to the JSON property validateOnly

Returns:

  • (Boolean)


3055
3056
3057
# File 'lib/google/apis/androidpublisher_v3/classes.rb', line 3055

def validate_only
  @validate_only
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



3063
3064
3065
3066
3067
# File 'lib/google/apis/androidpublisher_v3/classes.rb', line 3063

def update!(**args)
  @defer_duration = args[:defer_duration] if args.key?(:defer_duration)
  @etag = args[:etag] if args.key?(:etag)
  @validate_only = args[:validate_only] if args.key?(:validate_only)
end