もちろん、SOAPコールを作成するJavaコードの例があります。

java.io.ioexceptionをインポートします。
java.io.stringreaderをインポートします。
java.net.urlをインポートします。
javax.xml.soap。*をインポートします。

パブリッククラスのsoapclient {
    public static void main（string args []）スロー例外{
        //新しいSoapConnectionオブジェクトを作成します
        SoapConnectionFactory SoapConnectionFactory = SoapConnectionFactory.newintenance（）;
        soapconnection soapconnection = soapconnectionfactory.createconnection（）;

        //指定されたURLにSOAPメッセージを送信します
        string url = "http://www.example.com/math";
        Soapmessage Soapresspense = soapconnection.call（createsoaprequest（）、url）;

        //石鹸の回答を処理します
        printsoaprespense（soapresspense）;

        soapconnection.close（）;
    }

    private static soapmessage creasoaprequest（）スロー例外{
        messagefactory messagefactory = messagefactory.newintenance（）;
        SOAPMESSAGE SOAPMESSAGE = messageFactory.createMessage（）;
        Soappar soappar = soapmessage.getsoappar（）;

        string serveruri = "http://www.example.com/math";

        // SOAPコンテンツを作成します
        Soapenvelope Enlope = Soappart.getEnvelope（）;
        avelope.addnamespacedeclaration（ "math"、serveruri）;

        soapheader header = avelope.getheader（）;
        Soapbody Soapbody = envelope.getBody（）;
        soapelement soapbodyelem = soapbody.addchildement（ "add"、 "math"）;
        soapbodyelem1 = soapbodylem.addchildement（ "a"、math "）;
        soapbodyelem1.addtextnode（ "3"）;
        SOAPELEMENT SOAPBODYLEM2 = SOAPBODYELM.ADDCHILDEMENT（ "B"、 "MATH"）;
        soapbodylem2.addtextnode（ "5"）;

        Mimeheaders Headers = SoapMessage.getMimeHeaders（）;
        Headers.Addheader（ "Soapaction"、serveruri + "/add"）;

        soapmessage.savechanges（）;

        / * SOAPアプリケーションを印刷 */
        System.out.print（ "要求SOAPメッセージ="）;
        soapmessage.writeto（system.out）;
        System.out.println（）;

        ソープメッジを返します。
    }

    /**
     * SOAP応答を処理および印刷する方法
     */
    private static void printsoapresponse（Soapmessage Soapresso）スロー例外{
        TransformerFactory TransforcerFactory = TransformerFactory.NewIntenance（）;
        トランストランス= TransformerFactory.NewTransFormer（）;
        ソースsourcecontent = sopaprense.getSoappart（）。getContent（）;
        system.out.print（ "\ nrespense soap message ="）;
        StreamResult results = new StreamResult（system.out）;
        Transformer.transform（sourcecontent、result）;
    }
}

この例では、JavaのAPIを使用して「SoapConnection」オブジェクトを作成し、リモートサーバーにSOAPコールを作成します。
Claro, aquí hay un ejemplo de código Java para realizar una llamada SOAP:

import java.io.IOException;
import java.io.StringReader;
import java.net.URL;
import javax.xml.soap.*;

public class SOAPClient {
    public static void main(String args[]) throws Exception {
        // Crea un nuevo objeto SOAPConnection
        SOAPConnectionFactory soapConnectionFactory = SOAPConnectionFactory.newInstance();
        SOAPConnection soapConnection = soapConnectionFactory.createConnection();

        // Envía el mensaje SOAP a la URL especificada
        String url = "http://www.example.com/math";
        SOAPMessage soapResponse = soapConnection.call(createSOAPRequest(), url);

        // Procesa la respuesta SOAP
        printSOAPResponse(soapResponse);

        soapConnection.close();
    }

    private static SOAPMessage createSOAPRequest() throws Exception {
        MessageFactory messageFactory = MessageFactory.newInstance();
        SOAPMessage soapMessage = messageFactory.createMessage();
        SOAPPart soapPart = soapMessage.getSOAPPart();

        String serverURI = "http://www.example.com/math";

        // Crea el contenido SOAP
        SOAPEnvelope envelope = soapPart.getEnvelope();
        envelope.addNamespaceDeclaration("math", serverURI);

        SOAPHeader header = envelope.getHeader();
        SOAPBody soapBody = envelope.getBody();
        SOAPElement soapBodyElem = soapBody.addChildElement("Add", "math");
        SOAPElement soapBodyElem1 = soapBodyElem.addChildElement("a", "math");
        soapBodyElem1.addTextNode("3");
        SOAPElement soapBodyElem2 = soapBodyElem.addChildElement("b", "math");
        soapBodyElem2.addTextNode("5");

        MimeHeaders headers = soapMessage.getMimeHeaders();
        headers.addHeader("SOAPAction", serverURI + "/Add");

        soapMessage.saveChanges();

        /* Imprime la solicitud SOAP */
        System.out.print("Request SOAP Message = ");
        soapMessage.writeTo(System.out);
        System.out.println();

        return soapMessage;
    }

    /**
     * Método para procesar y imprimir la respuesta SOAP
     */
    private static void printSOAPResponse(SOAPMessage soapResponse) throws Exception {
        TransformerFactory transformerFactory = TransformerFactory.newInstance();
        Transformer transformer = transformerFactory.newTransformer();
        Source sourceContent = soapResponse.getSOAPPart().getContent();
        System.out.print("\nResponse SOAP Message = ");
        StreamResult result = new StreamResult(System.out);
        transformer.transform(sourceContent, result);
    }
}

Este ejemplo utiliza la API SOAP de Java para crear un objeto 'SOAPConnection' y realizar una llamada SOAP a un servidor remoto.