| OLD | NEW |
| 1 // This is a generated file (see the discoveryapis_generator project). | 1 // This is a generated file (see the discoveryapis_generator project). |
| 2 | 2 |
| 3 library googleapis.civicinfo.v2; | 3 library googleapis.civicinfo.v2; |
| 4 | 4 |
| 5 import 'dart:core' as core; | 5 import 'dart:core' as core; |
| 6 import 'dart:async' as async; | 6 import 'dart:async' as async; |
| 7 import 'dart:convert' as convert; | 7 import 'dart:convert' as convert; |
| 8 | 8 |
| 9 import 'package:_discoveryapis_commons/_discoveryapis_commons.dart' as commons; | 9 import 'package:_discoveryapis_commons/_discoveryapis_commons.dart' as commons; |
| 10 import 'package:http/http.dart' as http; | 10 import 'package:http/http.dart' as http; |
| (...skipping 650 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 661 * The number of candidates that will be elected to office in this contest. | 661 * The number of candidates that will be elected to office in this contest. |
| 662 */ | 662 */ |
| 663 core.String numberElected; | 663 core.String numberElected; |
| 664 /** The number of candidates that a voter may vote for in this contest. */ | 664 /** The number of candidates that a voter may vote for in this contest. */ |
| 665 core.String numberVotingFor; | 665 core.String numberVotingFor; |
| 666 /** The name of the office for this contest. */ | 666 /** The name of the office for this contest. */ |
| 667 core.String office; | 667 core.String office; |
| 668 /** If this is a partisan election, the name of the party it is for. */ | 668 /** If this is a partisan election, the name of the party it is for. */ |
| 669 core.String primaryParty; | 669 core.String primaryParty; |
| 670 /** | 670 /** |
| 671 * The set of ballot responses for the referendum. A ballot response |
| 672 * represents a line on the ballot. Common examples might include "yes" or |
| 673 * "no" for referenda, or a judge's name for a retention contest. This field |
| 674 * is only populated for contests of type 'Referendum'. |
| 675 */ |
| 676 core.List<core.String> referendumBallotResponses; |
| 677 /** |
| 678 * Specifies a short summary of the referendum that is on the ballot below the |
| 679 * title but above the text. This field is only populated for contests of type |
| 680 * 'Referendum'. |
| 681 */ |
| 682 core.String referendumBrief; |
| 683 /** |
| 684 * A statement in opposition to the referendum. It does not necessarily appear |
| 685 * on the ballot. This field is only populated for contests of type |
| 686 * 'Referendum'. |
| 687 */ |
| 688 core.String referendumConStatement; |
| 689 /** |
| 690 * Specifies what effect abstaining (not voting) on the proposition will have |
| 691 * (i.e. whether abstaining is considered a vote against it). This field is |
| 692 * only populated for contests of type 'Referendum'. |
| 693 */ |
| 694 core.String referendumEffectOfAbstain; |
| 695 /** |
| 696 * The threshold of votes that the referendum needs in order to pass, e.g. |
| 697 * "two-thirds". This field is only populated for contests of type |
| 698 * 'Referendum'. |
| 699 */ |
| 700 core.String referendumPassageThreshold; |
| 701 /** |
| 702 * A statement in favor of the referendum. It does not necessarily appear on |
| 703 * the ballot. This field is only populated for contests of type 'Referendum'. |
| 704 */ |
| 705 core.String referendumProStatement; |
| 706 /** |
| 671 * A brief description of the referendum. This field is only populated for | 707 * A brief description of the referendum. This field is only populated for |
| 672 * contests of type 'Referendum'. | 708 * contests of type 'Referendum'. |
| 673 */ | 709 */ |
| 674 core.String referendumSubtitle; | 710 core.String referendumSubtitle; |
| 675 /** | 711 /** |
| 712 * The full text of the referendum. This field is only populated for contests |
| 713 * of type 'Referendum'. |
| 714 */ |
| 715 core.String referendumText; |
| 716 /** |
| 676 * The title of the referendum (e.g. 'Proposition 42'). This field is only | 717 * The title of the referendum (e.g. 'Proposition 42'). This field is only |
| 677 * populated for contests of type 'Referendum'. | 718 * populated for contests of type 'Referendum'. |
| 678 */ | 719 */ |
| 679 core.String referendumTitle; | 720 core.String referendumTitle; |
| 680 /** | 721 /** |
| 681 * A link to the referendum. This field is only populated for contests of type | 722 * A link to the referendum. This field is only populated for contests of type |
| 682 * 'Referendum'. | 723 * 'Referendum'. |
| 683 */ | 724 */ |
| 684 core.String referendumUrl; | 725 core.String referendumUrl; |
| 685 /** The roles which this office fulfills. */ | 726 /** The roles which this office fulfills. */ |
| (...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 727 } | 768 } |
| 728 if (_json.containsKey("numberVotingFor")) { | 769 if (_json.containsKey("numberVotingFor")) { |
| 729 numberVotingFor = _json["numberVotingFor"]; | 770 numberVotingFor = _json["numberVotingFor"]; |
| 730 } | 771 } |
| 731 if (_json.containsKey("office")) { | 772 if (_json.containsKey("office")) { |
| 732 office = _json["office"]; | 773 office = _json["office"]; |
| 733 } | 774 } |
| 734 if (_json.containsKey("primaryParty")) { | 775 if (_json.containsKey("primaryParty")) { |
| 735 primaryParty = _json["primaryParty"]; | 776 primaryParty = _json["primaryParty"]; |
| 736 } | 777 } |
| 778 if (_json.containsKey("referendumBallotResponses")) { |
| 779 referendumBallotResponses = _json["referendumBallotResponses"]; |
| 780 } |
| 781 if (_json.containsKey("referendumBrief")) { |
| 782 referendumBrief = _json["referendumBrief"]; |
| 783 } |
| 784 if (_json.containsKey("referendumConStatement")) { |
| 785 referendumConStatement = _json["referendumConStatement"]; |
| 786 } |
| 787 if (_json.containsKey("referendumEffectOfAbstain")) { |
| 788 referendumEffectOfAbstain = _json["referendumEffectOfAbstain"]; |
| 789 } |
| 790 if (_json.containsKey("referendumPassageThreshold")) { |
| 791 referendumPassageThreshold = _json["referendumPassageThreshold"]; |
| 792 } |
| 793 if (_json.containsKey("referendumProStatement")) { |
| 794 referendumProStatement = _json["referendumProStatement"]; |
| 795 } |
| 737 if (_json.containsKey("referendumSubtitle")) { | 796 if (_json.containsKey("referendumSubtitle")) { |
| 738 referendumSubtitle = _json["referendumSubtitle"]; | 797 referendumSubtitle = _json["referendumSubtitle"]; |
| 739 } | 798 } |
| 799 if (_json.containsKey("referendumText")) { |
| 800 referendumText = _json["referendumText"]; |
| 801 } |
| 740 if (_json.containsKey("referendumTitle")) { | 802 if (_json.containsKey("referendumTitle")) { |
| 741 referendumTitle = _json["referendumTitle"]; | 803 referendumTitle = _json["referendumTitle"]; |
| 742 } | 804 } |
| 743 if (_json.containsKey("referendumUrl")) { | 805 if (_json.containsKey("referendumUrl")) { |
| 744 referendumUrl = _json["referendumUrl"]; | 806 referendumUrl = _json["referendumUrl"]; |
| 745 } | 807 } |
| 746 if (_json.containsKey("roles")) { | 808 if (_json.containsKey("roles")) { |
| 747 roles = _json["roles"]; | 809 roles = _json["roles"]; |
| 748 } | 810 } |
| 749 if (_json.containsKey("sources")) { | 811 if (_json.containsKey("sources")) { |
| (...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 782 } | 844 } |
| 783 if (numberVotingFor != null) { | 845 if (numberVotingFor != null) { |
| 784 _json["numberVotingFor"] = numberVotingFor; | 846 _json["numberVotingFor"] = numberVotingFor; |
| 785 } | 847 } |
| 786 if (office != null) { | 848 if (office != null) { |
| 787 _json["office"] = office; | 849 _json["office"] = office; |
| 788 } | 850 } |
| 789 if (primaryParty != null) { | 851 if (primaryParty != null) { |
| 790 _json["primaryParty"] = primaryParty; | 852 _json["primaryParty"] = primaryParty; |
| 791 } | 853 } |
| 854 if (referendumBallotResponses != null) { |
| 855 _json["referendumBallotResponses"] = referendumBallotResponses; |
| 856 } |
| 857 if (referendumBrief != null) { |
| 858 _json["referendumBrief"] = referendumBrief; |
| 859 } |
| 860 if (referendumConStatement != null) { |
| 861 _json["referendumConStatement"] = referendumConStatement; |
| 862 } |
| 863 if (referendumEffectOfAbstain != null) { |
| 864 _json["referendumEffectOfAbstain"] = referendumEffectOfAbstain; |
| 865 } |
| 866 if (referendumPassageThreshold != null) { |
| 867 _json["referendumPassageThreshold"] = referendumPassageThreshold; |
| 868 } |
| 869 if (referendumProStatement != null) { |
| 870 _json["referendumProStatement"] = referendumProStatement; |
| 871 } |
| 792 if (referendumSubtitle != null) { | 872 if (referendumSubtitle != null) { |
| 793 _json["referendumSubtitle"] = referendumSubtitle; | 873 _json["referendumSubtitle"] = referendumSubtitle; |
| 794 } | 874 } |
| 875 if (referendumText != null) { |
| 876 _json["referendumText"] = referendumText; |
| 877 } |
| 795 if (referendumTitle != null) { | 878 if (referendumTitle != null) { |
| 796 _json["referendumTitle"] = referendumTitle; | 879 _json["referendumTitle"] = referendumTitle; |
| 797 } | 880 } |
| 798 if (referendumUrl != null) { | 881 if (referendumUrl != null) { |
| 799 _json["referendumUrl"] = referendumUrl; | 882 _json["referendumUrl"] = referendumUrl; |
| 800 } | 883 } |
| 801 if (roles != null) { | 884 if (roles != null) { |
| 802 _json["roles"] = roles; | 885 _json["roles"] = roles; |
| 803 } | 886 } |
| 804 if (sources != null) { | 887 if (sources != null) { |
| (...skipping 805 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1610 * Locations where the voter is eligible to vote early, prior to election day. | 1693 * Locations where the voter is eligible to vote early, prior to election day. |
| 1611 */ | 1694 */ |
| 1612 core.List<PollingLocation> earlyVoteSites; | 1695 core.List<PollingLocation> earlyVoteSites; |
| 1613 /** The election that was queried. */ | 1696 /** The election that was queried. */ |
| 1614 Election election; | 1697 Election election; |
| 1615 /** | 1698 /** |
| 1616 * Identifies what kind of resource this is. Value: the fixed string | 1699 * Identifies what kind of resource this is. Value: the fixed string |
| 1617 * "civicinfo#voterInfoResponse". | 1700 * "civicinfo#voterInfoResponse". |
| 1618 */ | 1701 */ |
| 1619 core.String kind; | 1702 core.String kind; |
| 1703 /** |
| 1704 * Specifies whether voters in the precinct vote only by mailing their ballots |
| 1705 * (with the possible option of dropping off their ballots as well). |
| 1706 */ |
| 1707 core.bool mailOnly; |
| 1620 /** The normalized version of the requested address */ | 1708 /** The normalized version of the requested address */ |
| 1621 SimpleAddressType normalizedInput; | 1709 SimpleAddressType normalizedInput; |
| 1622 /** | 1710 /** |
| 1623 * If no election ID was specified in the query, and there was more than one | 1711 * If no election ID was specified in the query, and there was more than one |
| 1624 * election with data for the given voter, this will contain information about | 1712 * election with data for the given voter, this will contain information about |
| 1625 * the other elections that could apply. | 1713 * the other elections that could apply. |
| 1626 */ | 1714 */ |
| 1627 core.List<Election> otherElections; | 1715 core.List<Election> otherElections; |
| 1628 /** Locations where the voter is eligible to vote on election day. */ | 1716 /** Locations where the voter is eligible to vote on election day. */ |
| 1629 core.List<PollingLocation> pollingLocations; | 1717 core.List<PollingLocation> pollingLocations; |
| (...skipping 15 matching lines...) Expand all Loading... |
| 1645 } | 1733 } |
| 1646 if (_json.containsKey("earlyVoteSites")) { | 1734 if (_json.containsKey("earlyVoteSites")) { |
| 1647 earlyVoteSites = _json["earlyVoteSites"].map((value) => new PollingLocatio
n.fromJson(value)).toList(); | 1735 earlyVoteSites = _json["earlyVoteSites"].map((value) => new PollingLocatio
n.fromJson(value)).toList(); |
| 1648 } | 1736 } |
| 1649 if (_json.containsKey("election")) { | 1737 if (_json.containsKey("election")) { |
| 1650 election = new Election.fromJson(_json["election"]); | 1738 election = new Election.fromJson(_json["election"]); |
| 1651 } | 1739 } |
| 1652 if (_json.containsKey("kind")) { | 1740 if (_json.containsKey("kind")) { |
| 1653 kind = _json["kind"]; | 1741 kind = _json["kind"]; |
| 1654 } | 1742 } |
| 1743 if (_json.containsKey("mailOnly")) { |
| 1744 mailOnly = _json["mailOnly"]; |
| 1745 } |
| 1655 if (_json.containsKey("normalizedInput")) { | 1746 if (_json.containsKey("normalizedInput")) { |
| 1656 normalizedInput = new SimpleAddressType.fromJson(_json["normalizedInput"])
; | 1747 normalizedInput = new SimpleAddressType.fromJson(_json["normalizedInput"])
; |
| 1657 } | 1748 } |
| 1658 if (_json.containsKey("otherElections")) { | 1749 if (_json.containsKey("otherElections")) { |
| 1659 otherElections = _json["otherElections"].map((value) => new Election.fromJ
son(value)).toList(); | 1750 otherElections = _json["otherElections"].map((value) => new Election.fromJ
son(value)).toList(); |
| 1660 } | 1751 } |
| 1661 if (_json.containsKey("pollingLocations")) { | 1752 if (_json.containsKey("pollingLocations")) { |
| 1662 pollingLocations = _json["pollingLocations"].map((value) => new PollingLoc
ation.fromJson(value)).toList(); | 1753 pollingLocations = _json["pollingLocations"].map((value) => new PollingLoc
ation.fromJson(value)).toList(); |
| 1663 } | 1754 } |
| 1664 if (_json.containsKey("precinctId")) { | 1755 if (_json.containsKey("precinctId")) { |
| (...skipping 14 matching lines...) Expand all Loading... |
| 1679 } | 1770 } |
| 1680 if (earlyVoteSites != null) { | 1771 if (earlyVoteSites != null) { |
| 1681 _json["earlyVoteSites"] = earlyVoteSites.map((value) => (value).toJson()).
toList(); | 1772 _json["earlyVoteSites"] = earlyVoteSites.map((value) => (value).toJson()).
toList(); |
| 1682 } | 1773 } |
| 1683 if (election != null) { | 1774 if (election != null) { |
| 1684 _json["election"] = (election).toJson(); | 1775 _json["election"] = (election).toJson(); |
| 1685 } | 1776 } |
| 1686 if (kind != null) { | 1777 if (kind != null) { |
| 1687 _json["kind"] = kind; | 1778 _json["kind"] = kind; |
| 1688 } | 1779 } |
| 1780 if (mailOnly != null) { |
| 1781 _json["mailOnly"] = mailOnly; |
| 1782 } |
| 1689 if (normalizedInput != null) { | 1783 if (normalizedInput != null) { |
| 1690 _json["normalizedInput"] = (normalizedInput).toJson(); | 1784 _json["normalizedInput"] = (normalizedInput).toJson(); |
| 1691 } | 1785 } |
| 1692 if (otherElections != null) { | 1786 if (otherElections != null) { |
| 1693 _json["otherElections"] = otherElections.map((value) => (value).toJson()).
toList(); | 1787 _json["otherElections"] = otherElections.map((value) => (value).toJson()).
toList(); |
| 1694 } | 1788 } |
| 1695 if (pollingLocations != null) { | 1789 if (pollingLocations != null) { |
| 1696 _json["pollingLocations"] = pollingLocations.map((value) => (value).toJson
()).toList(); | 1790 _json["pollingLocations"] = pollingLocations.map((value) => (value).toJson
()).toList(); |
| 1697 } | 1791 } |
| 1698 if (precinctId != null) { | 1792 if (precinctId != null) { |
| 1699 _json["precinctId"] = precinctId; | 1793 _json["precinctId"] = precinctId; |
| 1700 } | 1794 } |
| 1701 if (state != null) { | 1795 if (state != null) { |
| 1702 _json["state"] = state.map((value) => (value).toJson()).toList(); | 1796 _json["state"] = state.map((value) => (value).toJson()).toList(); |
| 1703 } | 1797 } |
| 1704 return _json; | 1798 return _json; |
| 1705 } | 1799 } |
| 1706 } | 1800 } |
| OLD | NEW |