class Google::Apis::CivicinfoV2::Office

Information about an Office held by one or more Officials.

Attributes

division_id[RW]

The OCD ID of the division with which this office is associated. Corresponds to the JSON property `divisionId` @return [String]

levels[RW]

The levels of government of which this office is part. There may be more than one in cases where a jurisdiction effectively acts at two different levels of government; for example, the mayor of the District of Columbia acts at “ locality” level, but also effectively at both “administrative-area-2” and “ administrative-area-1”. Corresponds to the JSON property `levels` @return [Array<String>]

name[RW]

The human-readable name of the office. Corresponds to the JSON property `name` @return [String]

official_indices[RW]

List of indices in the officials array of people who presently hold this office. Corresponds to the JSON property `officialIndices` @return [Array<Fixnum>]

roles[RW]

The roles which this office fulfills. Roles are not meant to be exhaustive, or to exactly specify the entire set of responsibilities of a given office, but are meant to be rough categories that are useful for general selection from or sorting of a list of offices. Corresponds to the JSON property `roles` @return [Array<String>]

sources[RW]

A list of sources for this office. If multiple sources are listed, the data has been aggregated from those sources. Corresponds to the JSON property `sources` @return [Array<Google::Apis::CivicinfoV2::Source>]

Public Class Methods

new(**args) click to toggle source
# File lib/google/apis/civicinfo_v2/classes.rb, line 740
def initialize(**args)
   update!(**args)
end

Public Instance Methods

update!(**args) click to toggle source

Update properties of this object

# File lib/google/apis/civicinfo_v2/classes.rb, line 745
def update!(**args)
  @division_id = args[:division_id] if args.key?(:division_id)
  @levels = args[:levels] if args.key?(:levels)
  @name = args[:name] if args.key?(:name)
  @official_indices = args[:official_indices] if args.key?(:official_indices)
  @roles = args[:roles] if args.key?(:roles)
  @sources = args[:sources] if args.key?(:sources)
end