|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.hadoop.fs.BlockLocation
public class BlockLocation
Constructor Summary | |
---|---|
BlockLocation()
Default Constructor |
|
BlockLocation(java.lang.String[] names,
java.lang.String[] hosts,
long offset,
long length)
Constructor with host, name, offset and length |
|
BlockLocation(java.lang.String[] names,
java.lang.String[] hosts,
java.lang.String[] topologyPaths,
long offset,
long length)
Constructor with host, name, network topology, offset and length |
Method Summary | |
---|---|
java.lang.String[] |
getHosts()
Get the list of hosts (hostname) hosting this block |
long |
getLength()
Get the length of the block |
java.lang.String[] |
getNames()
Get the list of names (hostname:port) hosting this block |
long |
getOffset()
Get the start offset of file associated with this block |
java.lang.String[] |
getTopologyPaths()
Get the list of network topology paths for each of the hosts. |
void |
readFields(java.io.DataInput in)
Implement readFields of Writable |
void |
setHosts(java.lang.String[] hosts)
Set the hosts hosting this block |
void |
setLength(long length)
Set the length of block |
void |
setNames(java.lang.String[] names)
Set the names (host:port) hosting this block |
void |
setOffset(long offset)
Set the start offset of file associated with this block |
void |
setTopologyPaths(java.lang.String[] topologyPaths)
Set the network topology paths of the hosts |
java.lang.String |
toString()
|
void |
write(java.io.DataOutput out)
Implement write of Writable |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public BlockLocation()
public BlockLocation(java.lang.String[] names, java.lang.String[] hosts, long offset, long length)
public BlockLocation(java.lang.String[] names, java.lang.String[] hosts, java.lang.String[] topologyPaths, long offset, long length)
Method Detail |
---|
public java.lang.String[] getHosts() throws java.io.IOException
java.io.IOException
public java.lang.String[] getNames() throws java.io.IOException
java.io.IOException
public java.lang.String[] getTopologyPaths() throws java.io.IOException
java.io.IOException
public long getOffset()
public long getLength()
public void setOffset(long offset)
public void setLength(long length)
public void setHosts(java.lang.String[] hosts) throws java.io.IOException
java.io.IOException
public void setNames(java.lang.String[] names) throws java.io.IOException
java.io.IOException
public void setTopologyPaths(java.lang.String[] topologyPaths) throws java.io.IOException
java.io.IOException
public void write(java.io.DataOutput out) throws java.io.IOException
write
in interface Writable
out
- DataOuput
to serialize this object into.
java.io.IOException
public void readFields(java.io.DataInput in) throws java.io.IOException
readFields
in interface Writable
in
- DataInput
to deseriablize this object from.
java.io.IOException
public java.lang.String toString()
toString
in class java.lang.Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |