OSID Logo
OSID Specifications
voting rules package
Version 3.0.0
Release Candidate Preview
Interfaceosid.voting.rules.BallotConstrainerSearchSession
Implementsosid.voting.rules.BallotConstrainerQuerySession
Description

This session provides methods for searching among BallotConstrainer objects. The search query is constructed using the BallotConstraineryQuery.

getBallotConstrainersByQuery() is the basic search method and returns a list of BallotConstrainers. A more advanced search may be performed with getBallotConstrainersBySearch(). It accepts a BallotConstrainerSearch in addition to the query for the purpose of specifying additional options affecting the entire search, such as voting. getBallotConstrainersBySearch() returns a BallotConstrainerSearchResults that can be used to access the resulting BallotConstrainerList or be used to perform a search within the result set through BallotConstrainerSearch.

This session defines views that offer differing behaviors for searching.

  • federated polls view: searches include ballot constrainer in polls of which this polls is an ancestor in the polls hierarchy
  • isolated polls view: searches are restricted to ballot constrainer in this polls

BallotConstrainers may have a query record indicated by their respective record types. The query record is accessed via the BallotConstrainerQuery.

MethodgetBallotConstrainerSearch
Description

Gets a ballot constrainer search.

Returnosid.voting.rules.BallotConstrainerSearchthe ballot constrainer search
CompliancemandatoryThis method must be implemented.
MethodgetBallotConstrainerSearchOrder
Description

Gets a ballot constrainer search order. The BallotConstrainerSearchOrder is supplied to a BallotConstrainerSearch to specify the ordering of results.

Returnosid.voting.rules.BallotConstrainerSearchOrderthe ballot constrainer search order
CompliancemandatoryThis method must be implemented.
MethodgetBallotConstrainersBySearch
Description

Gets the search results matching the given search query using the given search.

Parametersosid.voting.rules.BallotConstrainerQueryballotConstrainerQuerythe ballot constrainer query
osid.voting.rules.BallotConstrainerSearchballotConstrainerSearchthe ballot constrainer search
Returnosid.voting.rules.BallotConstrainerSearchResultsthe returned search results
ErrorsNULL_ARGUMENT ballotConstrainerQuery or ballotConstrainerSearch is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
UNSUPPORTED ballotConstrainerQuery or ballotConstrainerSearch is not of this service
CompliancemandatoryThis method must be implemented.
MethodgetBallotConstrainerQueryFromInspector
Description

Gets a ballot constrainer query from an inspector. The inspector is available from a BallotConstrainerSearchResults.

Parametersosid.voting.rules.BallotConstrainerQueryInspectorballotConstrainerQueryInspectora ballot constrainer query inspector
Returnosid.voting.rules.BallotConstrainerQuerythe ballot constrainer query
ErrorsNULL_ARGUMENT ballotConstrainerQueryInspector is null
UNSUPPORTED ballotConstrainerQueryInspector is not of this service
CompliancemandatoryThis method must be implemented.