com.continuent.tungsten.replicator.shard
Class Shard

java.lang.Object
  extended by com.continuent.tungsten.replicator.shard.Shard

public class Shard
extends java.lang.Object

Holds information about a single shard, whose name is given by the shardId property.

Version:
1.0
Author:
Stephane Giron

Field Summary
 java.lang.String LOCAL
          Master name that denotes a short that is local to current service only.
 
Constructor Summary
Shard(java.util.Map<java.lang.String,java.lang.String> shard)
           
Shard(java.lang.String shardId, boolean critical, java.lang.String master)
           
 
Method Summary
 java.lang.String getMaster()
          Returns name of master service.
 java.lang.String getShardId()
          Returns the shard name.
 boolean isCritical()
          Returns true if shard is critical.
 boolean isLocal()
          Returns true if shard is local-only, i.e., does not cross services.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

LOCAL

public java.lang.String LOCAL
Master name that denotes a short that is local to current service only.

Constructor Detail

Shard

public Shard(java.lang.String shardId,
             boolean critical,
             java.lang.String master)

Shard

public Shard(java.util.Map<java.lang.String,java.lang.String> shard)
Method Detail

getShardId

public java.lang.String getShardId()
Returns the shard name.


isCritical

public boolean isCritical()
Returns true if shard is critical.


getMaster

public java.lang.String getMaster()
Returns name of master service.


isLocal

public boolean isLocal()
Returns true if shard is local-only, i.e., does not cross services.