org.apache.hadoop.hbase.stargate.model
Class TableRegionModel
java.lang.Object
org.apache.hadoop.hbase.stargate.model.TableRegionModel
- All Implemented Interfaces:
- Serializable
public class TableRegionModel
- extends Object
- implements Serializable
Representation of a region of a table and its current location on the
storage cluster.
<complexType name="TableRegion">
<attribute name="name" type="string"></attribute>
<attribute name="id" type="int"></attribute>
<attribute name="startKey" type="base64Binary"></attribute>
<attribute name="endKey" type="base64Binary"></attribute>
<attribute name="location" type="string"></attribute>
</complexType>
- See Also:
- Serialized Form
TableRegionModel
public TableRegionModel()
- Constructor
TableRegionModel
public TableRegionModel(String table,
long id,
byte[] startKey,
byte[] endKey,
String location)
- Constructor
- Parameters:
table
- the table nameid
- the encoded id of the regionstartKey
- the start key of the regionendKey
- the end key of the regionlocation
- the name and port of the region server hosting the region
getName
public String getName()
- Returns:
- the region name
getId
public long getId()
- Returns:
- the encoded region id
getStartKey
public byte[] getStartKey()
- Returns:
- the start key
getEndKey
public byte[] getEndKey()
- Returns:
- the end key
getLocation
public String getLocation()
- Returns:
- the name and port of the region server hosting the region
setName
public void setName(String name)
- Parameters:
name
- region printable name
setId
public void setId(long id)
- Parameters:
id
- the region's encoded id
setStartKey
public void setStartKey(byte[] startKey)
- Parameters:
startKey
- the start key
setEndKey
public void setEndKey(byte[] endKey)
- Parameters:
endKey
- the end key
setLocation
public void setLocation(String location)
- Parameters:
location
- the name and port of the region server hosting the region
toString
public String toString()
- Overrides:
toString
in class Object
Copyright © 2009 The Apache Software Foundation