protected void uploadTusFiles() throws IOException, ProtocolException {
        while (uploads.size() > 0) {
            final TusUploader tusUploader = tusClient.resumeOrCreateUpload(uploads.get(0));

            TusExecutor tusExecutor = new TusExecutor() {
                @Override
                protected void makeAttempt() throws ProtocolException, IOException {
                    int uploadedChunk = 0;
                    while (uploadedChunk > -1) {
                        uploadedChunk = tusUploader.uploadChunk();
                    }
                    tusUploader.finish();
                }
            };

            tusExecutor.makeAttempts();
            // remove upload instance from list
            uploads.remove(0);
        }
    }
protected void uploadTusFiles ( ) throws IOException , ProtocolException { while ( uploads . size ( ) > 0 ) { final TusUploader tusUploader = tusClient . resumeOrCreateUpload ( uploads . get ( 0 ) ) ; TusExecutor tusExecutor = new TusExecutor ( ) { @ Override protected void makeAttempt ( ) throws ProtocolException , IOException { int uploadedChunk = 0 ; while ( uploadedChunk > - 1 ) { uploadedChunk = tusUploader . uploadChunk ( ) ; } tusUploader . finish ( ) ; } } ; tusExecutor . makeAttempts ( ) ; uploads . remove ( 0 ) ; } }
Does the actual uploading of files (when tus is enabled).

@throws IOException when there's a failure with file retrieval.
@throws ProtocolException when there's a failure with tus upload.