OSID Logo
OSID Specifications
voting package
Version 3.0.0
Release Candidate Preview
Interfaceosid.voting.RaceResult
Implementsosid.OsidCompendium
Description

The results for a candidate in a race.

MethodgetRaceId
Description

Geta the race Id of the vote.

Returnosid.id.Idthe ballot Id
CompliancemandatoryThis method must be implemented.
MethodgetRace
Description

Gets the race of the vote.

Returnosid.voting.Racethe race
ErrorsOPERATION_FAILEDunable to complete request
CompliancemandatoryThis method must be implemented.
MethodgetCandidateId
Description

Gets the candidate Id.

Returnosid.id.Ida candidate Id
CompliancemandatoryThis method must be implemented.
MethodgetCandidate
Description

Gets the Candidate.

Returnosid.voting.Candidatethe candidate
ErrorsOPERATION_FAILEDunable to complete request
CompliancemandatoryThis method must be implemented.
MethodgetResourceId
Description

Gets the resource Id . A resource represents a voter or group of voters across a demographic.

Returnosid.id.Ida resource Id
CompliancemandatoryThis method must be implemented.
MethodgetResource
Description

Gets the Resource. A resource represents a voter or group of voters across a demographic.

Returnosid.resource.Resourcethe resource
ErrorsOPERATION_FAILEDunable to complete request
CompliancemandatoryThis method must be implemented.
MethodisFinal
Description

Tests if these results are final.

Returnboolean true if these results are final, false otherwise
CompliancemandatoryThis method must be implemented.
MethodgetTotalVotes
Description

Gets the total number of votes cast for this candidate.

Returnintegerthe total number of votes cast
CompliancemandatoryThis method must be implemented.
MethodgetMeanVotes
Description

Gets the mean number of votes cast for this candidate.

Returndecimalthe mean number of votes cast
CompliancemandatoryThis method must be implemented.
MethodgetMedianVotes
Description

Gets the median number of votes cast for this candidate.

Returnintegerthe median number of votes cast
CompliancemandatoryThis method must be implemented.
MethodgetVoteStandardDeviation
Description

Gets the standard deviation of the votes.

Returndecimalthe standard deviation
CompliancemandatoryThis method must be implemented.
MethodgetRaceResultRecord
Description

Gets the race result record corresponding to the given RaceResults record Type. This method is used to retrieve an object implementing the requested record. The raceResultsRecordType may be the Type returned in getRecordTypes() or any of its parents in a Type hierarchy where hasRecordType(raceResultsRecordType) is true .

Parametersosid.type.TyperaceResultsRecordTypethe type of the record to retrieve
Returnosid.voting.records.RaceResultRecordthe race results record
ErrorsNULL_ARGUMENT raceResultsRecordType is null
OPERATION_FAILEDunable to complete request
UNSUPPORTED hasRecordType(raceResultsRecordType) is false
CompliancemandatoryThis method must be implemented.