Class: Google::Apis::ContentV2::AccountShippingPostalCodeRange

Inherits:
Object
  • Object
show all
Includes:
Google::Apis::Core::Hashable, Google::Apis::Core::JsonObjectSupport
Defined in:
generated/google/apis/content_v2/classes.rb,
generated/google/apis/content_v2/representations.rb,
generated/google/apis/content_v2/representations.rb

Overview

A postal code range, that can be either:

  • A range of postal codes (e.g., start=12340, end=12359)
  • A range of postal codes prefixes (e.g., start=1234* end=1235*). Prefixes must be of the same length (e.g., start=12* end=2* is invalid).

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Google::Apis::Core::JsonObjectSupport

#to_json

Methods included from Google::Apis::Core::Hashable

process_value, #to_h

Constructor Details

#initialize(**args) ⇒ AccountShippingPostalCodeRange

Returns a new instance of AccountShippingPostalCodeRange.



391
392
393
# File 'generated/google/apis/content_v2/classes.rb', line 391

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

Instance Attribute Details

#endString

The last (inclusive) postal code or prefix of the range. Corresponds to the JSON property end

Returns:

  • (String)


384
385
386
# File 'generated/google/apis/content_v2/classes.rb', line 384

def end
  @end
end

#startString

The first (inclusive) postal code or prefix of the range. Corresponds to the JSON property start

Returns:

  • (String)


389
390
391
# File 'generated/google/apis/content_v2/classes.rb', line 389

def start
  @start
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



396
397
398
399
# File 'generated/google/apis/content_v2/classes.rb', line 396

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