Hi all,
I'm just starting with web services and CXF and I'd like to know if it's
possible to deal with the request body with CXF.
I just created a client like that:
File customer = new File("pathToXMLFile");
File body = new File("AZipFile");
PutMethod put = new PutMethod("http://localhost:8080/test/new");
put.addRequestHeader("Accept", "text/xml");
FileRequestEntity entity = new FileRequestEntity(customer, "text/xml;
charset=ISO-8859-1");
put.setRequestEntity(entity);
put.setRequestBody(body);
HttpClient httpclient = new HttpClient();
httpclient.executeMethod(put);
Here's my server:
@Path("test")
public class TestServlet {
@PUT
@Path("/new")
public String testPut(Customer customer) {
.....
}
}
My question is how do I get the requestBody in my server (i.e. zipFile)??
I can deal with the customer parameter which is a xml file (from
requestentity) but
not with requestBody?
Has anyone ever done it?
Thanks for your support.
Ramku
--
View this message in context:
http://www.nabble.com/CXF-and-http-body-tp18736318p18736318.html
Sent from the cxf-user mailing list archive at Nabble.com.