OSID Logo
OSID Specifications
voting rules package
Version 3.1.0
Interfaceosid.voting.rules.RaceProcessor
Implementsosid.OsidProcessor
Used Byosid.voting.rules.RaceProcessorAdminSession
osid.voting.rules.RaceProcessorList
osid.voting.rules.RaceProcessorLookupSession
Description

A RaceProcessor describes the rules for managing the behavior of a race.

MethodhasMaximumWinners
Description

Tests if there is a limit on the number of winners in a race.

Returnboolean true if a limit on the number of winners, false if no limit exists
Compliancemandatory This method must be implemented.
MethodgetMaximumWinners
Description

Gets the number of maximum winners in a race.

Returncardinal the maximum number of winners permitted
ErrorsILLEGAL_STATE hasMaximumWinners() is false
Compliancemandatory This method must be implemented.
MethodgetMinimumPercentageToWin
Description

Gets the minimum percentage (0-100) of total votes to be declared a winner in a race.

Returncardinal the minimum percentage
Compliancemandatory This method must be implemented.
MethodgetMinimumVotesToWin
Description

Gets the minimum votesl votes to be declared a winner in a race.

Returncardinal the minimum votes
Compliancemandatory This method must be implemented.
MethodgetRaceProcessorRecord
Description

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

Parametersosid.type.TyperaceProcessorRecordType the type of race processor record to retrieve
Returnosid.voting.rules.records.RaceProcessorRecord the race processor record
ErrorsNULL_ARGUMENT raceProcessorRecordType is null
OPERATION_FAILED unable to complete request
UNSUPPORTED hasRecordType(raceProcessorRecordType) is false
Compliancemandatory This method must be implemented.