Package com.onfido

Class FileTransfer


  • public class FileTransfer
    extends Object
    • Constructor Detail

      • FileTransfer

        public FileTransfer​(byte[] byteArray,
                            String filename)
        Create a new file transfer from a byte array
        Parameters:
        byteArray - Byte array to include in file transfer
        filename - Filename to send together with the transfer
        Throws:
        ApiException
      • FileTransfer

        public FileTransfer​(File inputFile)
        Create a new file transfer from a File
        Parameters:
        inputFile - File to include in transfer
        Throws:
        ApiException
      • FileTransfer

        public FileTransfer​(InputStream inputStream,
                            String filename)
                     throws ApiException
        Create a new file transfer from an InputStream
        Parameters:
        inputStream - InputStream to read data from
        filename - Filename to send together with the transfer
        Throws:
        ApiException
    • Method Detail

      • getByteArray

        public byte[] getByteArray()
        Return the array of bytes used for this file transfer.
        Returns:
        array of bytes
      • getInputFile

        public File getInputFile()
        Return the input stream used for this file transfer
        Returns:
        the provided input file
      • getFilename

        public String getFilename()
        Returns:
        the filename associated with this transfer
      • getContentType

        public String getContentType()
        Returns:
        the content-type associated with this transfer