
Originally Posted by
Jkelly
Question # 1:
I am now implementing a simple web service in which the endpoint extends AbstractMarshallingPayloadEndpoint and uses Castor to marshall a list of Java object to XML. I would like the web service clients to be able to get the XML file result, without having to wrap anything in a SOAP envelop. When implementing the method Object invokeInternal(Object requestObject), what type of object should I return in order to accomplish my goal? For instance, If my object is of type Car (see below). What type of OutputStream will be best? Or should I use another method?
Object invokeInternal(Object requestObject){
List cars = ....;
...
CastorMarshaller marshaller = ...
OutputStream outputstream = new (What type ???);
marshaller.marshalOutputStream(list, outputstream);
return outputstream;
}