class ReplicatedVote extends InternalReplicatedData
A Vote replicated data type.
This replicated data type is used to allow all the nodes in a cluster to vote on a condition.
- Source
- ReplicatedVote.scala
- Alphabetic
- By Inheritance
- ReplicatedVote
- InternalReplicatedData
- InternalReplicatedData
- ReplicatedData
- AnyRef
- Any
- by any2stringadd
- by StringFormat
- by Ensuring
- by ArrowAssoc
- Hide All
- Show All
- Public
- Protected
Type Members
- final type Self = ReplicatedVote
- Definition Classes
- ReplicatedVote → InternalReplicatedData
Value Members
- final def !=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def ##: Int
- Definition Classes
- AnyRef → Any
- def +(other: String): String
- Implicit
- This member is added by an implicit conversion from ReplicatedVote toany2stringadd[ReplicatedVote] performed by method any2stringadd in scala.Predef.
- Definition Classes
- any2stringadd
- def ->[B](y: B): (ReplicatedVote, B)
- Implicit
- This member is added by an implicit conversion from ReplicatedVote toArrowAssoc[ReplicatedVote] performed by method ArrowAssoc in scala.Predef.
- Definition Classes
- ArrowAssoc
- Annotations
- @inline()
- final def ==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def applyDelta: PartialFunction[Delta, ReplicatedVote]
- Definition Classes
- ReplicatedVote → InternalReplicatedData
- final def asInstanceOf[T0]: T0
- Definition Classes
- Any
- def clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.CloneNotSupportedException]) @native()
- val delegate: ReplicatedVoteImpl
- Definition Classes
- ReplicatedVote → InternalReplicatedData
- def ensuring(cond: (ReplicatedVote) => Boolean, msg: => Any): ReplicatedVote
- Implicit
- This member is added by an implicit conversion from ReplicatedVote toEnsuring[ReplicatedVote] performed by method Ensuring in scala.Predef.
- Definition Classes
- Ensuring
- def ensuring(cond: (ReplicatedVote) => Boolean): ReplicatedVote
- Implicit
- This member is added by an implicit conversion from ReplicatedVote toEnsuring[ReplicatedVote] performed by method Ensuring in scala.Predef.
- Definition Classes
- Ensuring
- def ensuring(cond: Boolean, msg: => Any): ReplicatedVote
- Implicit
- This member is added by an implicit conversion from ReplicatedVote toEnsuring[ReplicatedVote] performed by method Ensuring in scala.Predef.
- Definition Classes
- Ensuring
- def ensuring(cond: Boolean): ReplicatedVote
- Implicit
- This member is added by an implicit conversion from ReplicatedVote toEnsuring[ReplicatedVote] performed by method Ensuring in scala.Predef.
- Definition Classes
- Ensuring
- final def eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def equals(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef → Any
- final def getClass(): Class[_ <: AnyRef]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- def getDelta: Delta
- Definition Classes
- InternalReplicatedData → InternalReplicatedData
- def hasDelta: Boolean
- Definition Classes
- InternalReplicatedData → InternalReplicatedData
- def hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- def isAtLeastOne: Boolean
Has at least one node voted true?
Has at least one node voted true?
- returns
true
if at least one node has voted true
- final def isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- def isMajority: Boolean
Have a majority of nodes voted true?
Have a majority of nodes voted true?
- returns
true
if more than half of the nodes have voted true
- def isUnanimous: Boolean
Is the vote unanimous?
Is the vote unanimous?
- returns
true
if all nodes have voted true
- def name: String
- Definition Classes
- InternalReplicatedData → InternalReplicatedData
- final def ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- final def notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- final def notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- final def resetDelta(): ReplicatedVote
- Definition Classes
- ReplicatedVote → InternalReplicatedData
- def selfVote: Boolean
Get the current value for this node's vote.
Get the current value for this node's vote.
- returns
this node's vote
- final def synchronized[T0](arg0: => T0): T0
- Definition Classes
- AnyRef
- def toString(): String
- Definition Classes
- AnyRef → Any
- def vote(vote: Boolean): ReplicatedVote
Update this node's vote to the given value.
Update this node's vote to the given value.
- vote
the vote this node is contributing
- returns
a new vote, or this unchanged vote
- def voters: Int
Get the number of voters participating in the vote (ie, the number of nodes in the cluster).
Get the number of voters participating in the vote (ie, the number of nodes in the cluster).
- returns
the number of voters
- def votesFor: Int
Get the number of votes for.
Get the number of votes for.
- returns
the number of votes for
- final def wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException]) @native()
Deprecated Value Members
- def finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.Throwable]) @Deprecated
- Deprecated
(Since version 9)
- def formatted(fmtstr: String): String
- Implicit
- This member is added by an implicit conversion from ReplicatedVote toStringFormat[ReplicatedVote] performed by method StringFormat in scala.Predef.
- Definition Classes
- StringFormat
- Annotations
- @deprecated @inline()
- Deprecated
(Since version 2.12.16) Use
formatString.format(value)
instead ofvalue.formatted(formatString)
, or use thef""
string interpolator. In Java 15 and later,formatted
resolves to the new method in String which has reversed parameters.
- def →[B](y: B): (ReplicatedVote, B)
- Implicit
- This member is added by an implicit conversion from ReplicatedVote toArrowAssoc[ReplicatedVote] performed by method ArrowAssoc in scala.Predef.
- Definition Classes
- ArrowAssoc
- Annotations
- @deprecated
- Deprecated
(Since version 2.13.0) Use
->
instead. If you still wish to display it as one character, consider using a font with programming ligatures such as Fira Code.