public static boolean hasWonVoteOnFullCount ( final ClusterMember [ ] members , final long candidateTermId ) { int votes = 0 ; for ( final ClusterMember member : members ) { if ( null == member . vote || member . candidateTermId != candidateTermId ) { return false ; } votes += member . vote ? 1 : 0 ; } return votes >= ClusterMember . quorumThreshold ( members . length ) ; }
Has the candidate got unanimous support of the cluster?