public OperationBuilder addFileAsAttachment(final File file) {
        Assert.checkNotNullParam("file", file);
        try {
            FileStreamEntry entry = new FileStreamEntry(file);
            if (inputStreams == null) {
                inputStreams = new ArrayList<InputStream>();
            }
            inputStreams.add(entry);
        } catch (IOException e) {
            throw new RuntimeException(e);
        }
        return this;
    }
public OperationBuilder addFileAsAttachment ( final File file ) { Assert . checkNotNullParam ( "file" , file ) ; try { FileStreamEntry entry = new FileStreamEntry ( file ) ; if ( inputStreams == null ) { inputStreams = new ArrayList < InputStream > ( ) ; } inputStreams . add ( entry ) ; } catch ( IOException e ) { throw new RuntimeException ( e ) ; } return this ; }
Associate a file with the operation. This will create a {@code FileInputStream}
and add it as attachment.

@param file the file
@return the operation builder