OSID Logo
OSID Specifications
voting package
Version 3.1.0
Interfaceosid.voting.BallotAuthoringSession
Implementsosid.OsidSession
Description

This session provides methods for authoring ballots.

MethodgetBallotId
Description

Gets the Ballot Id associated with this session.

Returnosid.id.Id the Ballot Id associated with this session
Compliancemandatory This method must be implemented.
MethodgetBallot
Description

Gets the Ballot associated with this session.

Returnosid.voting.Ballot the Ballot associated with this session
ErrorsOPERATION_FAILED unable to complete request
PERMISSION_DENIED authorization failure
Compliancemandatory This method must be implemented.
MethodcanAuthorBallots
Description

Tests if this user can perform author ballots. A return of true does not guarantee successful authorization. A return of false indicates that it is known all methods in this session will result in a PERMISSION_DENIED. This is intended as a hint to an application that may opt not to offer lookup operations to unauthorized users.

Returnboolean false if lookup methods are not authorized, true otherwise
Compliancemandatory This method must be implemented.
MethodgetRaces
Description

Gets the races on this ballot.

Returnosid.voting.RaceList the races
ErrorsOPERATION_FAILED unable to complete request
PERMISSION_DENIED authorization failure
Compliancemandatory This method is must be implemented.
MethodaddRace
Description

Adds a race to this ballot.

Parametersosid.id.IdraceId the Id of the Race
ErrorsALREADY_EXISTS raceId already in ballot
NOT_FOUND raceId not found
NULL_ARGUMENT raceId is null
OPERATION_FAILED unable to complete request
PERMISSION_DENIED authorization failure occurred
Compliancemandatory This method must be implemented.
MethodremoveRace
Description

Removes a Race from this ballot.

Parametersosid.id.IdraceId the Id of the Race
ErrorsNOT_FOUND raceId not in ballot
NULL_ARGUMENT raceId is null
OPERATION_FAILED unable to complete request
PERMISSION_DENIED authorization failure occurred
Compliancemandatory This method must be implemented.
MethodmoveRace
Description

Moves an existing race to follow another race in this ballot.

Parametersosid.id.IdraceId the Id of a Race
osid.id.IdprecedingRaceId the Id of a preceding Race in the sequence
ErrorsNOT_FOUND raceId or precedingRaceId is not found
NULL_ARGUMENT raceId or precedingRaceId is null
OPERATION_FAILED unable to complete request
PERMISSION_DENIED authorization failure occurred
Compliancemandatory This method must be implemented.
MethodorderRaces
Description

Sequences existing races on this ballot.

Parametersosid.id.Id[]raceIds the Id of the Races
ErrorsNOT_FOUND a raceId was not found
NULL_ARGUMENT raceIds is null
OPERATION_FAILED unable to complete request
PERMISSION_DENIED authorization failure occurred
Compliancemandatory This method must be implemented.