Class: Google::Apis::RecaptchaenterpriseV1::GoogleCloudRecaptchaenterpriseV1TransactionDataItem

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

Overview

Line items being purchased in this transaction.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ GoogleCloudRecaptchaenterpriseV1TransactionDataItem

Returns a new instance of GoogleCloudRecaptchaenterpriseV1TransactionDataItem.



2047
2048
2049
# File 'lib/google/apis/recaptchaenterprise_v1/classes.rb', line 2047

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

Instance Attribute Details

#merchant_account_idString

Optional. When a merchant is specified, its corresponding account_id. Necessary to populate marketplace-style transactions. Corresponds to the JSON property merchantAccountId

Returns:

  • (String)


2029
2030
2031
# File 'lib/google/apis/recaptchaenterprise_v1/classes.rb', line 2029

def 
  @merchant_account_id
end

#nameString

Optional. The full name of the item. Corresponds to the JSON property name

Returns:

  • (String)


2034
2035
2036
# File 'lib/google/apis/recaptchaenterprise_v1/classes.rb', line 2034

def name
  @name
end

#quantityFixnum

Optional. The quantity of this item that is being purchased. Corresponds to the JSON property quantity

Returns:

  • (Fixnum)


2039
2040
2041
# File 'lib/google/apis/recaptchaenterprise_v1/classes.rb', line 2039

def quantity
  @quantity
end

#valueFloat

Optional. The value per item that the user is paying, in the transaction currency, after discounts. Corresponds to the JSON property value

Returns:

  • (Float)


2045
2046
2047
# File 'lib/google/apis/recaptchaenterprise_v1/classes.rb', line 2045

def value
  @value
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



2052
2053
2054
2055
2056
2057
# File 'lib/google/apis/recaptchaenterprise_v1/classes.rb', line 2052

def update!(**args)
  @merchant_account_id = args[:merchant_account_id] if args.key?(:merchant_account_id)
  @name = args[:name] if args.key?(:name)
  @quantity = args[:quantity] if args.key?(:quantity)
  @value = args[:value] if args.key?(:value)
end