Class HadoopBlockLocation

java.lang.Object
org.apache.flink.runtime.fs.hdfs.HadoopBlockLocation
All Implemented Interfaces:
Comparable<org.apache.flink.core.fs.BlockLocation>, org.apache.flink.core.fs.BlockLocation

public final class HadoopBlockLocation extends Object implements org.apache.flink.core.fs.BlockLocation
Implementation of the BlockLocation interface for the Hadoop Distributed File System.
  • Constructor Details

    • HadoopBlockLocation

      public HadoopBlockLocation(org.apache.hadoop.fs.BlockLocation blockLocation)
      Creates a new block location.
      Parameters:
      blockLocation - the original HDFS block location
  • Method Details

    • getHosts

      public String[] getHosts() throws IOException
      Specified by:
      getHosts in interface org.apache.flink.core.fs.BlockLocation
      Throws:
      IOException
    • getLength

      public long getLength()
      Specified by:
      getLength in interface org.apache.flink.core.fs.BlockLocation
    • getOffset

      public long getOffset()
      Specified by:
      getOffset in interface org.apache.flink.core.fs.BlockLocation
    • compareTo

      public int compareTo(org.apache.flink.core.fs.BlockLocation o)
      Specified by:
      compareTo in interface Comparable<org.apache.flink.core.fs.BlockLocation>