Class: Google::Apis::CivicinfoV2::RepresentativeInfoResponse

Inherits:
Object
  • Object
show all
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

The result of a representative info lookup query.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ RepresentativeInfoResponse

Returns a new instance of RepresentativeInfoResponse.



1089
1090
1091
# File 'lib/google/apis/civicinfo_v2/classes.rb', line 1089

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

Instance Attribute Details

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

A map of political geographic divisions that contain the requested address, keyed by the unique Open Civic Data identifier for this division. Corresponds to the JSON property divisions



1064
1065
1066
# File 'lib/google/apis/civicinfo_v2/classes.rb', line 1064

def divisions
  @divisions
end

#kindString

Identifies what kind of resource this is. Value: the fixed string "civicinfo# representativeInfoResponse". Corresponds to the JSON property kind

Returns:

  • (String)


1070
1071
1072
# File 'lib/google/apis/civicinfo_v2/classes.rb', line 1070

def kind
  @kind
end

#normalized_inputGoogle::Apis::CivicinfoV2::SimpleAddressType

A simple representation of an address. Corresponds to the JSON property normalizedInput



1075
1076
1077
# File 'lib/google/apis/civicinfo_v2/classes.rb', line 1075

def normalized_input
  @normalized_input
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



1081
1082
1083
# File 'lib/google/apis/civicinfo_v2/classes.rb', line 1081

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



1087
1088
1089
# File 'lib/google/apis/civicinfo_v2/classes.rb', line 1087

def officials
  @officials
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



1094
1095
1096
1097
1098
1099
1100
# File 'lib/google/apis/civicinfo_v2/classes.rb', line 1094

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