public static class TwoPhaseVotingAdapter.TwoPhaseVoteWrapper extends Object implements VotingListener
Constructor and Description |
---|
TwoPhaseVoteWrapper(TwoPhaseVotingListener listener) |
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object other) |
int |
hashCode() |
boolean |
vote(Object decree)
Each member is able to vote with
true or false
messages. |
public TwoPhaseVoteWrapper(TwoPhaseVotingListener listener)
public boolean vote(Object decree) throws VoteException
VotingListener
true
or false
messages. If the member does not know what to do with the
decree
it should throw VoteException
. Doing
this he will be excluded from voting process and will not influence
the result.vote
in interface VotingListener
decree
- object representing the decree of current voting.VoteException
- if listener does not know the meaning of the
decree and wants to be excluded from this voting.Copyright © 2019 JBoss, a division of Red Hat. All rights reserved.