Class: Google::Apis::MerchantapiAccountsV1beta::Headers
- Inherits:
-
Object
- Object
- Google::Apis::MerchantapiAccountsV1beta::Headers
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- lib/google/apis/merchantapi_accounts_v1beta/classes.rb,
lib/google/apis/merchantapi_accounts_v1beta/representations.rb,
lib/google/apis/merchantapi_accounts_v1beta/representations.rb
Overview
A non-empty list of row or column headers for a table. Exactly one of prices
,
weights
, num_items
, postal_code_group_names
, or location
must be set.
Instance Attribute Summary collapse
-
#locations ⇒ Array<Google::Apis::MerchantapiAccountsV1beta::LocationIdSet>
Required.
-
#number_of_items ⇒ Array<String>
Required.
-
#postal_code_group_names ⇒ Array<String>
Required.
-
#prices ⇒ Array<Google::Apis::MerchantapiAccountsV1beta::Price>
Required.
-
#weights ⇒ Array<Google::Apis::MerchantapiAccountsV1beta::Weight>
Required.
Instance Method Summary collapse
-
#initialize(**args) ⇒ Headers
constructor
A new instance of Headers.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ Headers
Returns a new instance of Headers.
991 992 993 |
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 991 def initialize(**args) update!(**args) end |
Instance Attribute Details
#locations ⇒ Array<Google::Apis::MerchantapiAccountsV1beta::LocationIdSet>
Required. A list of location ID sets. Must be non-empty. Can only be set if
all other fields are not set.
Corresponds to the JSON property locations
951 952 953 |
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 951 def locations @locations end |
#number_of_items ⇒ Array<String>
Required. A list of inclusive number of items upper bounds. The last value can
be "infinity"
. For example ["10", "50", "infinity"]
represents the headers
"<= 10 items", "<= 50 items", and "> 50 items". Must be non-empty. Can only be
set if all other fields are not set.
Corresponds to the JSON property numberOfItems
959 960 961 |
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 959 def number_of_items @number_of_items end |
#postal_code_group_names ⇒ Array<String>
Required. A list of postal group names. The last value can be "all other
locations"
. Example: ["zone 1", "zone 2", "all other locations"]
. The
referred postal code groups must match the delivery country of the service.
Must be non-empty. Can only be set if all other fields are not set.
Corresponds to the JSON property postalCodeGroupNames
967 968 969 |
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 967 def postal_code_group_names @postal_code_group_names end |
#prices ⇒ Array<Google::Apis::MerchantapiAccountsV1beta::Price>
Required. A list of inclusive order price upper bounds. The last price's value
can be infinity by setting price amount_micros = -1. For example [
"
amount_micros": 10000000, "currency_code": "USD",
"amount_micros": 500000000,
"currency_code": "USD",
"amount_micros": -1, "currency_code": "USD"]
represents the headers "<= $10", "<= $500", and "> $500". All prices within a
service must have the same currency. Must be non-empty. Must be positive
except -1. Can only be set if all other fields are not set.
Corresponds to the JSON property prices
978 979 980 |
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 978 def prices @prices end |
#weights ⇒ Array<Google::Apis::MerchantapiAccountsV1beta::Weight>
Required. A list of inclusive order weight upper bounds. The last weight's
value can be infinity by setting price amount_micros = -1. For example [
"
amount_micros": 10000000, "unit": "kg",
"amount_micros": 50000000, "unit": "
kg",
"amount_micros": -1, "unit": "kg"]
represents the headers "<= 10kg", "
<= 50kg", and "> 50kg". All weights within a service must have the same unit.
Must be non-empty. Must be positive except -1. Can only be set if all other
fields are not set.
Corresponds to the JSON property weights
989 990 991 |
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 989 def weights @weights end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
996 997 998 999 1000 1001 1002 |
# File 'lib/google/apis/merchantapi_accounts_v1beta/classes.rb', line 996 def update!(**args) @locations = args[:locations] if args.key?(:locations) @number_of_items = args[:number_of_items] if args.key?(:number_of_items) @postal_code_group_names = args[:postal_code_group_names] if args.key?(:postal_code_group_names) @prices = args[:prices] if args.key?(:prices) @weights = args[:weights] if args.key?(:weights) end |