RE: Axis stub response to JSP.
Thanks for this info.. My stub do not publish the objects like getEmployees() since I am using Axis Messaging Elements. I am not sure if I need to use stub.getPullParser(QName) and read the XML output. From: Raghu Upadhyayula [mailto:[EMAIL PROTECTED] Sent: Thursday, October 25, 2007 5:09 PM To: axis-user@ws.apache.org Subject: RE: Axis stub response to JSP. I guess, you can directly invoke your webservice from JSP using the stub (I haven't tried it though). For Ex: % String endPointURL = http://localhost/webservices/services/MyService; MyServiceStub stub = new MyServiceStub(endPointURL); Employee[] employees = stub.getEmployees(); // getEmployees is a method in your service // Use this employees array to display the data in the jsp. % From: Martin Gainty [mailto:[EMAIL PROTECTED] Sent: Thursday, October 26, 2000 1:33 PM To: axis-user@ws.apache.org Subject: Re: Axis stub response to JSP. JSP - Servlet(packages WSDLToJava StubClient) including encoding SOAP Request into XML- AxisServlet AxisServlet- XML response back to Servlet - Servlet parses the XML /populates beans/sends textResponse back -JSP (AJAX Div Tag or create ResultsJsp) Im sure there is a simpler solution..Anyone else? M-- - Original Message - From: Ajay Joshi mailto:[EMAIL PROTECTED] To: axis-user@ws.apache.org Sent: Thursday, October 25, 2007 3:32 PM Subject: Axis stub response to JSP. Hi, How Axis stub (generated thru WSDL2Java) can return response to JSP? I can see response in XML format.. response can be print to browser using servlet in text/html format. . But I am not sure how to convert response to Java object than be displayed to JSP. Regards Ajay
Re: Axis stub response to JSP.
JSP - Servlet(packages WSDLToJava StubClient) including encoding SOAP Request into XML- AxisServlet AxisServlet- XML response back to Servlet - Servlet parses the XML /populates beans/sends textResponse back -JSP (AJAX Div Tag or create ResultsJsp) Im sure there is a simpler solution..Anyone else? M-- - Original Message - From: Ajay Joshi To: axis-user@ws.apache.org Sent: Thursday, October 25, 2007 3:32 PM Subject: Axis stub response to JSP. Hi, How Axis stub (generated thru WSDL2Java) can return response to JSP? I can see response in XML format.. response can be print to browser using servlet in text/html format. . But I am not sure how to convert response to Java object than be displayed to JSP. Regards Ajay
Re: Axis stub response to JSP.
Ajay , The HappyAxis.jsp contains a call to the version.aar service. However, that's using Axiom OM to send/receive the request. You use Axiom to manually construct the xml request (as opposed to generating a stub with wsdl2java). Then you have to manually iterate through the response to get at the data you need. HTH, Giao --- Ajay Joshi [EMAIL PROTECTED] wrote: Hi, How Axis stub (generated thru WSDL2Java) can return response to JSP? I can see response in XML format.. response can be print to browser using servlet in text/html format. . But I am not sure how to convert response to Java object than be displayed to JSP. Regards Ajay __ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Axis stub response to JSP.
I guess, you can directly invoke your webservice from JSP using the stub (I haven't tried it though). For Ex: % String endPointURL = http://localhost/webservices/services/MyService; MyServiceStub stub = new MyServiceStub(endPointURL); Employee[] employees = stub.getEmployees(); // getEmployees is a method in your service // Use this employees array to display the data in the jsp. % From: Martin Gainty [mailto:[EMAIL PROTECTED] Sent: Thursday, October 26, 2000 1:33 PM To: axis-user@ws.apache.org Subject: Re: Axis stub response to JSP. JSP - Servlet(packages WSDLToJava StubClient) including encoding SOAP Request into XML- AxisServlet AxisServlet- XML response back to Servlet - Servlet parses the XML /populates beans/sends textResponse back -JSP (AJAX Div Tag or create ResultsJsp) Im sure there is a simpler solution..Anyone else? M-- - Original Message - From: Ajay Joshi mailto:[EMAIL PROTECTED] To: axis-user@ws.apache.org Sent: Thursday, October 25, 2007 3:32 PM Subject: Axis stub response to JSP. Hi, How Axis stub (generated thru WSDL2Java) can return response to JSP? I can see response in XML format.. response can be print to browser using servlet in text/html format. . But I am not sure how to convert response to Java object than be displayed to JSP. Regards Ajay