google-apis-civicinfo_v2 0.8.0 → 0.9.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 564c02659b9882f4766a4d887706b5fc82ed5f246dc76a5d890831e5bcbf756a
4
- data.tar.gz: be14ca691bd3932fa208a6b943ddd2123f3d37dc2b81820cf65e2953cda374dc
3
+ metadata.gz: 00f26fe49e154ad8c6d3dc076813fcc4ec8f74787a6b49ea9a1bd85bc78ea1ce
4
+ data.tar.gz: 51e268bad0bb28bd88a8501ce2406790f8aed10b859e2c6e99f2891fe6f881bd
5
5
  SHA512:
6
- metadata.gz: 61a6eeb1a1d6fc39be318660b89e3de64b726769f0b098745be1302a7181150fa1bb93cdd7dd3fcdb1de679eb4e2cb3c6eb2882cde12d665e72394b1e92163f2
7
- data.tar.gz: cf42bfe13c20b0824e5d3bf2e50cb14f555d2ad710d23974bb791cfa20d8d9ee8e99236c425b8f0fe95feec04f0e453518de937ea3d3435642e7845118f213ac
6
+ metadata.gz: 505d71401ea8abb8c380543dc8a1c50d2aad41ff70ba5bf59dae7fa8fbb8c3a7264c1b3fbc6f6c52439d1232636cc32a946ac4415f8d9dc06f5aa2e629383b6d
7
+ data.tar.gz: 7b03b4e83e3f9ff04bd772dcd6194f60fb84371978f5d7f74ea17b9a91a5b0d2c8cc32cbf2eb2f3b86c3dbf75864ee29e5b0aaadab021591c11ef0eaf632a365
data/CHANGELOG.md CHANGED
@@ -1,5 +1,10 @@
1
1
  # Release history for google-apis-civicinfo_v2
2
2
 
3
+ ### v0.9.0 (2022-04-13)
4
+
5
+ * Regenerated from discovery document revision 20220412
6
+ * Regenerated using generator version 0.4.1
7
+
3
8
  ### v0.8.0 (2021-12-14)
4
9
 
5
10
  * Unspecified changes
@@ -1035,6 +1035,108 @@ module Google
1035
1035
  end
1036
1036
  end
1037
1037
 
1038
+ #
1039
+ class Precinct
1040
+ include Google::Apis::Core::Hashable
1041
+
1042
+ # ID of the AdministrationRegion message for this precinct. Corresponds to
1043
+ # LocalityId xml tag.
1044
+ # Corresponds to the JSON property `administrationRegionId`
1045
+ # @return [String]
1046
+ attr_accessor :administration_region_id
1047
+
1048
+ # ID(s) of the Contest message(s) for this precinct.
1049
+ # Corresponds to the JSON property `contestId`
1050
+ # @return [Array<String>]
1051
+ attr_accessor :contest_id
1052
+
1053
+ # Required. Dataset ID. What datasets our Precincts come from.
1054
+ # Corresponds to the JSON property `datasetId`
1055
+ # @return [Fixnum]
1056
+ attr_accessor :dataset_id
1057
+
1058
+ # ID(s) of the PollingLocation message(s) for this precinct.
1059
+ # Corresponds to the JSON property `earlyVoteSiteId`
1060
+ # @return [Array<String>]
1061
+ attr_accessor :early_vote_site_id
1062
+
1063
+ # ID(s) of the ElectoralDistrict message(s) for this precinct.
1064
+ # Corresponds to the JSON property `electoralDistrictId`
1065
+ # @return [Array<String>]
1066
+ attr_accessor :electoral_district_id
1067
+
1068
+ # Required. A unique identifier for this precinct.
1069
+ # Corresponds to the JSON property `id`
1070
+ # @return [String]
1071
+ attr_accessor :id
1072
+
1073
+ # Specifies if the precinct runs mail-only elections.
1074
+ # Corresponds to the JSON property `mailOnly`
1075
+ # @return [Boolean]
1076
+ attr_accessor :mail_only
1077
+ alias_method :mail_only?, :mail_only
1078
+
1079
+ # Required. The name of the precinct.
1080
+ # Corresponds to the JSON property `name`
1081
+ # @return [String]
1082
+ attr_accessor :name
1083
+
1084
+ # The number of the precinct.
1085
+ # Corresponds to the JSON property `number`
1086
+ # @return [String]
1087
+ attr_accessor :number
1088
+
1089
+ # Encouraged. The OCD ID of the precinct
1090
+ # Corresponds to the JSON property `ocdId`
1091
+ # @return [Array<String>]
1092
+ attr_accessor :ocd_id
1093
+
1094
+ # ID(s) of the PollingLocation message(s) for this precinct.
1095
+ # Corresponds to the JSON property `pollingLocationId`
1096
+ # @return [Array<String>]
1097
+ attr_accessor :polling_location_id
1098
+
1099
+ # ID(s) of the SpatialBoundary message(s) for this precinct. Used to specify a
1100
+ # geometrical boundary of the precinct.
1101
+ # Corresponds to the JSON property `spatialBoundaryId`
1102
+ # @return [Array<String>]
1103
+ attr_accessor :spatial_boundary_id
1104
+
1105
+ # If present, this proto corresponds to one portion of split precinct. Other
1106
+ # portions of this precinct are guaranteed to have the same `name`. If not
1107
+ # present, this proto represents a full precicnt.
1108
+ # Corresponds to the JSON property `splitName`
1109
+ # @return [String]
1110
+ attr_accessor :split_name
1111
+
1112
+ # Specifies the ward the precinct is contained within.
1113
+ # Corresponds to the JSON property `ward`
1114
+ # @return [String]
1115
+ attr_accessor :ward
1116
+
1117
+ def initialize(**args)
1118
+ update!(**args)
1119
+ end
1120
+
1121
+ # Update properties of this object
1122
+ def update!(**args)
1123
+ @administration_region_id = args[:administration_region_id] if args.key?(:administration_region_id)
1124
+ @contest_id = args[:contest_id] if args.key?(:contest_id)
1125
+ @dataset_id = args[:dataset_id] if args.key?(:dataset_id)
1126
+ @early_vote_site_id = args[:early_vote_site_id] if args.key?(:early_vote_site_id)
1127
+ @electoral_district_id = args[:electoral_district_id] if args.key?(:electoral_district_id)
1128
+ @id = args[:id] if args.key?(:id)
1129
+ @mail_only = args[:mail_only] if args.key?(:mail_only)
1130
+ @name = args[:name] if args.key?(:name)
1131
+ @number = args[:number] if args.key?(:number)
1132
+ @ocd_id = args[:ocd_id] if args.key?(:ocd_id)
1133
+ @polling_location_id = args[:polling_location_id] if args.key?(:polling_location_id)
1134
+ @spatial_boundary_id = args[:spatial_boundary_id] if args.key?(:spatial_boundary_id)
1135
+ @split_name = args[:split_name] if args.key?(:split_name)
1136
+ @ward = args[:ward] if args.key?(:ward)
1137
+ end
1138
+ end
1139
+
1038
1140
  #
1039
1141
  class RepresentativeInfoData
1040
1142
  include Google::Apis::Core::Hashable
@@ -1266,6 +1368,12 @@ module Google
1266
1368
  # @return [String]
1267
1369
  attr_accessor :precinct_id
1268
1370
 
1371
+ # The precincts that match this voter's address. Will only be returned for
1372
+ # project IDs which have been whitelisted as "partner projects".
1373
+ # Corresponds to the JSON property `precincts`
1374
+ # @return [Array<Google::Apis::CivicinfoV2::Precinct>]
1375
+ attr_accessor :precincts
1376
+
1269
1377
  # Local Election Information for the state that the voter votes in. For the US,
1270
1378
  # there will only be one element in this array.
1271
1379
  # Corresponds to the JSON property `state`
@@ -1288,6 +1396,7 @@ module Google
1288
1396
  @other_elections = args[:other_elections] if args.key?(:other_elections)
1289
1397
  @polling_locations = args[:polling_locations] if args.key?(:polling_locations)
1290
1398
  @precinct_id = args[:precinct_id] if args.key?(:precinct_id)
1399
+ @precincts = args[:precincts] if args.key?(:precincts)
1291
1400
  @state = args[:state] if args.key?(:state)
1292
1401
  end
1293
1402
  end
@@ -16,13 +16,13 @@ module Google
16
16
  module Apis
17
17
  module CivicinfoV2
18
18
  # Version of the google-apis-civicinfo_v2 gem
19
- GEM_VERSION = "0.8.0"
19
+ GEM_VERSION = "0.9.0"
20
20
 
21
21
  # Version of the code generator used to generate this client
22
- GENERATOR_VERSION = "0.4.0"
22
+ GENERATOR_VERSION = "0.4.1"
23
23
 
24
24
  # Revision of the discovery document this client was generated from
25
- REVISION = "20211209"
25
+ REVISION = "20220412"
26
26
  end
27
27
  end
28
28
  end
@@ -130,6 +130,12 @@ module Google
130
130
  include Google::Apis::Core::JsonObjectSupport
131
131
  end
132
132
 
133
+ class Precinct
134
+ class Representation < Google::Apis::Core::JsonRepresentation; end
135
+
136
+ include Google::Apis::Core::JsonObjectSupport
137
+ end
138
+
133
139
  class RepresentativeInfoData
134
140
  class Representation < Google::Apis::Core::JsonRepresentation; end
135
141
 
@@ -397,6 +403,26 @@ module Google
397
403
  end
398
404
  end
399
405
 
406
+ class Precinct
407
+ # @private
408
+ class Representation < Google::Apis::Core::JsonRepresentation
409
+ property :administration_region_id, as: 'administrationRegionId'
410
+ collection :contest_id, as: 'contestId'
411
+ property :dataset_id, :numeric_string => true, as: 'datasetId'
412
+ collection :early_vote_site_id, as: 'earlyVoteSiteId'
413
+ collection :electoral_district_id, as: 'electoralDistrictId'
414
+ property :id, as: 'id'
415
+ property :mail_only, as: 'mailOnly'
416
+ property :name, as: 'name'
417
+ property :number, as: 'number'
418
+ collection :ocd_id, as: 'ocdId'
419
+ collection :polling_location_id, as: 'pollingLocationId'
420
+ collection :spatial_boundary_id, as: 'spatialBoundaryId'
421
+ property :split_name, as: 'splitName'
422
+ property :ward, as: 'ward'
423
+ end
424
+ end
425
+
400
426
  class RepresentativeInfoData
401
427
  # @private
402
428
  class Representation < Google::Apis::Core::JsonRepresentation
@@ -465,6 +491,8 @@ module Google
465
491
  collection :polling_locations, as: 'pollingLocations', class: Google::Apis::CivicinfoV2::PollingLocation, decorator: Google::Apis::CivicinfoV2::PollingLocation::Representation
466
492
 
467
493
  property :precinct_id, as: 'precinctId'
494
+ collection :precincts, as: 'precincts', class: Google::Apis::CivicinfoV2::Precinct, decorator: Google::Apis::CivicinfoV2::Precinct::Representation
495
+
468
496
  collection :state, as: 'state', class: Google::Apis::CivicinfoV2::AdministrationRegion, decorator: Google::Apis::CivicinfoV2::AdministrationRegion::Representation
469
497
 
470
498
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: google-apis-civicinfo_v2
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.8.0
4
+ version: 0.9.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Google LLC
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-01-10 00:00:00.000000000 Z
11
+ date: 2022-04-18 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: google-apis-core
@@ -58,7 +58,7 @@ licenses:
58
58
  metadata:
59
59
  bug_tracker_uri: https://github.com/googleapis/google-api-ruby-client/issues
60
60
  changelog_uri: https://github.com/googleapis/google-api-ruby-client/tree/main/generated/google-apis-civicinfo_v2/CHANGELOG.md
61
- documentation_uri: https://googleapis.dev/ruby/google-apis-civicinfo_v2/v0.8.0
61
+ documentation_uri: https://googleapis.dev/ruby/google-apis-civicinfo_v2/v0.9.0
62
62
  source_code_uri: https://github.com/googleapis/google-api-ruby-client/tree/main/generated/google-apis-civicinfo_v2
63
63
  post_install_message:
64
64
  rdoc_options: []
@@ -75,7 +75,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
75
75
  - !ruby/object:Gem::Version
76
76
  version: '0'
77
77
  requirements: []
78
- rubygems_version: 3.3.4
78
+ rubygems_version: 3.3.5
79
79
  signing_key:
80
80
  specification_version: 4
81
81
  summary: Simple REST client for Google Civic Information API V2