How do I create a soap client?
I need to create a SOAP client. The SOAP client should access se开发者_运维技巧rvices exposed using SOAP messages. It performs dynamic bindings and executes methods at remote web services. Soap methods are:
- getTodoList(acronym) -> List of TodoData()
- getTodoOneDay(acronym, date) -> List of TodoData()
- createTodo(acronym, time, note, priority) -> String
- updateTodo(id, acronym, time, note, priority) -> String
- deleteTodo(acronym, id) -> String
There is a soap server running on http://lol.comlab.bth.se:8090. Please help me by giving code in either php, java, python or any other language.
You could invoke method getTodoList(acronym)
using PHP SOAP Extension in WSDL Mode:
$client = new SoapClient("http://lol.comlab.bth.se:8090/PathToYour.wsdl");
$return = $client->getTodoList(acronym));
Or in non-WSDL Mode:
$client = new SoapClient(null, array(
'location' => "http://lol.comlab.bth.se:8090/PathToYourServer.php",
'uri' => "urn://lol.comlab.bth.se",
'trace' => 1 ));
$return = $client->__soapCall("getTodoList", array(acronym));
Also, these tutorials could be helpful:
- PHP SOAP Extension
- PHP SOAP Extension - Server Applications
Just install the python-zsi library, or any other source code generator, and execute:
wsdl2py http://lol.comlab.bth.se:8090/wsdl
your done
I think you're asking someone to write the whole client, and not just help out with it. You might try another site to hire a coder for this.
精彩评论