web services - How to generate soap request xml from wsdl file in java -
As a parameter, search for some Java Openers API to create a soap request xml file with wsdl_URL and operation name Actually, soap U is doing this and I tried to go through soap UI source code, but I am not able to understand the whole code to complete my work.
Is there a Java API available to do this
I spent a few days in the net and I did not see any results.
If any body has any thoughts then please help me.
> Thanks in advance.
You can use open-source membrane SOA library () to generate XMLs for you Every operation defined in the WSDL:
create public zerom templates (string url) {WSDLPers parser = new WSDLPiras (); Definitions wsdl = parser.parse (url); Stringworld author = new stringwriter (); SOARequestCreator Manufacturer = New SOARequestCreator (); Creator.setbuilder (new markup builder (author)); Creator.setDefinitions (WSDL); For (service service: wsdl.getServices ()) {for (port port: service.getPorts ()) {binding binding = port .getBinding (); PortType PortType = Binding. JetProperty (); (Operation op: portType.getOperations ()) for {creator.setCreator (new request template creator ()); Creator.createRequest (port.getName (), op.getName (), binding.Getnam ()); Println (author); Author.getBuffer () setLength (0). }}}
Comments
Post a Comment