Hi Please find that below code and tell me where i am wrong
..
I am trying to download any specified file from nuxeo server
to our local machine ,here file is pm.JPG (this is id :
92d0e6b8351c8311cf3c81969d6fd482)
// List all the documents.
package com.rest.client;
import org.nuxeo.ecm.automation.client.jaxrs.Session;
import
org.nuxeo.ecm.automation.client.jaxrs.impl.HttpAutomationCli
ent;
import
org.nuxeo.ecm.automation.client.jaxrs.model.Document;
import
org.nuxeo.ecm.automation.client.jaxrs.model.Documents;
public class DownloadFiles {
public static void main(String[] args) {
HttpAutomationClient client = new
HttpAutomationClient("http://localhost:8080/nuxeo/site/automation");
Session session = client.getSession("Administrator",
"Administrator");
Documents docs;
try {
Document root = (Document)
session.newRequest("Document.CheckOut").set("value",
"/92d0e6b8351c8311cf3c81969d6fd482").execute();
//Document root = (Document)
session.newRequest("Document.CheckOut").setInput(rootPath).execute();
System.out.println("Pankaj");
} catch (Exception e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
client.shutdown();
}
}
---
Mailing list: [email protected]
Forum: http://forum.nuxeo.org/f/1/