You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
majority-judgment-library-java/src/main/java/fr/mieuxvoter/mj/ProposalTallyInterface.java

34 lines
790 B

package fr.mieuxvoter.mj;
import java.math.BigInteger;
public interface ProposalTallyInterface {
/**
* The tallies of each Grade, that is
* the amount of judgments received for each Grade by the Proposal,
* from "worst" ("most conservative") Grade to "best" Grade.
*/
public BigInteger[] getTally();
/**
* Should be the sum of getTally()
*
* @return The total amount of judgments received by this proposal.
*/
public BigInteger getAmountOfJudgments();
/**
* Homemade factory to skip the clone() shenanigans.
* Used by the score calculus.
*/
public ProposalTallyInterface duplicate();
/**
* Move judgments that were fromGrade into intoGrade.
* Used by the score calculus.
*/
public void moveJudgments(Integer fromGrade, Integer intoGrade);
}