OSID Logo
OSID Specifications
voting rules package
Version 3.1.0
Interfaceosid.voting.rules.RaceConstrainerPollsAssignmentSession
Implementsosid.OsidSession
Used Byosid.voting.rules.VotingRulesManager
osid.voting.rules.VotingRulesProxyManager
Description

This session provides methods to re-assign RaceConstrainer to Polls mappings. a RaceConstrainer may appear in multiple Polls objects and removing the last reference to a RaceConstrainer is the equivalent of deleting it. Each Polls may have its own authorizations governing who is allowed to operate on it.

Adding a reference of a RaceConstrainer to another Polls is not a copy operation (eg: does not change its Id).

MethodcanAssignRaceConstrainers
Description

Tests if this user can alter race constrainer/polls mappings. A return of true does not guarantee successful authorization. A return of false indicates that it is known mapping 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 mapping is not authorized, true otherwise
Compliancemandatory This method must be implemented.
MethodcanAssignRaceConstrainersToPolls
Description

Tests if this user can alter race constrainer/polls mappings. A return of true does not guarantee successful authorization. A return of false indicates that it is known mapping 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.

Parametersosid.id.IdpollsId the Id of the Polls
Returnboolean false if mapping is not authorized, true otherwise
ErrorsNULL_ARGUMENT pollsId is null
Compliancemandatory This method must be implemented.
MethodgetAssignablePollsIds
Description

Gets a list of polls including and under the given polls node in which any race constrainer can be assigned.

Parametersosid.id.IdpollsId the Id of the Polls
Returnosid.id.IdList list of assignable polls Ids
ErrorsNULL_ARGUMENT pollsId is null
OPERATION_FAILED unable to complete request
Compliancemandatory This method must be implemented.
MethodgetAssignablePollsIdsForRaceConstrainer
Description

Gets a list of polls including and under the given polls node in which a specific race constrainer can be assigned.

Parametersosid.id.IdpollsId the Id of the Polls
osid.id.IdraceConstrainerId the Id of the RaceConstrainer
Returnosid.id.IdList list of assignable polls Ids
ErrorsNULL_ARGUMENT pollsId or raceConstrainerId is null
OPERATION_FAILED unable to complete request
Compliancemandatory This method must be implemented.
MethodassignRaceConstrainerToPolls
Description

Adds an existing RaceConstrainer to a Polls.

Parametersosid.id.IdraceConstrainerId the Id of the RaceConstrainer
osid.id.IdpollsId the Id of the Polls
ErrorsALREADY_EXISTS raceConstrainerId is already assigned to pollsId
NOT_FOUND raceConstrainerId or pollsId not found
NULL_ARGUMENT raceConstrainerId or pollsId is null
OPERATION_FAILED unable to complete request
PERMISSION_DENIED authorization failure
Compliancemandatory This method must be implemented.
MethodunassignRaceConstrainerFromPolls
Description

Removes a RaceConstrainer from a Polls.

Parametersosid.id.IdraceConstrainerId the Id of the RaceConstrainer
osid.id.IdpollsId the Id of the Polls
ErrorsNOT_FOUND raceConstrainerId or pollsId not found or raceConstrainerId not assigned to pollsId
NULL_ARGUMENT raceConstrainerId or pollsId is null
OPERATION_FAILED unable to complete request
PERMISSION_DENIED authorization failure
Compliancemandatory This method must be implemented.
MethodreassignRaceConstrainerToPolls
Description

Moves a RaceConstrainer from one Polls to another. Mappings to other Polls are unaffected.

Parametersosid.id.IdraceConstrainerId the Id of the RaceConstrainer
osid.id.IdfromPollsId the Id of the current Polls
osid.id.IdtoPollsId the Id of the destination Polls
ErrorsALREADY_EXISTS raceConstrainerId already assigned to toPollsId
NOT_FOUND raceConstrainerId, fromPollsId, or toPollsId not found or raceConstrainerId not mapped to fromPollsId
NULL_ARGUMENT raceConstrainerId, fromPollsId, or toPollsId is null
OPERATION_FAILED unable to complete request
PERMISSION_DENIED authorization failure
Compliancemandatory This method must be implemented.