Class: Google::Apis::CivicinfoV2::SimpleAddressType

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

Overview

A simple representation of an address.

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) ⇒ SimpleAddressType

Returns a new instance of SimpleAddressType.



1438
1439
1440
# File 'generated/google/apis/civicinfo_v2/classes.rb', line 1438

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

Instance Attribute Details

#cityString

The city or town for the address. Corresponds to the JSON property city

Returns:

  • (String)


1406
1407
1408
# File 'generated/google/apis/civicinfo_v2/classes.rb', line 1406

def city
  @city
end

#line1String

The street name and number of this address. Corresponds to the JSON property line1

Returns:

  • (String)


1411
1412
1413
# File 'generated/google/apis/civicinfo_v2/classes.rb', line 1411

def line1
  @line1
end

#line2String

The second line the address, if needed. Corresponds to the JSON property line2

Returns:

  • (String)


1416
1417
1418
# File 'generated/google/apis/civicinfo_v2/classes.rb', line 1416

def line2
  @line2
end

#line3String

The third line of the address, if needed. Corresponds to the JSON property line3

Returns:

  • (String)


1421
1422
1423
# File 'generated/google/apis/civicinfo_v2/classes.rb', line 1421

def line3
  @line3
end

#location_nameString

The name of the location. Corresponds to the JSON property locationName

Returns:

  • (String)


1426
1427
1428
# File 'generated/google/apis/civicinfo_v2/classes.rb', line 1426

def location_name
  @location_name
end

#stateString

The US two letter state abbreviation of the address. Corresponds to the JSON property state

Returns:

  • (String)


1431
1432
1433
# File 'generated/google/apis/civicinfo_v2/classes.rb', line 1431

def state
  @state
end

#zipString

The US Postal Zip Code of the address. Corresponds to the JSON property zip

Returns:

  • (String)


1436
1437
1438
# File 'generated/google/apis/civicinfo_v2/classes.rb', line 1436

def zip
  @zip
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



1443
1444
1445
1446
1447
1448
1449
1450
1451
# File 'generated/google/apis/civicinfo_v2/classes.rb', line 1443

def update!(**args)
  @city = args[:city] if args.key?(:city)
  @line1 = args[:line1] if args.key?(:line1)
  @line2 = args[:line2] if args.key?(:line2)
  @line3 = args[:line3] if args.key?(:line3)
  @location_name = args[:location_name] if args.key?(:location_name)
  @state = args[:state] if args.key?(:state)
  @zip = args[:zip] if args.key?(:zip)
end