Class: Google::Apis::AndroidpublisherV1_1::SubscriptionPurchase

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

Overview

A SubscriptionPurchase resource indicates the status of a user's subscription purchase.

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Core::JsonObjectSupport

#to_json

Methods included from Core::Hashable

process_value, #to_h

Constructor Details

#initialize(**args) ⇒ SubscriptionPurchase

Returns a new instance of SubscriptionPurchase.



121
122
123
# File 'generated/google/apis/androidpublisher_v1_1/classes.rb', line 121

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

Instance Attribute Details

#auto_renewingBoolean Also known as: auto_renewing?

Whether the subscription will automatically be renewed when it reaches its current expiry time. Corresponds to the JSON property autoRenewing

Returns:

  • (Boolean)


102
103
104
# File 'generated/google/apis/androidpublisher_v1_1/classes.rb', line 102

def auto_renewing
  @auto_renewing
end

#initiation_timestamp_msecFixnum

Time at which the subscription was granted, in milliseconds since the Epoch. Corresponds to the JSON property initiationTimestampMsec

Returns:

  • (Fixnum)


108
109
110
# File 'generated/google/apis/androidpublisher_v1_1/classes.rb', line 108

def initiation_timestamp_msec
  @initiation_timestamp_msec
end

#kindString

This kind represents a subscriptionPurchase object in the androidpublisher service. Corresponds to the JSON property kind

Returns:

  • (String)


114
115
116
# File 'generated/google/apis/androidpublisher_v1_1/classes.rb', line 114

def kind
  @kind
end

#valid_until_timestamp_msecFixnum

Time at which the subscription will expire, in milliseconds since the Epoch. Corresponds to the JSON property validUntilTimestampMsec

Returns:

  • (Fixnum)


119
120
121
# File 'generated/google/apis/androidpublisher_v1_1/classes.rb', line 119

def valid_until_timestamp_msec
  @valid_until_timestamp_msec
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



126
127
128
129
130
131
# File 'generated/google/apis/androidpublisher_v1_1/classes.rb', line 126

def update!(**args)
  @auto_renewing = args[:auto_renewing] if args.key?(:auto_renewing)
  @initiation_timestamp_msec = args[:initiation_timestamp_msec] if args.key?(:initiation_timestamp_msec)
  @kind = args[:kind] if args.key?(:kind)
  @valid_until_timestamp_msec = args[:valid_until_timestamp_msec] if args.key?(:valid_until_timestamp_msec)
end