This will work for me. Basically I need to receive XML as a parameter, for
example as a String in onActivate() method. So, I think this will do job for
me:

 public TextStreamResponse onActivate(String xml) {

    //doing something with xml

    return new TextStreamResponse("text/xml", xml);

}

Thank you!

Niksa


Richard Hill-7 wrote:
> 
> 
> You don't specify where/how you want to receive XML requests from - is
> this server-to-server? If so this out of the realm of Tapestry, but
> there's plenty of java networking libs to help you do this.
> 
> With respect to sending an xml document/page to a browser client,
> tapestry is not really designed for this. Although you could use
> TextStreamResponse for this:
> 
> http://tapestry.apache.org/tapestry5/apidocs/org/apache/tapestry5/util/TextStreamResponse.html
> 
> 
> public TextStreamResponse onActivate() {
> 
>     String xml = getMyXMLFromSomeWhere....
> 
>     return new TextStreamResponse("text/xml", xml);
> 
> }
> 
> 
> R.
> 
> 
> 
> -----Original Message-----
> From: niksami <ni...@fleka.me>
> Reply-to: "Tapestry users" <users@tapestry.apache.org>
> To: users@tapestry.apache.org
> Subject: XML requests
> Date: Mon, 15 Nov 2010 06:18:03 -0800 (PST)
> 
> Hello everyone.
> 
> In my application I need to receive XML requests, and then to send the
> response back to the client in XML format too. I tried to find some nice
> solution here, but with no success. I hope you can give me some short code
> examples.
> 
> Best regards,
> Niksa
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
> For additional commands, e-mail: users-h...@tapestry.apache.org
> 
> 
> 

-- 
View this message in context: 
http://tapestry.1045711.n5.nabble.com/XML-requests-tp3265672p3265893.html
Sent from the Tapestry - User mailing list archive at Nabble.com.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org

Reply via email to