|
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.ObjectCountNode.Table
@ThreadSafe public static class CountNode.Table
The relational store of count nodes that (in part) backs a election count.
| Nested Class Summary | |
|---|---|
(package private) static class |
CountNode.Table.RankedCumulate
|
| Constructor Summary | |
|---|---|
CountNode.Table(ReadyDirectory readyDirectory,
Database database)
Constructs a Table. |
|
| Method Summary | |
|---|---|
(package private) void |
create()
Creates this table in the database. |
(package private) Database |
database()
Returns the database in which this table is stored. |
(package private) void |
drop()
Drops this table from the database. |
(package private) boolean |
exists()
Returns true if this table exists in the database; false otherwise. |
(package private) CountNode |
get(String voterEmail)
Retrieves a node from this table. |
(package private) List<CountNode> |
getByRankIndeces(int first,
int lastBound)
Retrieves a list of nodes by rank indeces. |
List<CountNode> |
getCastersByCandidate(String candidateEmail,
long minimumCarryCount)
Retrieves a list of nodes that are successfully casting for a particular candidate. |
CountNode |
getOrCreate(String voterEmail)
Retrieves a node from this table; or, if none is stored, a default node. |
void |
put(CountNode node)
Stores a node. |
(package private) CountNode.Table.RankedCumulate |
rank()
Sorts all rows by the columns that determine rank; stores the resulting rank and rank-index for each row; and returns the cumulative count of votes cast, and so forth. |
(package private) ReadyDirectory |
readyDirectory()
The file-based counterpart to this table. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
CountNode.Table(ReadyDirectory readyDirectory,
Database database)
throws IOException
readyDirectory - per readyDirectory()database - per database()
IOException| Method Detail |
|---|
final void create()
throws SQLException
SQLExceptionfinal Database database()
final void drop()
throws SQLException
SQLException
final boolean exists()
throws SQLException
SQLException
CountNode get(String voterEmail)
throws SQLException
SQLException
List<CountNode> getByRankIndeces(int first,
int lastBound)
throws SQLException
SQLException
public List<CountNode> getCastersByCandidate(String candidateEmail,
long minimumCarryCount)
throws SQLException
minimumCarryCount - the minimum carry count that a node must have,
for inclusion in the list; all others are excluded
SQLException
public CountNode getOrCreate(String voterEmail)
throws SQLException
SQLException
public final void put(CountNode node)
throws SQLException
SQLException
CountNode.Table.RankedCumulate rank()
throws SQLException
SQLExceptionfinal ReadyDirectory readyDirectory()
|
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||