Results 1 to 6 of 6

Thread: Sending SOAP Request in java

  1. #1
    Join Date
    Nov 2009
    Posts
    678

    Sending SOAP Request in java

    Hello, I want to know all of the details about the Sending SOAP Request in java. I am learning java programming and while learning it, I need to create a case study on Sending SOAP Request in java, but as I am beginner in java; I don't know what did it mean. If you know it in detail then please provide me details about it.

  2. #2
    Join Date
    Apr 2008
    Posts
    1,948

    Re: Sending SOAP Request in java

    Hello, if you want to send the Soap request in java then you need to make use of the code below:
    Code:
    POST /InStock HTTP/1.1
    Host: www.techarena.in
    Content-Type: application/soap+xml; charset=utf-8
    Content-Length: nnn
    
    <?xml version="1.0"?>
    <soap:Envelope
    xmlns:soap="http://forums.techarena.in/2001/12/soap-envelope"
    soap:encodingStyle="http://forums.techarena.in/2001/12/soap-encoding">
    
    <soap:Body xmlns:m="http://forums.techarena.in/stock">
      <m:GetStockPrice>
        <m:Product>Wipro</m:Product>
      </m:GetStockPrice>
    </soap:Body>
    
    </soap:Envelope>

  3. #3
    Join Date
    May 2008
    Posts
    2,012

    Re: Sending SOAP Request in java

    Hello, this is simple.
    • Right click on the package.
    • In Categories, select "Web Services", and "Web Service Client" for the file type.
    • Select on the button "next".
    • Check "WSDL URL", and fills the corresponding fields.
    • Select Finish.


    Then to call the methods, you must follow these steps:
    • Right click in the main ().
    • Select "Web Service Client Resources" in the menu.
    • Select "Call Web Service Operation".
    • Select the method you want to use, and go.

  4. #4
    Join Date
    Apr 2008
    Posts
    2,005

    Re: Sending SOAP Request in java

    Hello, if you want to send the response then you need to make use of the code below for sending response in java:
    Code:
    HTTP/1.1 200 OK
    Content-Type: application/soap+xml; charset=utf-8
    Content-Length: nnn
    
    <?xml version="1.0"?>
    <soap:Envelope
    xmlns:soap="http://forums.techarena.in/2001/12/soap-envelope"
    soap:encodingStyle="http://forums.techarena.in/2001/12/soap-encoding">
    
    <soap:Body xmlns:m="http://www.techarena.in/stock">
      <m:GetStockRateResponse>
        <m:Rate>34.5</m:Rate>
      </m:GetStockRateResponse>
    </soap:Body>
    
    </soap:Envelope>

  5. #5
    Join Date
    May 2008
    Posts
    2,297

    Re: Sending SOAP Request in java

    Hello, if you want to use the command line for compiling and executing and or for managing the services you if make use of the soap client for running the soap client. So, you need to make use of the classpath environment and that file must be having following jar files:
    • soap.jar
    • activation.jar
    • mail.jar
    • xerces.jar

  6. #6
    Join Date
    Oct 2005
    Posts
    2,393

    Re: Sending SOAP Request in java

    Hello, I think the books below will provide you all of the details which you want:
    • Bleeding at the Keyboard - A Guide to Modern Programming with Java
    • Concurrent Programming in Java: Design Principles and Patterns
    • JXTA
    • Securing Java
    • Data Structures and Algorithms With Object-Oriented Design Patterns in Java

Similar Threads

  1. Replies: 3
    Last Post: 20-01-2012, 08:46 PM
  2. Sending a POST Request in Java
    By Sheenas in forum Software Development
    Replies: 4
    Last Post: 26-02-2010, 10:52 PM
  3. JSP form - error in sending request
    By Vodka in forum Software Development
    Replies: 5
    Last Post: 18-01-2010, 02:04 PM
  4. XML injection in a SOAP request
    By Logan.M in forum Software Development
    Replies: 4
    Last Post: 30-04-2009, 11:30 PM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Page generated in 1,714,051,422.88460 seconds with 16 queries