Package ucar.nc2.iosp

Interface Layout.Chunk

  • All Known Subinterfaces:
    LayoutBB.Chunk
    All Known Implementing Classes:
    IndexChunker.Chunk
    Enclosing interface:
    Layout

    public static interface Layout.Chunk
    A chunk of data that is contiguous in both the source and destination. Read nelems from src at filePos, store in destination at startElem. (or) Write nelems to file at filePos, from array at startElem.
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      long getDestElem()
      Get starting element position as a 1D element index into the destination, eg the requested array with shape "wantSection".
      int getNelems()
      Get number of elements to transfer contiguously (Note: elements, not bytes)
      long getSrcPos()
      Get the position in source where to read or write: "file position"
    • Method Detail

      • getSrcPos

        long getSrcPos()
        Get the position in source where to read or write: "file position"
        Returns:
        position as a byte count into the source, eg a file
      • getNelems

        int getNelems()
        Get number of elements to transfer contiguously (Note: elements, not bytes)
        Returns:
        number of elements to transfer
      • getDestElem

        long getDestElem()
        Get starting element position as a 1D element index into the destination, eg the requested array with shape "wantSection".
        Returns:
        starting element in the array (Note: elements, not bytes)