Guest AendyDer Request liegt bereits vollständig vor
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
<?xml version="1.0" ?>
<S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/">
<S:Body>
<CheckForSoftwareUpdates>
<InstalledSoftware>
<SoftwareName>
SampleSoftware1
</SoftwareName>
<Version>
1.2.3
</Version>
<OperatingSystem>
Windows_XP
</OperatingSystem>
</InstalledSoftware>
<InstalledSoftware>
<SoftwareName>
SampleSoftware2
</SoftwareName>
<Version>
2.3.4
</Version>
<OperatingSystem>
Windows_XP
</OperatingSystem>
</InstalledSoftware>
</CheckForSoftwareUpdates>
</S:Body>
</S:Envelope>
1 2 3 4 5 6 7 8
#!perl -w use SOAP::Lite; my $service = SOAP::Lite -> service('http://192.168.0.214/update.wsdl'); my $test = $service->CheckForSoftwareUpdates('SampleSoftware1');
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
<?xml version ="1.0" ?>
<definitions name="StockQuote"
targetNamespace="http://example.org/StockQuote"
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
xmlns:tns="http://schemas.xmlsoap.org/wsdl/soap/"
xmlns="http://schemas.xmlsoap.org/wsdl/">
<message name="CheckForSoftwareUpdatesRequest">
<part name="InstalledSoftware" type=""/>
</message>
<message name="CheckForSoftwareUpdatesResponse">
<part name="Result" type=""/>
</message>
<portType name="StockQuotePortType">
<operation name="CheckForSoftwareUpdates">
<input message="tns:CheckForSoftwareUpdatesRequest"/>
<output message="tns:CheckForSoftwareUpdatesResponse"/>
</operation>
</portType>
<binding name="StockQuoteBinding" type="tns:StockQuotePortType">
<soap:binding style="rpc"
transport="http://schemas.xmlsoap.org/soap/http"/>
<operation name="CheckForSoftwareUpdates">
<soap:operation soapAction="http://192.168.0.214/update/CheckForSoftwareUpdate"/>
<input>
<soap:body use="encoded" namespace="urn:xmethods-delayed-quotes"
encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
</input>
<output>
<soap:body use="encoded" namespace="urn:xmethods-delayed-quotes"
encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
</output>
</operation>
</binding>
<service name="StockQuoteService">
<port name="StockQuotePort" binding="StockQuoteBinding">
<soap:address location="http://192.168.0.214/stockquote.php"/>
</port>
</service>
</definitions>
1 2 3 4 5 6 7 8
use SOAP::Lite; my $client = SOAP::Lite->new( proxy => 'URL der Gegenstelle', uri => 'Klasse der Funktion', ); print $client->Funktionsaufruf( Parameter )->result;
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
use SOAP::Lite;
my $soap = SOAP::Lite->new( proxy => 'http://192.168.0.214/stockquote1.php');
$soap->on_action( sub { "urn:HelloWorld#sayHello" });
$soap->autotype(0)->readable(1);
my $som = $soap->call(
'CheckForSoftwareUpdates',
SOAP::Data->name('InstalledSoftware')->value(
\SOAP::Data->value([
SOAP::Data->name('SoftwareName')->value('SampleSoftware1'),
SOAP::Data->name('Version')->value('1.2.3'),
SOAP::Data->name('OperatingSystem')->value('Windows_XP'),
])
)
);
if ($som->fault)
{
die $som->fault->{ faultstring };
}
print $som->result, "\n";
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
<?xml version="1.0" encoding="UTF-8"?>
<soap:Envelope
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
soap:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Body>
<CheckForSoftwareUpdates>
<InstalledSoftware>
<soapenc:Array>
<SoftwareName>SampleSoftware1</SoftwareName>
<Version>1.2.3</Version>
<OperatingSystem>Windows_XP</OperatingSystem>
</soapenc:Array>
</InstalledSoftware>
</CheckForSoftwareUpdates>
</soap:Body>
</soap:Envelope>
1 2 3 4 5 6 7 8 9 10
my $som = $soap->call( 'CheckForSoftwareUpdates', SOAP::Data->name('InstalledSoftware')->value( \SOAP::Data->value([ SOAP::Data->name('SoftwareName')->value('SampleSoftware1'), SOAP::Data->name('Version')->value('1.2.3'), SOAP::Data->name('OperatingSystem')->value('Windows_XP'), ]) ) );
1 2 3 4 5 6 7 8 9 10
my $som = $soap->call( 'CheckForSoftwareUpdates', SOAP::Data->name( 'InstalledSoftware' => \SOAP::Data->value( SOAP::Data->name('SoftwareName')->value('SampleSoftware1'), SOAP::Data->name('Version')->value('1.2.3'), SOAP::Data->name('OperatingSystem')->value('Windows_XP'), ) ) );