1 |
#!/usr/bin/perl |
#!/usr/bin/perl |
2 |
|
|
3 |
use XMLRPC::Lite; |
use XMLRPC::Lite; |
4 |
|
use Data::Dumper; |
5 |
|
|
6 |
my $xmlrpc = new XMLRPC::Lite->proxy('http://127.0.0.1/wstest.dgmx'); |
my $xmlrpc = new XMLRPC::Lite->proxy('http://127.0.0.1/wstest.dgmx'); |
7 |
|
|
14 |
} |
} |
15 |
|
|
16 |
|
|
17 |
$xmlresult = $xmlrpc->call('SayGoodbye', 'Byeyeyeye', 10, 20, 10.1, 20.2 ); |
#$xmlresult = $xmlrpc->call('getastruct', 10, 20 ); |
18 |
|
$xmlresult = $xmlrpc->call('sendastruct', { Value1 => 10, Value2 => 20 } ); |
19 |
|
|
20 |
if( $xmlresult->result ) { |
if( $xmlresult->result ) { |
21 |
print $xmlresult->result . "\n"; |
print Dumper $xmlresult->result; |
22 |
} else { |
} else { |
23 |
print $xmlresult->fault->{faultString} . "\n"; |
print $xmlresult->fault->{faultString} . "\n"; |
24 |
} |
} |