| Interface | osid.voting.CandidatePollsSession | ||
|---|---|---|---|
| Implements | osid.OsidSession | ||
| Description | 
                 This session provides methods to retrieve  This lookup session defines several views: 
  | ||
| Method | useComparativePollsView | ||
| 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 | usePlenaryPollsView | ||
| Description | 
                     A complete view of the   | ||
| Compliance | mandatory | This method is must be implemented. | |
| Method | canLookupCandidatePollsMappings | ||
| Description | 
                     Tests if this user can perform lookups of 
                    candidate/polls mappings. A return of true does not 
                    guarantee successful authorization. A return of false 
                    indicates that it is known lookup methods in this session 
                    will result in a   | ||
| Return | boolean |  false  if looking up mappings is not authorized,  true 
 otherwise  | |
| Compliance | mandatory | This method must be implemented. | |
| Method | getCandidateIdsByPolls | ||
| Description | 
                     Gets the list of   | ||
| Parameters | osid.id.Id | pollsId |  Id  of a  Polls   | 
| Return | osid.id.IdList | list of related candidate  Ids   | |
| Errors | NOT_FOUND |  pollsId  is not found  |                 |
| NULL_ARGUMENT |  pollsId  is  null   |                 ||
| OPERATION_FAILED | unable to complete request | ||
| PERMISSION_DENIED | authorization failure | ||
| Compliance | mandatory | This method must be implemented. | |
| Method | getCandidatesByPolls | ||
| Description | 
                     Gets the list of   | ||
| Parameters | osid.id.Id | pollsId |  Id  of a  Polls   | 
| Return | osid.voting.CandidateList | list of related candidates | |
| Errors | NOT_FOUND |  pollsId  is not found  |                 |
| NULL_ARGUMENT |  pollsId  is  null   |                 ||
| OPERATION_FAILED | unable to complete request | ||
| PERMISSION_DENIED | authorization failure | ||
| Compliance | mandatory | This method must be implemented. | |
| Method | getCandidateIdsByPolls | ||
| Description | 
                     Gets the list of   | ||
| Parameters | osid.id.IdList | pollsIds | list of polls  Ids   | 
| Return | osid.id.IdList | list of candidate  Ids   | |
| Errors | NULL_ARGUMENT |  pollsIds  is  null   |                 |
| OPERATION_FAILED | unable to complete request | ||
| PERMISSION_DENIED | authorization failure | ||
| Compliance | mandatory | This method must be implemented. | |
| Method | getCandidatesByPolls | ||
| Description | 
                     Gets the list of   | ||
| Parameters | osid.id.IdList | pollsIds | list of polls  Ids   | 
| Return | osid.voting.CandidateList | list of candidates | |
| Errors | NULL_ARGUMENT |  pollsIds  is  null   |                 |
| OPERATION_FAILED | unable to complete request | ||
| PERMISSION_DENIED | authorization failure | ||
| Compliance | mandatory | This method must be implemented. | |
| Method | getPollsIdsByCandidate | ||
| Description | 
                     Gets the list of   | ||
| Parameters | osid.id.Id | candidateId |  Id  of a  Candidate   | 
| Return | osid.id.IdList | list of polls  Ids   | |
| Errors | NOT_FOUND |  candidateId  is not found  |                 |
| NULL_ARGUMENT |  candidateId  is  null   |                 ||
| OPERATION_FAILED | unable to complete request | ||
| PERMISSION_DENIED | authorization failure | ||
| Compliance | mandatory | This method must be implemented. | |
| Method | getPollsByCandidate | ||
| Description | 
                     Gets the list of   | ||
| Parameters | osid.id.Id | candidateId |  Id  of a  Candidate   | 
| Return | osid.voting.PollsList | list of polls | |
| Errors | NOT_FOUND |  candidateId  is not found  |                 |
| NULL_ARGUMENT |  candidateId  is  null   |                 ||
| OPERATION_FAILED | unable to complete request | ||
| PERMISSION_DENIED | authorization failure | ||
| Compliance | mandatory | This method must be implemented. | |