Package org.apache.flink.core.fs
Interface BlockLocation
-
- All Superinterfaces:
Comparable<BlockLocation>
- All Known Implementing Classes:
HadoopBlockLocation
,LocalBlockLocation
@Public public interface BlockLocation extends Comparable<BlockLocation>
A BlockLocation lists hosts, offset and length of block.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description String[]
getHosts()
Get the list of hosts (hostname) hosting this block.long
getLength()
Get the length of the block.long
getOffset()
Get the start offset of the file associated with this block.-
Methods inherited from interface java.lang.Comparable
compareTo
-
-
-
-
Method Detail
-
getHosts
String[] getHosts() throws IOException
Get the list of hosts (hostname) hosting this block.- Returns:
- A list of hosts (hostname) hosting this block.
- Throws:
IOException
- thrown if the list of hosts could not be retrieved
-
getOffset
long getOffset()
Get the start offset of the file associated with this block.- Returns:
- The start offset of the file associated with this block.
-
getLength
long getLength()
Get the length of the block.- Returns:
- the length of the block
-
-