Class: Google::Apis::ContentV2::AccountShippingShippingServiceCalculationMethod
- Inherits:
-
Object
- Object
- Google::Apis::ContentV2::AccountShippingShippingServiceCalculationMethod
- Defined in:
- generated/google/apis/content_v2/classes.rb,
generated/google/apis/content_v2/representations.rb,
generated/google/apis/content_v2/representations.rb
Overview
Shipping cost calculation method. Exactly one of the field is set.
Instance Attribute Summary collapse
-
#carrier_rate ⇒ String
Name of the carrier rate to use for the calculation.
-
#excluded ⇒ Boolean
(also: #excluded?)
Delivery is excluded.
-
#flat_rate ⇒ Google::Apis::ContentV2::Price
Fixed price shipping, represented as a floating point number associated with a currency.
-
#percentage_rate ⇒ String
Percentage of the price, represented as a floating point number without the percentage character.
-
#rate_table ⇒ String
Name of the rate table to use for the calculation.
Instance Method Summary collapse
-
#initialize(**args) ⇒ AccountShippingShippingServiceCalculationMethod
constructor
A new instance of AccountShippingShippingServiceCalculationMethod.
-
#update!(**args) ⇒ Object
Update properties of this object.
Methods included from Google::Apis::Core::JsonObjectSupport
Methods included from Google::Apis::Core::Hashable
Constructor Details
#initialize(**args) ⇒ AccountShippingShippingServiceCalculationMethod
Returns a new instance of AccountShippingShippingServiceCalculationMethod.
566 567 568 |
# File 'generated/google/apis/content_v2/classes.rb', line 566 def initialize(**args) update!(**args) end |
Instance Attribute Details
#carrier_rate ⇒ String
Name of the carrier rate to use for the calculation.
Corresponds to the JSON property carrierRate
541 542 543 |
# File 'generated/google/apis/content_v2/classes.rb', line 541 def carrier_rate @carrier_rate end |
#excluded ⇒ Boolean Also known as: excluded?
Delivery is excluded. Valid only within cost rules tree.
Corresponds to the JSON property excluded
546 547 548 |
# File 'generated/google/apis/content_v2/classes.rb', line 546 def excluded @excluded end |
#flat_rate ⇒ Google::Apis::ContentV2::Price
Fixed price shipping, represented as a floating point number associated with a
currency.
Corresponds to the JSON property flatRate
553 554 555 |
# File 'generated/google/apis/content_v2/classes.rb', line 553 def flat_rate @flat_rate end |
#percentage_rate ⇒ String
Percentage of the price, represented as a floating point number without the
percentage character.
Corresponds to the JSON property percentageRate
559 560 561 |
# File 'generated/google/apis/content_v2/classes.rb', line 559 def percentage_rate @percentage_rate end |
#rate_table ⇒ String
Name of the rate table to use for the calculation.
Corresponds to the JSON property rateTable
564 565 566 |
# File 'generated/google/apis/content_v2/classes.rb', line 564 def rate_table @rate_table end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
571 572 573 574 575 576 577 |
# File 'generated/google/apis/content_v2/classes.rb', line 571 def update!(**args) @carrier_rate = args[:carrier_rate] if args.key?(:carrier_rate) @excluded = args[:excluded] if args.key?(:excluded) @flat_rate = args[:flat_rate] if args.key?(:flat_rate) @percentage_rate = args[:percentage_rate] if args.key?(:percentage_rate) @rate_table = args[:rate_table] if args.key?(:rate_table) end |