org.gswing.components.common
Class Vote

java.lang.Object
  extended by org.gswing.components.common.Vote
Direct Known Subclasses:
FptpVote, ListVote

public abstract class Vote
extends Object

Purpose: Abstract class provides what the attributes that each vote should consist of.


Constructor Summary
Vote(int constituency, int electionNo, int votes)
          Constructor.
 
Method Summary
 int getConstituency()
          Get the contituency identifier of this vote.
 int getElectionNo()
          Get the election number of this vote.
 int getVotes()
          Get the number of votes for this vote.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Vote

public Vote(int constituency,
            int electionNo,
            int votes)
Constructor.

Parameters:
constituency - The constituency name.
electionNo - The unique election number.
votes - The number of votes for a particular candidate / party.
Method Detail

getConstituency

public int getConstituency()
Get the contituency identifier of this vote.

Returns:
The constituency name.

getElectionNo

public int getElectionNo()
Get the election number of this vote.

Returns:
The unique election number.

getVotes

public int getVotes()
Get the number of votes for this vote.

Returns:
The number of votes for a particular candidate.


Copyright © 2008. All Rights Reserved.