Interface BallotForm

All Superinterfaces:
Extensible, Identifiable, OsidBrowsableForm, OsidExtensibleForm, OsidForm, OsidGovernatorForm, OsidIdentifiableForm, OsidObjectForm, OsidOperableForm, OsidSourceableForm, OsidTemporalForm, Suppliable
All Known Subinterfaces:
BallotBatchForm

public interface BallotForm extends OsidGovernatorForm, OsidTemporalForm

This is the form for creating and updating Ballots . Like all OsidForm objects, various data elements may be set here for use in the create and update methods in the BallotAdminSession . For each data element that may be set, metadata may be examined to provide display hints or data constraints.

  • Method Details

    • getCommissionersMetadata

      Metadata getCommissionersMetadata()
      Gets the metadata for the commissioners.
      Returns:
      metadata for the commissioners
      Compliance:
      mandatory - This method must be implemented.
    • setCommissioners

      void setCommissioners(IdList commissionerIds)
      Sets the commissioners.
      Parameters:
      commissionerIds - the new commissioners
      Throws:
      InvalidArgumentException - commissionerIds is invalid
      NoAccessException - Metadata.isReadOnly() is true
      NullArgumentException - commissionerIds is null
      Compliance:
      mandatory - This method must be implemented.
    • clearCommissioners

      void clearCommissioners()
      Removes the commissioners.
      Throws:
      NoAccessException - Metadata.isRequired() is true or Metadata.isReadOnly() is true
      Compliance:
      mandatory - This method must be implemented.
    • getRevoteMetadata

      Metadata getRevoteMetadata()
      Gets the metadata for the revote flag.
      Returns:
      metadata for the revote flag
      Compliance:
      mandatory - This method must be implemented.
    • setRevote

      void setRevote(boolean revote)
      Sets the revote flag.
      Parameters:
      revote - the revote flag
      Throws:
      InvalidArgumentException - revote is invalid
      NoAccessException - Metadata.isReadOnly() is true
      Compliance:
      mandatory - This method must be implemented.
    • clearRevote

      void clearRevote()
      Clears the revote flag.
      Compliance:
      mandatory - This method must be implemented.
    • getBallotFormRecord

      BallotFormRecord getBallotFormRecord(Type candidateRecordType) throws OperationFailedException
      Gets the BallotFormRecord corresponding to the given Ballot record Type .
      Parameters:
      candidateRecordType - the ballot record type
      Returns:
      the ballot form record
      Throws:
      NullArgumentException - ballotRecordType is null
      OperationFailedException - unable to complete request
      UnsupportedException - hasRecordType(ballotRecordType) is false
      Compliance:
      mandatory - This method must be implemented.