Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CheckServer ¶
Types ¶
type Address ¶
type Address struct { LocationName string `json:"locationName"` Line1 string `json:"line1"` Line2 string `json:"line2"` Line3 string `json:"line3"` City string `json:"city"` State string `json:"state"` Zip string `json:"zip"` }
Address Resource
type AdministrationRegion ¶
type AdministrationRegion struct { Name string `json:"name"` ElectionAdministrationBody ElectionAdministrationBody `json:"electionAdministrationBody"` }
AdministrationRegion Resource
type Candidate ¶
type Candidate struct { Name string `json:"name"` Party string `json:"party"` CandidateUrl string `json:"candidateUrl"` Phone string `json:"phone"` PhotoUrl string `json:"photoUrl"` Email string `json:"email"` OrderOnBallot int64 `json:"orderOnBallot"` Channels []Channel `json:"channels"` }
Candidate Resource
func (Candidate) Description ¶
func (Candidate) FilterValue ¶
type Contest ¶
type Contest struct { Type string `json:"type"` PrimaryParty string `json:"primaryParty"` ElectorateSpecifications string `json:"electorateSpecifications"` Special string `json:"special"` BallotTitle string `json:"ballotTitle"` Office string `json:"office"` Level []string `json:"level"` Roles []string `json:"roles"` District District `json:"district"` NumberElected string `json:"numberElected"` // Docs say long, but API returns a string NumberVotingFor string `json:"numberVotingFor"` // Docs say long, but API returns a string BallotPlacement string `json:"ballotPlacement"` // Docs say long, but API returns a string Candidates []Candidate `json:"candidates"` ReferendumTitle string `json:"referendumTitle"` ReferendumSubtitle string `json:"referendumSubtitle"` ReferendumUrl string `json:"referendumUrl"` ReferendumBrief string `json:"referendumBrief"` ReferendumText string `json:"referendumText"` ReferendumProStatement string `json:"referendumProStatement"` ReferendumConStatement string `json:"referendumConStatement"` ReferendumPassageThreshold string `json:"referendumPassageThreshold"` ReferendumEffectOfAbstain string `json:"referendumEffectOfAbstain"` ReferendumBallotResponses []string `json:"referendumBallotResponses"` Sources []Source `json:"sources"` }
Contest Resource
func (Contest) Description ¶
func (Contest) FilterValue ¶
type District ¶
type District struct { Name string `json:"name"` Scope string `json:"scope"` ID string `json:"id"` }
District Resource
type Election ¶
type Election struct { ID string `json:"id"` Name string `json:"name"` ElectionDay string `json:"electionDay"` OcdDivisionId string `json:"ocdDivisionId"` }
Election Resource
type ElectionAdministrationBody ¶
type ElectionAdministrationBody struct { Name string `json:"name"` ElectionInfoUrl string `json:"electionInfoUrl"` ElectionRegistrationUrl string `json:"electionRegistrationUrl"` ElectionRegistrationConfirmationUrl string `json:"electionRegistrationConfirmationUrl"` ElectionNoticeText string `json:"electionNoticeText"` ElectionNoticeUrl string `json:"electionNoticeUrl"` AbsenteeVotingInfoUrl string `json:"absenteeVotingInfoUrl"` VotingLocationFinderUrl string `json:"votingLocationFinderUrl"` BallotInfoUrl string `json:"ballotInfoUrl"` ElectionRulesUrl string `json:"electionRulesUrl"` VoterServices []string `json:"voter_services"` HoursOfOperation string `json:"hoursOfOperation"` CorrespondenceAddress Address `json:"correspondenceAddress"` PhysicalAddress Address `json:"physicalAddress"` ElectionOfficials []ElectionOfficial `json:"electionOfficials"` }
ElectionAdministrationBody Resource
type ElectionOfficial ¶
type ElectionOfficial struct { Name string `json:"name"` Title string `json:"title"` OfficePhoneNumber string `json:"officePhoneNumber"` FaxNumber string `json:"faxNumber"` EmailAddress string `json:"emailAddress"` }
ElectionOfficial Resource
type PollingPlace ¶
type PollingPlace struct { Address Address `json:"address"` Notes string `json:"notes"` PollingHours string `json:"pollingHours"` Name string `json:"name"` VoterServices string `json:"voterServices"` StartDate string `json:"startDate"` EndDate string `json:"endDate"` Latitude float64 `json:"latitude"` Longitude float64 `json:"longitude"` Sources []Source `json:"sources"` }
PollingPlace Resource (used for pollingLocations, earlyVoteSites, and dropOffLocations)
func (PollingPlace) Description ¶
func (p PollingPlace) Description() string
func (PollingPlace) FilterValue ¶
func (p PollingPlace) FilterValue() string
func (PollingPlace) GetMapsUrl ¶
func (p PollingPlace) GetMapsUrl() (string, error)
func (PollingPlace) Title ¶
func (p PollingPlace) Title() string
type State ¶
type State struct { Name string `json:"name"` ElectionAdministrationBody ElectionAdministrationBody `json:"electionAdministrationBody"` LocalJurisdiction *AdministrationRegion `json:"local_jurisdiction"` Sources []Source `json:"sources"` }
State Resource
type VoterInfoResponse ¶
type VoterInfoResponse struct { Kind string `json:"kind"` Election Election `json:"election"` OtherElections []Election `json:"otherElections"` NormalizedInput Address `json:"normalizedInput"` PollingLocations []PollingPlace `json:"pollingLocations"` EarlyVoteSites []PollingPlace `json:"earlyVoteSites"` DropOffLocations []PollingPlace `json:"dropOffLocations"` Contests []Contest `json:"contests"` State []State `json:"state"` // This is an array in the API, but I think it should be a single object. Have not seen a counterexample MailOnly bool `json:"mailOnly"` }
Click to show internal directories.
Click to hide internal directories.