選舉報告

使用 ElectionReport 做為根實體。定義與報表狀態、格式和產生時間相關的項目。

ElectionReport 包含下列主要元素:

Election 相同,ElectionReport 會「包裝」元素出現的位置,但 Election 除外,這些位置位於容器元素中。這樣就能在 XML 檢視器和編輯器中,更輕鬆地操控執行個體檔案。

有時,保留特定項目排序方式很重要,例如辦公室或政黨。在這些情況下,我們希望產生應用程式能根據現有的排序方式定義這些元素。

元素

下表列出 ElectionReport 的元素:

元素 多重性 類型 說明
CommitteeCollection 0 或 1 N/A 定義的包裝函式元素。Committee詳情請參閱「集合實體」。
DataSourceCollection 0 或 1 N/A 定義的包裝函式元素。DataSource詳情請參閱「集合實體」。
Election 0 以上 Election 將選舉與報告建立關聯。
ElectoralCommissionCollection 0 或 1 N/A 定義的包裝函式元素。ElectoralCommission詳情請參閱「集合實體」。
ExternalIdentifiers 0 或 1 ExternalIdentifiers 將 ID 與報表建立關聯。
Format 1 ReportDetailLevel 提供報表的詳細程度,例如是競賽摘要還是選區層級結果。
GeneratedDate 1 dateTime 表示選舉報表產生的日期和時間。
GpUnitCollection 0 或 1 N/A 定義的包裝函式元素。GpUnit詳情請參閱「集合實體」。
Issuer 1 string 報告核發者的識別資訊。
IssuerAbbreviation 0 或 1 string 報表發布者的縮寫,例如結果所屬州或選區的縮寫。
IsTest 0 或 1 boolean 指出報表是否為測試報告。如未提供這個元素,預設值為 false
Notes 0 或 1 string 用於在報表中加入任意訊息。
OfficeCollection 0 或 1 N/A 定義的包裝函式元素。Office詳情請參閱「集合實體」。
GovernmentBodyCollection 0 或 1 N/A 定義的包裝函式元素。GovernmentBody詳情請參閱「集合實體」。
PartyCollection 0 或 1 N/A 定義的包裝函式元素。Party詳情請參閱「集合實體」。
PersonCollection 0 或 1 N/A 定義的包裝函式元素。Person詳情請參閱「集合實體」。
SequenceStart 1 integer 報表在報表序列中的編號。這個元素會與 SequenceEnd 搭配使用,例如讀取為「1/1」、「1/2」或「2/2」。開頭為「1」。
SequenceEnd 1 integer 一系列報表的上限。舉例來說,如果只有一份報表,這個值就是 1;如果序列中有兩份報表,這個值就是 2
Status 1 ResultsStatus 選舉報告的狀態,例如選舉前或非官方。
TestType 0 或 1 string 測試類型說明,例如選舉前測試或邏輯與準確度測試。
VendorApplicationId 1 string 產生選舉報表的供應商應用程式 ID。例如 X-EMS version 3.1.a
VoterInformationCollection 0 或 1 N/A 定義的包裝函式元素。VoterInformation詳情請參閱「集合實體」。

範例

XML

    <ElectionReport xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
      <DataSourceCollection>
        <DataSource objectId="ds-1">…</DataSource>
      </DataSourceCollection>
      <Election>…</Election>
      <GpUnitCollection>
        <GpUnit objectId="ru-gpu0">…</GpUnit>
        <GpUnit objectId="ru-gpu1">…</GpUnit>
      </GpUnitCollection>
      <OfficeCollection>
        <Office objectId="off-0001a">…</Office>
      </OfficeCollection>
      <GovernmentBodyCollection>
        <GovernmentBody objectId="gb-0001a">…</GovernmentBody>
      </GovernmentBodyCollection>
      <PartyCollection>
        <Party objectId="par-001">…</Party>
        <Party objectId="par-002">…</Party>
      </PartyCollection>
      <PersonCollection>
        <Person objectId="per-001">…</Person>
        <Person objectId="per-002">…</Person>
      </PersonCollection>
      <Issuer>Example Data Provider</Issuer>
      <IssuerAbbreviation>EDP</IssuerAbbreviation>
      <Format>summary-contest</Format>
      <GeneratedDate>2013-11-05T14:25:28</GeneratedDate>
      <Status>unofficial-partial</Status>
      <VendorApplicationId>Hand-Generated v0.1</VendorApplicationId>
      <SequenceStart>1</SequenceStart>
      <SequenceEnd>1</SequenceEnd>
    </ElectionReport>