File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Web Services and the fly likes How can i captor xml response return from http non web app Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Web Services
Bookmark "How can i captor xml response return from http non web app" Watch "How can i captor xml response return from http non web app" New topic
Author

How can i captor xml response return from http non web app

Meir Yan
Ranch Hand

Joined: Apr 27, 2006
Posts: 597
Hello all its not exactly web services but its like ...
im using WBEM
http://wbemservices.sourceforge.net/#Development
client to communicate to distant server , this is some kind of simple way
to send and receive object thorough xml ( like light version of web services ) .

im sending the requests via http with requests throw the client but i have no way to receive the xml errors that are sending
back via http response , the only way for me to get the xml response back is to sniff the network and capture the packets coming back
from the distant server , the return error are not related to the WBEM client this is simple response coming back from the server
my question is how can i capture this xml coming back from the server with java code .
my code does not run under web server , its simple application .

Thanks
William Brogden
Author and all-around good cowpoke
Rancher

Joined: Mar 22, 2000
Posts: 12781
    
    5
Exactly how are you constructing the request?

If you are creating a URLConnection or HttpURLConnection, the getInputStream method is provided so you can get the body of the response.

Bill
Meir Yan
Ranch Hand

Joined: Apr 27, 2006
Posts: 597
Hello

im creating the request throw the WBEM services lib client that making the http request , the problem is that i can't find any

way in that lib to catch the http response , so im looking some kind of java native way to that
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: How can i captor xml response return from http non web app