| ORDictionaryTKey, TValueSetItem Method (Cluster, TKey, TValue) |
Adds an entry to the map.
Note that the new
value will be merged with existing values
on other nodes and the outcome depends on what
IReplicatedData
type that is used.
Consider using
AddOrUpdate(Cluster, TKey, TValue, FuncTValue, TValue) instead of
SetItem(Cluster, TKey, TValue) if you want modify
existing entry.
ArgumentException is thrown if you try to replace an existing
ORSetT
value, because important history can be lost when replacing the `ORSet` and
undesired effects of merging will occur. Use
ORMultiDictionaryTKey, TValue or
AddOrUpdate(Cluster, TKey, TValue, FuncTValue, TValue) instead.
Namespace:
Akka.DistributedData
Assembly:
Akka.DistributedData (in Akka.DistributedData.dll) Version: 1.2.3.129 (1.2.3.129)
Syntax public ORDictionary<TKey, TValue> SetItem(
Cluster node,
TKey key,
TValue value
)
member SetItem :
node : Cluster *
key : 'TKey *
value : 'TValue -> ORDictionary<'TKey, 'TValue>
Parameters
- node
- Type: Akka.ClusterCluster
[Missing <param name="node"/> documentation for "M:Akka.DistributedData.ORDictionary`2.SetItem(Akka.Cluster.Cluster,`0,`1)"]
- key
- Type: TKey
[Missing <param name="key"/> documentation for "M:Akka.DistributedData.ORDictionary`2.SetItem(Akka.Cluster.Cluster,`0,`1)"]
- value
- Type: TValue
[Missing <param name="value"/> documentation for "M:Akka.DistributedData.ORDictionary`2.SetItem(Akka.Cluster.Cluster,`0,`1)"]
Return Value
Type:
ORDictionaryTKey,
TValue[Missing <returns> documentation for "M:Akka.DistributedData.ORDictionary`2.SetItem(Akka.Cluster.Cluster,`0,`1)"]
See Also