Interface | osid.voting.VoteLookupSession | ||
---|---|---|---|
Implements | osid.OsidSession | ||
Description |
This session provides methods for looking up votes. This session defines views that offer differing behaviors when retrieving multiple objects.
| ||
Method | getPollsId | ||
Description |
Gets the | ||
Return | osid.id.Id | the Polls Id associated with this session | |
Compliance | mandatory | This method must be implemented. | |
Method | getPolls | ||
Description |
Gets the | ||
Return | osid.voting.Polls | the Polls associated with this session | |
Errors | OPERATION_FAILED | unable to complete request | |
PERMISSION_DENIED | authorization failure | ||
Compliance | mandatory | This method must be implemented. | |
Method | canLookupVotes | ||
Description |
Tests if this user can access votes. 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 | ||
Return | boolean | false if voting methods are not authorized, true
otherwise | |
Compliance | mandatory | This method must be implemented. | |
Method | useComparativeVoteView | ||
Description |
The returns from the lookup methods may omit or translate elements based on this session, such as authorization, and not result in an error. This view is used when greater interoperability is desired at the expense of precision. | ||
Compliance | mandatory | This method is must be implemented. | |
Method | usePlenaryVoteView | ||
Description |
A complete view of the vote returns is desired. Methods will return what is requested or result in an error. This view is used when greater precision is desired at the expense of interoperability. | ||
Compliance | mandatory | This method is must be implemented. | |
Method | useFederatedPollsView | ||
Description |
Federates the view for methods in this session. A federated view will include votes in polls which are children of this polls in the polls hierarchy. | ||
Compliance | mandatory | This method is must be implemented. | |
Method | useIsolatedPollsView | ||
Description |
Isolates the view for methods in this session. An isolated view restricts votes to these polls only. | ||
Compliance | mandatory | This method is must be implemented. | |
Method | useEffectiveVoteView | ||
Description |
Only votes whose effective dates are current are returned by methods in this session. | ||
Compliance | mandatory | This method is must be implemented. | |
Method | useAnyEffectiveVoteView | ||
Description |
All votes of any effective dates are returned by methods in this session. | ||
Compliance | mandatory | This method is must be implemented. | |
Method | getVote | ||
Description |
Gets a | ||
Parameters | osid.id.Id | voteId | Id of the Vote |
Return | osid.voting.Vote | the vote | |
Errors | NOT_FOUND | voteId not found | |
NULL_ARGUMENT | voteId is null | ||
OPERATION_FAILED | unable to complete request | ||
PERMISSION_DENIED | authorization failure | ||
Compliance | mandatory | This method is must be implemented. | |
Method | getVotesByIds | ||
Description |
Gets a In effective mode, votes are returned that are currently effective. In any effective mode, effective votes and those currently expired are returned. | ||
Parameters | osid.id.IdList | voteIds | the list of Ids to retrieve |
Return | osid.voting.VoteList | the returned Vote list | |
Errors | NOT_FOUND | an Id was not found | |
NULL_ARGUMENT | voteIds is null | ||
OPERATION_FAILED | unable to complete request | ||
PERMISSION_DENIED | authorization failure | ||
Compliance | mandatory | This method must be implemented. | |
Method | getVotesByGenusType | ||
Description |
Gets the votes for the given vote genus type. In plenary mode, the returned list contains all known votes or an error results. Otherwise, the returned list may contain only those votes that are accessible through this session. In effective mode, votes are returned that are currently effective. In any effective mode, effective votes and those currently expired are returned. | ||
Parameters | osid.type.Type | voteGenusType | a vote genus type |
Return | osid.voting.VoteList | the votes | |
Errors | NULL_ARGUMENT | voteGenusType is null | |
OPERATION_FAILED | unable to complete request | ||
PERMISSION_DENIED | authorization failure | ||
Compliance | mandatory | This method must be implemented. | |
Method | getVotesByParentGenusType | ||
Description |
Gets the votes for the given vote genus type and include any votes with a genus type derived from the specified genus type. In plenary mode, the returned list contains all known votes or an error results. Otherwise, the returned list may contain only those votes that are accessible through this session. In effective mode, votes are returned that are currently effective. In any effective mode, effective votes and those currently expired are returned. | ||
Parameters | osid.type.Type | voteGenusType | a vote genus type |
Return | osid.voting.VoteList | the votes | |
Errors | NULL_ARGUMENT | voteGenusType is null | |
OPERATION_FAILED | unable to complete request | ||
PERMISSION_DENIED | authorization failure | ||
Compliance | mandatory | This method must be implemented. | |
Method | getVotesByRecordType | ||
Description |
Gets the votes for the given vote record type. In plenary mode, the returned list contains all known votes or an error results. Otherwise, the returned list may contain only those votes that are accessible through this session. In effective mode, votes are returned that are currently effective. In any effective mode, effective votes and those currently expired are returned. | ||
Parameters | osid.type.Type | voteRecordType | a vote record type |
Return | osid.voting.VoteList | the votes | |
Errors | NULL_ARGUMENT | voteRecordType is null | |
OPERATION_FAILED | unable to complete request | ||
PERMISSION_DENIED | authorization failure | ||
Compliance | mandatory | This method must be implemented. | |
Method | getVotesOnDate | ||
Description |
Gets a list of votes effective during the entire given date range inclusive but not confined to the date range. In plenary mode, the returned list contains all known votes or an error results. Otherwise, the returned list may contain only those votes that are accessible through this session. In effective mode, votes are returned that are currently effective. In any effective mode, effective votes and those currently expired are returned. | ||
Parameters | osid.calendaring.DateTime | from | start of date range |
osid.calendaring.DateTime | to | end of date range | |
Return | osid.voting.VoteList | the returned Vote list | |
Errors | INVALID_ARGUMENT | from is greater than to | |
NULL_ARGUMENT | from or to is null | ||
OPERATION_FAILED | unable to complete request | ||
PERMISSION_DENIED | authorization failure | ||
Compliance | mandatory | This method must be implemented. | |
Method | getVotesForVoter | ||
Description |
Gets the votes cast by the given voter. In plenary mode, the returned list contains all of the
votes mapped to the candidate In effective mode, votes are returned that are currently effective. In any effective mode, effective votes and those currently expired are returned. | ||
Parameters | osid.id.Id | resourceId | Id of a Voter |
Return | osid.voting.VoteList | the votes | |
Errors | NULL_ARGUMENT | resourceId is null | |
OPERATION_FAILED | unable to complete request | ||
PERMISSION_DENIED | authorization failure | ||
Compliance | mandatory | This method must be implemented. | |
Method | getVotesForVoterOnDate | ||
Description |
Gets a list of votes for a voter effective during the
entire given date range inclusive but not confined to the
date range. In effective mode, votes are returned that are currently effective. In any effective mode, effective votes and those currently expired are returned. | ||
Parameters | osid.id.Id | resourceId | Id of a Voter |
osid.calendaring.DateTime | from | start of date range | |
osid.calendaring.DateTime | to | end of date range | |
Return | osid.voting.VoteList | the returned Vote list | |
Errors | INVALID_ARGUMENT | from is greater than to | |
NULL_ARGUMENT | resourceId, from or to is null | ||
OPERATION_FAILED | unable to complete request | ||
PERMISSION_DENIED | authorization failure | ||
Compliance | mandatory | This method must be implemented. | |
Method | getVotesForCandidate | ||
Description |
Gets the In plenary mode, the returned list contains all known votes or an error results. Otherwise, the returned list may contain only those votes that are accessible through this session. In effective mode, votes are returned that are currently effective. In any effective mode, effective votes and those currently expired are returned. | ||
Parameters | osid.id.Id | candidateId | Id of a Candidate |
Return | osid.voting.VoteList | the votes | |
Errors | NULL_ARGUMENT | candidateId is null | |
OPERATION_FAILED | unable to complete request | ||
PERMISSION_DENIED | authorization failure | ||
Compliance | mandatory | This method must be implemented. | |
Method | getVotesForCandidateOnDate | ||
Description |
Gets a list of votes for a candidate effective during
the entire given date range inclusive but not confined to
the date range. In effective mode, votes are returned that are currently effective. In any effective mode, effective votes and those currently expired are returned. | ||
Parameters | osid.id.Id | candidateId | Id of a Candidate |
osid.calendaring.DateTime | from | start of date range | |
osid.calendaring.DateTime | to | end of date range | |
Return | osid.voting.VoteList | the returned Vote list | |
Errors | INVALID_ARGUMENT | from is greater than to | |
NULL_ARGUMENT | candidateId, from or to is null
| ||
OPERATION_FAILED | unable to complete request | ||
PERMISSION_DENIED | authorization failure | ||
Compliance | mandatory | This method must be implemented. | |
Method | getVotesForVoterAndCandidate | ||
Description |
Gets the votes cast by the given voter and candidate. In plenary mode, the returned list contains all of the
votes mapped to the candidate In effective mode, votes are returned that are currently effective. In any effective mode, effective votes and those currently expired are returned. | ||
Parameters | osid.id.Id | resourceId | Id of a Voter |
osid.id.Id | candidateId | Id of a Candidate | |
Return | osid.voting.VoteList | the votes | |
Errors | NULL_ARGUMENT | resourceId or candidateId is null
| |
OPERATION_FAILED | unable to complete request | ||
PERMISSION_DENIED | authorization failure | ||
Compliance | mandatory | This method must be implemented. | |
Method | getVotesForVoterAndCandidateOnDate | ||
Description |
Gets a list of votes for a voter and candidate
effective during the entire given date range inclusive but
not confined to the date range. In effective mode, votes are returned that are currently effective. In any effective mode, effective votes and those currently expired are returned. | ||
Parameters | osid.id.Id | resourceId | Id of a Voter |
osid.id.Id | candidateId | Id of a Candidate | |
osid.calendaring.DateTime | from | start of date range | |
osid.calendaring.DateTime | to | end of date range | |
Return | osid.voting.VoteList | the returned Vote list | |
Errors | INVALID_ARGUMENT | from is greater than to | |
NULL_ARGUMENT | resourceId, candidateId, from or to is
null | ||
OPERATION_FAILED | unable to complete request | ||
PERMISSION_DENIED | authorization failure | ||
Compliance | mandatory | This method must be implemented. | |
Method | getVotesForRace | ||
Description |
Gets the votes cast in the given race. In plenary mode, the returned list contains all of the
votes mapped to the candidate In effective mode, votes are returned that are currently effective. In any effective mode, effective votes and those currently expired are returned. | ||
Parameters | osid.id.Id | raceId | Id of a Race |
Return | osid.voting.VoteList | the votes | |
Errors | NULL_ARGUMENT | ballotId is null | |
OPERATION_FAILED | unable to complete request | ||
PERMISSION_DENIED | authorization failure | ||
Compliance | mandatory | This method must be implemented. | |
Method | getVotesForRaceOnDate | ||
Description |
Gets a list of votes in a race effective during the
entire given date range inclusive but not confined to the
date range. In effective mode, votes are returned that are currently effective. In any effective mode, effective votes and those currently expired are returned. | ||
Parameters | osid.id.Id | raceId | Id of a Race |
osid.calendaring.DateTime | from | start of date range | |
osid.calendaring.DateTime | to | end of date range | |
Return | osid.voting.VoteList | the returned Vote list | |
Errors | INVALID_ARGUMENT | from is greater than to | |
NULL_ARGUMENT | raceId, from or to is null | ||
OPERATION_FAILED | unable to complete request | ||
PERMISSION_DENIED | authorization failure | ||
Compliance | mandatory | This method must be implemented. | |
Method | getVotesForVoterAndRace | ||
Description |
Gets the votes cast by the given voter and race. In plenary mode, the returned list contains all of the
votes mapped to the candidate In effective mode, votes are returned that are currently effective. In any effective mode, effective votes and those currently expired are returned. | ||
Parameters | osid.id.Id | resourceId | Id of a Voter |
osid.id.Id | raceId | Id of a Race | |
Return | osid.voting.VoteList | the votes | |
Errors | NULL_ARGUMENT | resourceId or raceId is null | |
OPERATION_FAILED | unable to complete request | ||
PERMISSION_DENIED | authorization failure | ||
Compliance | mandatory | This method must be implemented. | |
Method | getVotesForVoterAndRaceOnDate | ||
Description |
Gets a list of votes for a voter and race effective
during the entire given date range inclusive but not
confined to the date range. In effective mode, votes are returned that are currently effective. In any effective mode, effective votes and those currently expired are returned. | ||
Parameters | osid.id.Id | resourceId | Id of a Voter |
osid.id.Id | raceId | Id of a Race | |
osid.calendaring.DateTime | from | start of date range | |
osid.calendaring.DateTime | to | end of date range | |
Return | osid.voting.VoteList | the returned Vote list | |
Errors | INVALID_ARGUMENT | from is greater than to | |
NULL_ARGUMENT | resourceId, raceId, from or to is null
| ||
OPERATION_FAILED | unable to complete request | ||
PERMISSION_DENIED | authorization failure | ||
Compliance | mandatory | This method must be implemented. | |
Method | getVotesForBallot | ||
Description |
Gets the votes cast in the given ballot. In plenary mode, the returned list contains all of the
votes mapped to the candidate In effective mode, votes are returned that are currently effective. In any effective mode, effective votes and those currently expired are returned. | ||
Parameters | osid.id.Id | ballotId | Id of a Ballot |
Return | osid.voting.VoteList | the votes | |
Errors | NULL_ARGUMENT | ballotId is null | |
OPERATION_FAILED | unable to complete request | ||
PERMISSION_DENIED | authorization failure | ||
Compliance | mandatory | This method must be implemented. | |
Method | getVotesForBallotOnDate | ||
Description |
Gets a list of votes in a ballot effective during the
entire given date range inclusive but not confined to the
date range. In effective mode, votes are returned that are currently effective. In any effective mode, effective votes and those currently expired are returned. | ||
Parameters | osid.id.Id | ballotId | Id of a Ballot |
osid.calendaring.DateTime | from | start of date range | |
osid.calendaring.DateTime | to | end of date range | |
Return | osid.voting.VoteList | the returned Vote list | |
Errors | INVALID_ARGUMENT | from is greater than to | |
NULL_ARGUMENT | ballotId, from or to is null | ||
OPERATION_FAILED | unable to complete request | ||
PERMISSION_DENIED | authorization failure | ||
Compliance | mandatory | This method must be implemented. | |
Method | getVotesForVoterAndBallot | ||
Description |
Gets the votes cast by the given voter and ballot. In plenary mode, the returned list contains all of the
votes mapped to the candidate In effective mode, votes are returned that are currently effective. In any effective mode, effective votes and those currently expired are returned. | ||
Parameters | osid.id.Id | resourceId | Id of a Voter |
osid.id.Id | ballotId | Id of a Ballot | |
Return | osid.voting.VoteList | the votes | |
Errors | NULL_ARGUMENT | resourceId or ballotId is null | |
OPERATION_FAILED | unable to complete request | ||
PERMISSION_DENIED | authorization failure | ||
Compliance | mandatory | This method must be implemented. | |
Method | getVotesForVoterAndBallotOnDate | ||
Description |
Gets a list of votes for a voter and ballot effective
during the entire given date range inclusive but not
confined to the date range. In effective mode, votes are returned that are currently effective. In any effective mode, effective votes and those currently expired are returned. | ||
Parameters | osid.id.Id | resourceId | Id of a Voter |
osid.id.Id | ballotId | Id of a Ballot | |
osid.calendaring.DateTime | from | start of date range | |
osid.calendaring.DateTime | to | end of date range | |
Return | osid.voting.VoteList | the returned Vote list | |
Errors | INVALID_ARGUMENT | from is greater than to | |
NULL_ARGUMENT | resourceId, ballotId, from or to is
null | ||
OPERATION_FAILED | unable to complete request | ||
PERMISSION_DENIED | authorization failure | ||
Compliance | mandatory | This method must be implemented. | |
Method | getVotes | ||
Description |
Gets all votes. In plenary mode, the returned list contains all of the
votes mapped to the candidate In effective mode, votes are returned that are currently effective. In any effective mode, effective votes and those currently expired are returned. | ||
Return | osid.voting.VoteList | the votes | |
Errors | OPERATION_FAILED | unable to complete request | |
PERMISSION_DENIED | authorization failure | ||
Compliance | mandatory | This method must be implemented. |