Class FileTransfer

    • Constructor Detail

      • FileTransfer

        public FileTransfer​(File f,
                            long pos,
                            long len)
        Constructs a new FileTransfer instance backed by the specified File. The content to transfer will begin at the specified offset, pos with the total transfer length being specified by len.
        Parameters:
        f - the File to transfer.
        pos - the offset within the File to start the transfer.
        len - the total number of bytes to transfer.
        Throws:
        IllegalArgumentException - if f is null, does not exist, is not readable, or is a directory.
        IllegalArgumentException - if pos or len are negative.
        IllegalArgumentException - if len exceeds the number of bytes that may be transferred based on the provided offset and file length.