public final class VoteTrack extends Object implements HasHandlers, Hold, Track
VoteTrackV
Constructor and Description |
---|
VoteTrack()
Constructs a VoteTrack.
|
Modifier and Type | Method and Description |
---|---|
CountNodeJS |
anchor()
|
(package private) Holder<CountNodeJS> |
anchorHolder()
A constant holder for the anchor node.
|
(package private) static String |
anchorName(Stage stage)
Returns the mailish username of the person who should be anchor, or null if nobody should be.
|
CountNodeJS |
candidate()
|
(package private) Holder<CountNodeJS> |
candidateHolder()
A constant holder for the variable candidate.
|
CountJS |
count()
The tracked count, or null if it is yet unknown.
|
CountNodeJS |
downstream()
|
(package private) Holder<CountNodeJS> |
downstreamHolder()
A constant holder for the variable downstream node.
|
void |
fireEvent(GwtEvent<?> e) |
boolean |
hasTightCycle()
True if the candidate and anchor are in a tight cycle;
false if either there is no candidate, or its node is yet unknown.
|
static VoteTrack |
i(Stage stage)
Returns the staged instance of VoteTrack, or null if
none is staged.
|
(package private) Spool |
initWaitSpool()
A spool that unwinds just before this track commences initializing, which it does
on "init complete".
|
VoteTrackV |
newView(StageV _stageV)
Constructs a view of this track.
|
PeerBoard |
peers()
The board of peers, meaning either the anchor node's co-voters or the base co-candidates.
|
void |
release()
Releases this hold.
|
(package private) static boolean |
toPin(Stage stage)
Answers whether the anchor should currently be pinned to a
single node in votespace, or free to follow the staged actor.
|
Board |
voters()
The board of the anchor node's direct voters.
|
public static VoteTrack i(Stage stage)
Spool initWaitSpool()
public CountNodeJS anchor()
Holder<CountNodeJS> anchorHolder()
static String anchorName(Stage stage)
public CountNodeJS candidate()
Holder<CountNodeJS> candidateHolder()
public CountNodeJS downstream()
Holder<CountNodeJS> downstreamHolder()
public boolean hasTightCycle()
public PeerBoard peers()
Condition | Content | |
---|---|---|
(a) | no count | disabled |
(b) | no anchor | nodes are base candidates |
(c) | anchor pending but named in candidate's voters | nodes are candidate's voters |
(d) | anchor pending but name matches root candidate | nodes are base candidates |
(e) | anchor pending | disabled |
(f) | anchor is root candidate | nodes are base candidates |
(g) | no candidate | nodes are base candidates, anchor is mosquito orphan |
(h) | candidate pending | disabled |
(i) | default | nodes are candidate's voters |
The anchor (if any) is always included, either as a dart-sectored node, or as a mosquito.
static boolean toPin(Stage stage)
public Board voters()
public void fireEvent(GwtEvent<?> e)
fireEvent
in interface HasHandlers