class Google::Apis::ContentV2::AccountShippingShippingServiceCalculationMethod

Shipping cost calculation method. Exactly one of the field is set.

Attributes

carrier_rate[RW]

Name of the carrier rate to use for the calculation. Corresponds to the JSON property `carrierRate` @return [String]

excluded[RW]

Delivery is excluded. Valid only within cost rules tree. Corresponds to the JSON property `excluded` @return [Boolean]

excluded?[RW]

Delivery is excluded. Valid only within cost rules tree. Corresponds to the JSON property `excluded` @return [Boolean]

flat_rate[RW]

Fixed price shipping, represented as a floating point number associated with a currency. Corresponds to the JSON property `flatRate` @return [Google::Apis::ContentV2::Price]

percentage_rate[RW]

Percentage of the price, represented as a floating point number without the percentage character. Corresponds to the JSON property `percentageRate` @return [String]

rate_table[RW]

Name of the rate table to use for the calculation. Corresponds to the JSON property `rateTable` @return [String]

Public Class Methods

new(**args) click to toggle source
# File generated/google/apis/content_v2/classes.rb, line 552
def initialize(**args)
   update!(**args)
end

Public Instance Methods

update!(**args) click to toggle source

Update properties of this object

# File generated/google/apis/content_v2/classes.rb, line 557
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