aspose file tools*
The moose likes Web Services and the fly likes web services Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Web Services
Bookmark "web services" Watch "web services" New topic
Author

web services

Thirumalesh yeligar
Greenhorn

Joined: Sep 02, 2013
Posts: 29
how to build soap header using message context and Binding provider......?
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41867
    
  63
I'm not clear on what the message context and the binding provider have to do with setting headers. Have you gotten the SAAJ client to run which I pointed you to before? Its source code shows how to set SOAP headers. (Are you even still using SAAJ? Or maybe JAX-WS?)

Either way, provide us with more detail about what you're doing, and where you're stuck making progress.


Ping & DNS - my free Android networking tools app
Thirumalesh yeligar
Greenhorn

Joined: Sep 02, 2013
Posts: 29
Hi ulf,

Thanks for your reply... what is the use of java classes that are genereated from wsdl file and using these classes how can i build soap body..?
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41867
    
  63
This question has nothing to do with the first question about adding SOAP headers, right? Just want to make sure I'm not missing some connection.

You can those Java classes to build a client for the WS described by the WSDL. They have all he code needed for creating the SOAP, sending it across the network, receiving the response and extracting the data form that.

using these classes how can i build soap body..?

As I mentioned in the previous paragraph, it is the code in those classes that create and read the SOAP - you (or rather, any code you write) would not be doing that. If you want to create SOAP directly (why?), then the SOAP client code I pointed you to repeatedly would be a starting point.

Your questions are a bit all over the place, so I'm having a hard time discerning what exactly it is you're trying to do. Are you following some introduction or tutorial? Do you have any client or server WS code so far?
Thirumalesh yeligar
Greenhorn

Joined: Sep 02, 2013
Posts: 29
i dont know anything about SOAP. now i'm learning
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41867
    
  63
Then I again strongly advise you start by working through some tutorials; http://www.coderanch.com/how-to/java/WebServicesFaq points to several good starting points, like https://www.java.net/today/2003/11/05/ch4SOAP.pdf for learning about SOAP, http://oreilly.com/catalog/javawsian/chapter/ch03.pdf for learning about SAAJ, and https://www.java.net/print/219684 for learning about JAX-WS (which I recommend over SAAJ).
Thirumalesh yeligar
Greenhorn

Joined: Sep 02, 2013
Posts: 29
Actullay i have java classes generated from the wsdl file. Now i have to link classes in the soap body... How to do it? please help me..............
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41867
    
  63
What does it mean to "link classes in the soap body"?
Thirumalesh yeligar
Greenhorn

Joined: Sep 02, 2013
Posts: 29
in my project documentation there are classes that i have to link and send it to the server..
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41867
    
  63
I have no idea what might be meant by "linking classes". If this task has been given to you, you should ask the person from whom you got it.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: web services