Class: Google::Apis::CivicinfoV2::RepresentativeInfoData

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

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

Returns a new instance of RepresentativeInfoData.



1321
1322
1323
# File 'generated/google/apis/civicinfo_v2/classes.rb', line 1321

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

Instance Attribute Details

#divisionsHash<String,Google::Apis::CivicinfoV2::GeographicDivision>

Political geographic divisions that contain the requested address. Corresponds to the JSON property divisions



1307
1308
1309
# File 'generated/google/apis/civicinfo_v2/classes.rb', line 1307

def divisions
  @divisions
end

#officesArray<Google::Apis::CivicinfoV2::Office>

Elected offices referenced by the divisions listed above. Will only be present if includeOffices was true in the request. Corresponds to the JSON property offices



1313
1314
1315
# File 'generated/google/apis/civicinfo_v2/classes.rb', line 1313

def offices
  @offices
end

#officialsArray<Google::Apis::CivicinfoV2::Official>

Officials holding the offices listed above. Will only be present if includeOffices was true in the request. Corresponds to the JSON property officials



1319
1320
1321
# File 'generated/google/apis/civicinfo_v2/classes.rb', line 1319

def officials
  @officials
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



1326
1327
1328
1329
1330
# File 'generated/google/apis/civicinfo_v2/classes.rb', line 1326

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