public class Row extends Object implements MapWriter
MapWriter.EntryWriter
Modifier and Type | Field and Description |
---|---|
Map<String,Map<String,List<ReplicaInfo>>> |
collectionVsShardVsReplicas |
String |
node |
Constructor and Description |
---|
Row(String node,
Cell[] cells,
boolean anyValueMissing,
Map<String,Map<String,List<ReplicaInfo>>> collectionVsShardVsReplicas,
boolean isLive,
Policy.Session session) |
Row(String node,
List<Pair<String,Variable.Type>> params,
List<String> perReplicaAttributes,
Policy.Session session) |
Modifier and Type | Method and Description |
---|---|
Row |
addReplica(String coll,
String shard,
Replica.Type type) |
Row |
addReplica(String coll,
String shard,
Replica.Type type,
boolean strictMode) |
void |
forEachReplica(Consumer<ReplicaInfo> consumer) |
static void |
forEachReplica(Map<String,Map<String,List<ReplicaInfo>>> collectionVsShardVsReplicas,
Consumer<ReplicaInfo> consumer) |
void |
forEachReplica(String coll,
Consumer<ReplicaInfo> consumer) |
void |
forEachShard(String collection,
BiConsumer<String,List<ReplicaInfo>> consumer) |
Cell[] |
getCells() |
ReplicaInfo |
getReplica(String coll,
String shard,
Replica.Type type) |
Object |
getVal(String name,
Object def) |
Row |
removeReplica(String coll,
String shard,
Replica.Type type) |
Row |
removeReplica(String coll,
String shard,
Replica.Type type,
int recursionCount) |
String |
toString() |
void |
writeMap(MapWriter.EntryWriter ew) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
_forEachEntry, _forEachEntry, _forEachEntry, _get, _get, _getStr, _getStr
public final String node
public Row(String node, List<Pair<String,Variable.Type>> params, List<String> perReplicaAttributes, Policy.Session session)
public Row(String node, Cell[] cells, boolean anyValueMissing, Map<String,Map<String,List<ReplicaInfo>>> collectionVsShardVsReplicas, boolean isLive, Policy.Session session)
public void forEachShard(String collection, BiConsumer<String,List<ReplicaInfo>> consumer)
public void writeMap(MapWriter.EntryWriter ew) throws IOException
writeMap
in interface MapWriter
IOException
public Row addReplica(String coll, String shard, Replica.Type type)
public Row addReplica(String coll, String shard, Replica.Type type, boolean strictMode)
public ReplicaInfo getReplica(String coll, String shard, Replica.Type type)
public Row removeReplica(String coll, String shard, Replica.Type type)
public Row removeReplica(String coll, String shard, Replica.Type type, int recursionCount)
public Cell[] getCells()
public void forEachReplica(Consumer<ReplicaInfo> consumer)
public void forEachReplica(String coll, Consumer<ReplicaInfo> consumer)
public static void forEachReplica(Map<String,Map<String,List<ReplicaInfo>>> collectionVsShardVsReplicas, Consumer<ReplicaInfo> consumer)
Copyright © 2000-2018 Apache Software Foundation. All Rights Reserved.