Version of the nuxeo java client
Version : 0.1
Current problem
When fetching a blob via the nuxeo client :
final NuxeoClient client = new NuxeoClient(url, username, password); final Document document = client.repository().fetchDocumentById(id); final Blob blob = document.fetchBlob();
The filename set into the blob object corresponds to a temporary name like nx-3249828972020235203.tmp instead of the real filename set in the file:filename property of the document object.
Possible solutions
For consistency we could have two fields in the Blob class, one for the real filename and one for the temporary filename.
Or we could just have one field with the real filename, which is what I do :
final NuxeoClient client = new NuxeoClient(url, username, password); final Document document = client.repository().fetchDocumentById(id); final Blob blob = document.fetchBlob(); // Update the filename blob.setFileName((String) document.getProperties().get("file:filename"));