Class FileInputRegionInformation

java.lang.Object
com.pnfsoftware.jeb.core.input.FileInputRegionInformation
All Implemented Interfaces:
IInputLocation

public class FileInputRegionInformation extends Object implements IInputLocation
Location information within binary input, consisting of an offset and an optional size, plus optional source metadata.
  • Constructor Details

    • FileInputRegionInformation

      public FileInputRegionInformation(long offset)
      Create a new location object with an unknown size.
      Parameters:
      offset - mandatory offset
    • FileInputRegionInformation

      public FileInputRegionInformation(long offset, long size)
      Create a new location object.
      Parameters:
      offset - the non-negative offset
      size - optional size, zero to indicate an unknown size
    • FileInputRegionInformation

      public FileInputRegionInformation(long offset, long size, IInput input)
      Create a new location object.
      Parameters:
      offset - the non-negative offset
      size - optional size, zero to indicate an unknown size
      input - optional input, if the input object is not known (or unclear) by the client
    • FileInputRegionInformation

      public FileInputRegionInformation(long offset, long size, IInput input, String info)
      Create a new location object.
      Parameters:
      offset - the non-negative offset
      size - optional size, zero to indicate an unknown size
      input - optional input, if the input object is not known (or unclear) by the client
      info - optional information string
  • Method Details

    • getOffset

      public long getOffset()
      Get the location offset in bytes, relative to the beginning of the input.
      Returns:
      the non-negative offset
    • getSize

      public long getSize()
      Get the location size in bytes.
      Returns:
      the optional size; 0 generally indicates an unspecified size, and negative values are preserved as provided by the creator
    • getInput

      public IInput getInput()
      Get the input object.
      Returns:
      the optional input object, may be null if unspecified
    • getInfo

      public String getInfo()
      Get the optional descriptive string associated with this location.
      Returns:
      the descriptive string, or null if none was provided
    • toString

      public String toString()
      Overrides:
      toString in class Object