Class AbstractOrigin.PathOrigin

    • Constructor Detail

      • PathOrigin

        public PathOrigin​(java.nio.file.Path origin)
        Constructs a new instance for the given origin.
        Parameters:
        origin - The origin.
    • Method Detail

      • getByteArray

        public byte[] getByteArray​(long position,
                                   int length)
                            throws java.io.IOException
        Description copied from class: AbstractOrigin
        Gets this origin as a byte array, if possible.
        Overrides:
        getByteArray in class AbstractOrigin<java.nio.file.Path,​AbstractOrigin.PathOrigin>
        Parameters:
        position - the initial index of the range to be copied, inclusive.
        length - How many bytes to copy.
        Returns:
        this origin as a byte array, if possible.
        Throws:
        java.io.IOException - if an I/O error occurs.