OSID Logo
OSID Specifications
voting package
Version 3.0.0
Release Candidate Preview
Interfaceosid.voting.BallotSmartPollsSession
Implementsosid.OsidSession
Description

This session manages queries and sequencing to create "smart" dynamic catalogs. A BallotQuery can be retrieved from this session and mapped to this Polls to create a virtual collection of Ballots. The ballots may be sequenced using the BallotSearchOrder from this session.

This Polls has a default query that matches any ballot and a default search order that specifies no sequencing. The queries may be examined using a BallotQueryInspector. The query may be modified by converting the inspector back to a BallotQuery.

MethodgetPollsId
Description

Gets the Polls Id associated with this session.

Returnosid.id.Idthe Polls Id associated with this session
CompliancemandatoryThis method must be implemented.
MethodgetPolls
Description

Gets the Polls associated with this session.

Returnosid.voting.Pollsthe Polls associated with this session
ErrorsOPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodcanManageSmartPolls
Description

Tests if this user can manage smart polls. A return of true does not guarantee successful authorization. A return of false indicates that it is known 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 operations to unauthorized users.

Returnboolean false if smart polls management is not authorized, true otherwise
CompliancemandatoryThis method must be implemented.
MethodgetBallotQuery
Description

Gets a ballot query.

Returnosid.voting.BallotQuerythe ballot query
CompliancemandatoryThis method must be implemented.
MethodgetBallotSearchOrder
Description

Gets a ballot search order.

Returnosid.voting.BallotSearchOrderthe ballot search order
CompliancemandatoryThis method must be implemented.
MethodapplyBallotQuery
Description

Applies a ballot query to this polls.

Parametersosid.voting.BallotQueryballotQuerythe ballot query
ErrorsNULL_ARGUMENT ballotQuery is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure occurred
UNSUPPORTED ballotQuery not of this service
CompliancemandatoryThis method must be implemented.
MethodinspectBallotQuery
Description

Gets a ballot query inspector for this polls.

Returnosid.voting.BallotQueryInspectorthe ballot query inspector
ErrorsOPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure occurred
CompliancemandatoryThis method must be implemented.
MethodapplyBallotSequencing
Description

Applies a ballot search order to this polls.

Parametersosid.voting.BallotSearchOrderballotSearchOrderthe ballot search order
ErrorsNULL_ARGUMENT ballotSearchOrder is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure occurred
UNSUPPORTED ballotSearchOrder not of this service
CompliancemandatoryThis method must be implemented.
MethodgetBallotQueryFromInspector
Description

Gets a ballot query from an inspector.

Parametersosid.voting.BallotQueryInspectorballotQueryInspectora ballot query inspector
Returnosid.voting.BallotQuerythe ballot query
ErrorsNULL_ARGUMENT ballotQueryInspector is null
UNSUPPORTED ballotQueryInspector is not of this service
CompliancemandatoryThis method must be implemented.