Class: Google::Apis::PaymentsresellersubscriptionV1::GoogleCloudPaymentsResellerSubscriptionV1Amount

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

Overview

Describes the amount unit including the currency code.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ GoogleCloudPaymentsResellerSubscriptionV1Amount

Returns a new instance of GoogleCloudPaymentsResellerSubscriptionV1Amount.



40
41
42
# File 'lib/google/apis/paymentsresellersubscription_v1/classes.rb', line 40

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

Instance Attribute Details

#amount_microsFixnum

Required. Amount in micros (1_000_000 micros = 1 currency unit) Corresponds to the JSON property amountMicros

Returns:

  • (Fixnum)


32
33
34
# File 'lib/google/apis/paymentsresellersubscription_v1/classes.rb', line 32

def amount_micros
  @amount_micros
end

#currency_codeString

Required. Currency codes in accordance with ISO-4217 Currency Codes. For example, USD. Corresponds to the JSON property currencyCode

Returns:

  • (String)


38
39
40
# File 'lib/google/apis/paymentsresellersubscription_v1/classes.rb', line 38

def currency_code
  @currency_code
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



45
46
47
48
# File 'lib/google/apis/paymentsresellersubscription_v1/classes.rb', line 45

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