OSID Logo
OSID Specifications
voting package
Version 3.0.0
Release Candidate Preview
Interfaceosid.voting.VoteSearchOrder
Implementsosid.OsidRelationshipSearchOrder
Description

An interface for specifying the ordering of search results.

MethodorderByCandidate
Description

Specified a preference for ordering results by the candidate.

Parametersosid.SearchOrderStylestylesearch order style
ErrorsNULL_ARGUMENT style is null
CompliancemandatoryThis method must be implemented.
MethodsupportsCandidateSearchOrder
Description

Tests if a CandidateSearchOrder is available.

Returnboolean true if a candidate search order is available, false otherwise
CompliancemandatoryThis method must be implemented.
MethodgetCandidateSearchOrder
Description

Gets the search order interface for a candidate.

Returnosid.voting.CandidateSearchOrderthe candidate search order
ErrorsUNIMPLEMENTED supportsCandidateSearchOrder() is false
ComplianceoptionalThis method must be implemented if supportsCandidateSearchOrder() is true.
MethodorderByVoter
Description

Specified a preference for ordering results by the voter.

Parametersosid.SearchOrderStylestylesearch order style
ErrorsNULL_ARGUMENT style is null
CompliancemandatoryThis method must be implemented.
MethodsupportsVoterSearchOrder
Description

Tests if a ResourceSearchOrder is available.

Returnboolean true if a resource search order is available, false otherwise
CompliancemandatoryThis method must be implemented.
MethodgetVoterSearchOrder
Description

Gets the search order for a resource.

Returnosid.resource.ResourceSearchOrderthe resource search order
ErrorsUNIMPLEMENTED supportsVoterSearchOrder() is false
ComplianceoptionalThis method must be implemented if supportsVoterSearchOrder() is true.
MethodorderByVotingAgent
Description

Specified a preference for ordering results by the voteing agent.

Parametersosid.SearchOrderStylestylesearch order style
ErrorsNULL_ARGUMENT style is null
CompliancemandatoryThis method must be implemented.
MethodsupportsVotingAgentSearchOrder
Description

Tests if an AgentSearchOrder is available.

Returnboolean true if an agent search order is available, false otherwise
CompliancemandatoryThis method must be implemented.
MethodgetVotingAgentSearchOrder
Description

Gets the search order for an agent.

Returnosid.authentication.AgentSearchOrderthe agent search order
ErrorsUNIMPLEMENTED supportsVotingAgentSearchOrder() is false
ComplianceoptionalThis method must be implemented if supportsVotingAgentSearchOrder() is true.
MethodorderByVotes
Description

Specified a preference for ordering results by the number of votes.

Parametersosid.SearchOrderStylestylesearch order style
ErrorsNULL_ARGUMENT style is null
CompliancemandatoryThis method must be implemented.
MethodgetVoteSearchOrderRecord
Description

Gets the vote search order record corresponding to the given vote record Type. Multiple retrievals return the same underlying object.

Parametersosid.type.TypevoteRecordTypea vote record type
Returnosid.voting.records.VoteSearchOrderRecordthe vote search order record
ErrorsNULL_ARGUMENT voteRecordType is null
OPERATION_FAILEDunable to complete request
UNSUPPORTED hasRecordType(VoteRecordType) is false
CompliancemandatoryThis method must be implemented.