Class: Google::Apis::CivicinfoV2::SimpleAddressType
- Inherits:
-
Object
- Object
- Google::Apis::CivicinfoV2::SimpleAddressType
- Includes:
- Google::Apis::Core::Hashable, Google::Apis::Core::JsonObjectSupport
- Defined in:
- lib/google/apis/civicinfo_v2/classes.rb,
lib/google/apis/civicinfo_v2/representations.rb,
lib/google/apis/civicinfo_v2/representations.rb
Overview
A simple representation of an address.
Instance Attribute Summary collapse
-
#city ⇒ String
The city or town for the address.
-
#line1 ⇒ String
The street name and number of this address.
-
#line2 ⇒ String
The second line the address, if needed.
-
#line3 ⇒ String
The third line of the address, if needed.
-
#location_name ⇒ String
The name of the location.
-
#state ⇒ String
The US two letter state abbreviation of the address.
-
#zip ⇒ String
The US Postal Zip Code of the address.
Instance Method Summary collapse
-
#initialize(**args) ⇒ SimpleAddressType
constructor
A new instance of SimpleAddressType.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ SimpleAddressType
Returns a new instance of SimpleAddressType.
1158 1159 1160 |
# File 'lib/google/apis/civicinfo_v2/classes.rb', line 1158 def initialize(**args) update!(**args) end |
Instance Attribute Details
#city ⇒ String
The city or town for the address.
Corresponds to the JSON property city
1126 1127 1128 |
# File 'lib/google/apis/civicinfo_v2/classes.rb', line 1126 def city @city end |
#line1 ⇒ String
The street name and number of this address.
Corresponds to the JSON property line1
1131 1132 1133 |
# File 'lib/google/apis/civicinfo_v2/classes.rb', line 1131 def line1 @line1 end |
#line2 ⇒ String
The second line the address, if needed.
Corresponds to the JSON property line2
1136 1137 1138 |
# File 'lib/google/apis/civicinfo_v2/classes.rb', line 1136 def line2 @line2 end |
#line3 ⇒ String
The third line of the address, if needed.
Corresponds to the JSON property line3
1141 1142 1143 |
# File 'lib/google/apis/civicinfo_v2/classes.rb', line 1141 def line3 @line3 end |
#location_name ⇒ String
The name of the location.
Corresponds to the JSON property locationName
1146 1147 1148 |
# File 'lib/google/apis/civicinfo_v2/classes.rb', line 1146 def location_name @location_name end |
#state ⇒ String
The US two letter state abbreviation of the address.
Corresponds to the JSON property state
1151 1152 1153 |
# File 'lib/google/apis/civicinfo_v2/classes.rb', line 1151 def state @state end |
#zip ⇒ String
The US Postal Zip Code of the address.
Corresponds to the JSON property zip
1156 1157 1158 |
# File 'lib/google/apis/civicinfo_v2/classes.rb', line 1156 def zip @zip end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
1163 1164 1165 1166 1167 1168 1169 1170 1171 |
# File 'lib/google/apis/civicinfo_v2/classes.rb', line 1163 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 |