Package org.apache.pekko.cluster.ddata
Class Replicator.Update<A extends ReplicatedData>
java.lang.Object
org.apache.pekko.cluster.ddata.Replicator.Update<A>
- All Implemented Interfaces:
Serializable,NoSerializationVerificationNeeded,Replicator.Command<A>,scala.Equals,scala.Product
- Enclosing class:
- Replicator
public static final class Replicator.Update<A extends ReplicatedData>
extends Object
implements Replicator.Command<A>, NoSerializationVerificationNeeded, scala.Product, Serializable
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionJava API: Modify value of localReplicatorand replicate with givenwriteConsistency.Update(Key<A> key, A initial, Replicator.WriteConsistency writeConsistency, Optional<Object> request, Function<A, A> modify) Java API: Modify value of localReplicatorand replicate with givenwriteConsistency.Update(Key<A> key, Replicator.WriteConsistency writeConsistency, scala.Option<Object> request, scala.Function1<scala.Option<A>, A> modify) -
Method Summary
Modifier and TypeMethodDescriptionboolean<A extends ReplicatedData>
Replicator.Update<A>copy(Key<A> key, Replicator.WriteConsistency writeConsistency, scala.Option<Object> request, scala.Function1<scala.Option<A>, A> modify) <A extends ReplicatedData>
Key<A><A extends ReplicatedData>
Replicator.WriteConsistency<A extends ReplicatedData>
scala.Option<Object>booleaninthashCode()key()modify()intproductElement(int x$1) productElementName(int x$1) scala.collection.Iterator<Object>scala.Option<Object>request()toString()Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface scala.Product
productElementNames
-
Constructor Details
-
Update
-
Update
public Update(Key<A> key, A initial, Replicator.WriteConsistency writeConsistency, Function<A, A> modify) Java API: Modify value of localReplicatorand replicate with givenwriteConsistency.The current value for the
keyis passed to themodifyfunction. If there is no current data value for thekeytheinitialvalue will be passed to themodifyfunction. -
Update
public Update(Key<A> key, A initial, Replicator.WriteConsistency writeConsistency, Optional<Object> request, Function<A, A> modify) Java API: Modify value of localReplicatorand replicate with givenwriteConsistency.The current value for the
keyis passed to themodifyfunction. If there is no current data value for thekeytheinitialvalue will be passed to themodifyfunction.The optional
requestcontext is included in the reply messages. This is a convenient way to pass contextual information (e.g. original sender) without having to useaskor local correlation data structures.
-
-
Method Details
-
key
- Specified by:
keyin interfaceReplicator.Command<A extends ReplicatedData>
-
writeConsistency
-
request
-
modify
-
copy
public <A extends ReplicatedData> Replicator.Update<A> copy(Key<A> key, Replicator.WriteConsistency writeConsistency, scala.Option<Object> request, scala.Function1<scala.Option<A>, A> modify) -
copy$default$1
-
copy$default$2
-
copy$default$3
-
productPrefix
- Specified by:
productPrefixin interfacescala.Product
-
productArity
public int productArity()- Specified by:
productArityin interfacescala.Product
-
productElement
- Specified by:
productElementin interfacescala.Product
-
productIterator
- Specified by:
productIteratorin interfacescala.Product
-
canEqual
- Specified by:
canEqualin interfacescala.Equals
-
productElementName
- Specified by:
productElementNamein interfacescala.Product
-
hashCode
public int hashCode() -
toString
-
equals
-