From f63138fc8706890a04b6a33c2c2b4d989bc38a86 Mon Sep 17 00:00:00 2001 From: Martin Kutter Date: Mon, 10 Sep 2007 08:23:59 -0800 Subject: [PATCH] import SOAP-WSDL 2.00_13 from CPAN git-cpan-module: SOAP-WSDL git-cpan-version: 2.00_13 git-cpan-authorid: MKUTTER git-cpan-file: authors/id/M/MK/MKUTTER/SOAP-WSDL-2.00_13.tar.gz --- Build.PL | 81 +-- CHANGES | 54 +- HACKING | 44 +- LICENSE | 14 +- MANIFEST | 420 +++++------ META.yml | 15 +- README | 48 +- TODO | 71 +- benchmark/01_expat.t | 44 +- benchmark/XSD/01_anyType.t | 21 + benchmark/XSD/02_anySimpleType.t | 22 + benchmark/XSD/03_string.t | 22 + bin/wsdl2perl.pl | 242 +++---- example/fortune.pl | 92 +-- example/lib/MyElements/CountCookies.pm | 142 ++-- .../lib/MyElements/CountCookiesResponse.pm | 170 ++--- example/lib/MyElements/GetCitiesByCountry.pm | 186 ++--- .../MyElements/GetCitiesByCountryResponse.pm | 186 ++--- example/lib/MyElements/GetFortuneCookie.pm | 142 ++-- .../MyElements/GetFortuneCookieResponse.pm | 170 ++--- example/lib/MyElements/GetSpecificCookie.pm | 170 ++--- .../MyElements/GetSpecificCookieResponse.pm | 170 ++--- example/lib/MyElements/GetWeather.pm | 210 +++--- example/lib/MyElements/GetWeatherResponse.pm | 186 ++--- example/lib/MyElements/int.pm | 120 ++-- example/lib/MyElements/readNodeCount.pm | 142 ++-- .../lib/MyElements/readNodeCountResponse.pm | 170 ++--- example/lib/MyElements/string.pm | 136 ++-- .../FullerData_x0020_Fortune_x0020_Cookie.pm | 654 ++++++++--------- example/lib/MyInterfaces/GlobalWeather.pm | 166 ++--- .../FullerData_x0020_Fortune_x0020_Cookie.pm | 98 +-- example/lib/MyTypemaps/GlobalWeather.pm | 100 +-- example/weather.pl | 40 +- example/weather_wsdl.pl | 82 ++- example/wsdl/FortuneCookie.xml | 614 ++++++++-------- example/wsdl/genericbarcode.xml | 304 ++++---- example/wsdl/globalweather.xml | 368 +++++----- lib/SOAP/WSDL.pm | 672 ++++++++++-------- lib/SOAP/WSDL/Base.pm | 110 +-- lib/SOAP/WSDL/Binding.pm | 50 +- lib/SOAP/WSDL/Client.pm | 338 +++++---- lib/SOAP/WSDL/Client/Base.pm | 202 +++--- lib/SOAP/WSDL/Definitions.pm | 626 ++++++++-------- lib/SOAP/WSDL/Deserializer/SOAP11.pm | 49 ++ lib/SOAP/WSDL/Deserializer/SOM.pm | 100 +++ lib/SOAP/WSDL/Expat/MessageParser.pm | 36 +- lib/SOAP/WSDL/Expat/MessageStreamParser.pm | 4 +- lib/SOAP/WSDL/Expat/MessageSubParser.pm | 4 +- lib/SOAP/WSDL/Expat/SubParser.pm | 4 +- lib/SOAP/WSDL/Expat/WSDLParser.pm | 78 +- lib/SOAP/WSDL/Factory/Deserializer.pm | 137 ++++ lib/SOAP/WSDL/Factory/Serializer.pm | 202 +++--- lib/SOAP/WSDL/Factory/Transport.pm | 437 ++++++------ lib/SOAP/WSDL/Manual.pod | 424 +++++------ lib/SOAP/WSDL/Manual/Glossary.pod | 160 ++--- lib/SOAP/WSDL/Manual/WS_I.pod | 16 +- lib/SOAP/WSDL/Operation.pm | 8 +- lib/SOAP/WSDL/Parser.pod | 26 +- lib/SOAP/WSDL/Port.pm | 18 +- lib/SOAP/WSDL/SAX/MessageHandler.pm | 4 +- lib/SOAP/WSDL/SAX/WSDLHandler.pm | 54 +- lib/SOAP/WSDL/Serializer/SOAP11.pm | 48 +- lib/SOAP/WSDL/Service.pm | 6 +- lib/SOAP/WSDL/Transport/HTTP.pm | 182 +++-- lib/SOAP/WSDL/TypeLookup.pm | 250 +++---- lib/SOAP/WSDL/XSD/Builtin.pm | 8 +- lib/SOAP/WSDL/XSD/ComplexType.pm | 98 +-- lib/SOAP/WSDL/XSD/Element.pm | 76 +- lib/SOAP/WSDL/XSD/Schema.pm | 2 +- lib/SOAP/WSDL/XSD/SimpleType.pm | 42 +- lib/SOAP/WSDL/XSD/Typelib/Builtin.pm | 389 +++++----- lib/SOAP/WSDL/XSD/Typelib/Builtin/ENTITY.pm | 8 +- lib/SOAP/WSDL/XSD/Typelib/Builtin/ID.pm | 2 +- lib/SOAP/WSDL/XSD/Typelib/Builtin/IDREF.pm | 2 +- lib/SOAP/WSDL/XSD/Typelib/Builtin/IDREFS.pm | 2 +- lib/SOAP/WSDL/XSD/Typelib/Builtin/NCName.pm | 4 +- lib/SOAP/WSDL/XSD/Typelib/Builtin/NMTOKEN.pm | 8 +- lib/SOAP/WSDL/XSD/Typelib/Builtin/NMTOKENS.pm | 10 +- lib/SOAP/WSDL/XSD/Typelib/Builtin/NOTATION.pm | 22 +- lib/SOAP/WSDL/XSD/Typelib/Builtin/Name.pm | 6 +- lib/SOAP/WSDL/XSD/Typelib/Builtin/QName.pm | 20 +- .../WSDL/XSD/Typelib/Builtin/anySimpleType.pm | 10 +- lib/SOAP/WSDL/XSD/Typelib/Builtin/anyType.pm | 6 +- lib/SOAP/WSDL/XSD/Typelib/Builtin/anyURI.pm | 20 +- .../WSDL/XSD/Typelib/Builtin/base64Binary.pm | 22 +- lib/SOAP/WSDL/XSD/Typelib/Builtin/boolean.pm | 8 +- lib/SOAP/WSDL/XSD/Typelib/Builtin/byte.pm | 4 +- lib/SOAP/WSDL/XSD/Typelib/Builtin/date.pm | 72 +- lib/SOAP/WSDL/XSD/Typelib/Builtin/dateTime.pm | 28 +- lib/SOAP/WSDL/XSD/Typelib/Builtin/decimal.pm | 30 +- lib/SOAP/WSDL/XSD/Typelib/Builtin/double.pm | 6 +- lib/SOAP/WSDL/XSD/Typelib/Builtin/duration.pm | 26 +- lib/SOAP/WSDL/XSD/Typelib/Builtin/float.pm | 26 +- lib/SOAP/WSDL/XSD/Typelib/Builtin/gDay.pm | 24 +- lib/SOAP/WSDL/XSD/Typelib/Builtin/gMonth.pm | 24 +- .../WSDL/XSD/Typelib/Builtin/gMonthDay.pm | 24 +- lib/SOAP/WSDL/XSD/Typelib/Builtin/gYear.pm | 24 +- .../WSDL/XSD/Typelib/Builtin/gYearMonth.pm | 24 +- .../WSDL/XSD/Typelib/Builtin/hexBinary.pm | 22 +- lib/SOAP/WSDL/XSD/Typelib/Builtin/int.pm | 4 +- lib/SOAP/WSDL/XSD/Typelib/Builtin/integer.pm | 6 +- lib/SOAP/WSDL/XSD/Typelib/Builtin/language.pm | 6 +- lib/SOAP/WSDL/XSD/Typelib/Builtin/list.pm | 52 +- lib/SOAP/WSDL/XSD/Typelib/Builtin/long.pm | 2 +- .../XSD/Typelib/Builtin/negativeInteger.pm | 6 +- .../XSD/Typelib/Builtin/nonNegativeInteger.pm | 8 +- .../XSD/Typelib/Builtin/nonPositiveInteger.pm | 10 +- .../XSD/Typelib/Builtin/normalizedString.pm | 6 +- .../XSD/Typelib/Builtin/positiveInteger.pm | 8 +- lib/SOAP/WSDL/XSD/Typelib/Builtin/short.pm | 6 +- lib/SOAP/WSDL/XSD/Typelib/Builtin/string.pm | 8 +- lib/SOAP/WSDL/XSD/Typelib/Builtin/time.pm | 42 +- lib/SOAP/WSDL/XSD/Typelib/Builtin/token.pm | 8 +- .../WSDL/XSD/Typelib/Builtin/unsignedByte.pm | 10 +- .../WSDL/XSD/Typelib/Builtin/unsignedInt.pm | 12 +- .../WSDL/XSD/Typelib/Builtin/unsignedLong.pm | 6 +- .../WSDL/XSD/Typelib/Builtin/unsignedShort.pm | 8 +- lib/SOAP/WSDL/XSD/Typelib/ComplexType.pm | 108 +-- lib/SOAP/WSDL/XSD/Typelib/Element.pm | 70 +- lib/SOAP/WSDL/XSD/Typelib/SimpleType.pm | 4 +- t/002_parse_wsdl.t | 12 +- t/002_sax.t | 4 +- t/003_wsdl_based_serializer.t | 1 - t/004_parse_wsdl.t | 2 +- t/004_sax_wsdl.t | 2 +- t/005_parse_contributed.t | 2 - t/005_sax_contributed_wsdl.t | 2 - t/006_client.t | 4 +- t/009_data_classes.t | 2 +- t/012_element.t | 10 +- t/014_sax_typelib.t | 46 +- t/016_client_object.t | 24 +- t/017_generator_expat.t | 92 +-- t/017_generator_libxml.t | 100 +-- t/018_generator_expat.t | 28 +- t/018_generator_libxml.t | 34 +- t/021_generator_element_ref_expat.t | 56 +- t/021_generator_element_ref_libxml.t | 80 +-- t/098_pod.t | 36 +- t/Expat/02_sub_parser.t | 670 ++++++++--------- t/Expat/03_wsdl.t | 20 +- t/SOAP/WSDL/01_use.t | 6 +- t/SOAP/WSDL/02_port.t | 2 +- t/SOAP/WSDL/03_complexType-all.t | 164 ++--- t/SOAP/WSDL/03_complexType-choice.t | 22 +- t/SOAP/WSDL/03_complexType-complexContent.t | 42 +- t/SOAP/WSDL/03_complexType-element-ref.t | 86 +-- t/SOAP/WSDL/03_complexType-group.t | 42 +- t/SOAP/WSDL/03_complexType-sequence.t | 148 ++-- t/SOAP/WSDL/03_complexType-simpleContent.t | 42 +- t/SOAP/WSDL/04_element-complexType.t | 8 +- t/SOAP/WSDL/04_element-simpleType.t | 100 +-- t/SOAP/WSDL/04_element.t | 140 ++-- t/SOAP/WSDL/05_simpleType-list.t | 106 +-- t/SOAP/WSDL/05_simpleType-restriction.t | 118 +-- t/SOAP/WSDL/05_simpleType-union.t | 132 ++-- t/SOAP/WSDL/11_helloworld.NET.t | 108 +-- t/SOAP/WSDL/XSD/Typelib/Builtin/001_string.t | 36 +- .../WSDL/XSD/Typelib/Builtin/002_dateTime.t | 2 +- t/SOAP/WSDL/XSD/Typelib/Builtin/003_date.t | 54 +- t/SOAP/WSDL/XSD/Typelib/Builtin/004_time.t | 25 + t/acceptance/wsdl/02_port.wsdl | 220 +++--- .../wsdl/03_complexType-element-ref.wsdl | 2 +- .../wsdl/03_complexType-sequence.wsdl | 16 +- t/acceptance/wsdl/04_element-simpleType.wsdl | 116 +-- t/acceptance/wsdl/04_element.wsdl | 100 +-- t/acceptance/wsdl/05_simpleType-list.wsdl | 140 ++-- .../wsdl/05_simpleType-restriction.wsdl | 118 +-- t/acceptance/wsdl/05_simpleType-union.wsdl | 206 +++--- t/acceptance/wsdl/10_helloworld.asmx.xml | 150 ++-- t/acceptance/wsdl/11_helloworld.wsdl | 210 +++--- t/acceptance/wsdl/contributed/Axis.wsdl | 134 ++-- t/acceptance/wsdl/contributed/ETest.wsdl | 314 ++++---- t/acceptance/wsdl/contributed/OITest.wsdl | 302 ++++---- t/acceptance/wsdl/email_account.wsdl | 348 ++++----- t/lib/MyElement.pm | 12 +- t/lib/Test/SOAPMessage.pm | 126 ++-- t/lib/Typelib/Base.pm | 2 +- t/lib/Typelib/TEnqueueMessage.pm | 34 +- t/lib/Typelib/TMessage.pm | 50 +- t/test.pl | 15 + 181 files changed, 8714 insertions(+), 8161 deletions(-) create mode 100644 benchmark/XSD/01_anyType.t create mode 100644 benchmark/XSD/02_anySimpleType.t create mode 100644 benchmark/XSD/03_string.t create mode 100644 lib/SOAP/WSDL/Deserializer/SOAP11.pm create mode 100644 lib/SOAP/WSDL/Deserializer/SOM.pm create mode 100644 lib/SOAP/WSDL/Factory/Deserializer.pm create mode 100644 t/SOAP/WSDL/XSD/Typelib/Builtin/004_time.t create mode 100644 t/test.pl diff --git a/Build.PL b/Build.PL index 22ca352..e993b19 100644 --- a/Build.PL +++ b/Build.PL @@ -1,40 +1,41 @@ -use Module::Build; - -Module::Build->new( - create_makefile_pl => 'passthrough', - dist_abstract => 'SOAP with WSDL support', - dist_name => 'SOAP-WSDL', - dist_version => '2.00_12', - module_name => 'SOAP::WSDL', - license => 'artistic', - requires => { - 'Class::Std' => q/v0.0.8/, - 'Class::Std::Storable' => 0, - 'Date::Parse' => 0, - 'Date::Format' => 0, - 'LWP::UserAgent' => 0, - 'List::Util' => 0, - 'File::Basename' => 0, - 'File::Path' => 0, - 'XML::Parser::Expat' => 0, - 'Template' => 0, - 'Getopt::Long' => 0, - }, - buildrequires => { - 'Date::Parse' => 0, - 'Date::Format' => 0, - 'Test::More' => 0, - 'Class::Std' => q/v0.0.8/, - 'Class::Std::Storable' => 0, - 'List::Util' => 0, - 'LWP::UserAgent' => 0, - 'File::Basename' => 0, - 'File::Path' => 0, - 'XML::Parser::Expat' => 0, - 'Template' => 0, - 'Getopt::Long' => 0, - 'Cwd' => 0, - 'File::Find' => 0, - }, - recursive_test_files => 1, -)->create_build_script; +use Module::Build; + +Module::Build->new( + create_makefile_pl => 'passthrough', + dist_abstract => 'SOAP with WSDL support', + dist_name => 'SOAP-WSDL', + dist_version => '2.00_13', + module_name => 'SOAP::WSDL', + license => 'artistic', + requires => { + 'Class::Std' => q/v0.0.8/, + 'Class::Std::Storable' => 0, + 'Date::Parse' => 0, + 'Date::Format' => 0, + 'LWP::UserAgent' => 0, + 'List::Util' => 0, + 'File::Basename' => 0, + 'File::Path' => 0, + 'XML::Parser::Expat' => 0, + 'Template' => 0, + 'Getopt::Long' => 0, + }, + buildrequires => { + 'Date::Parse' => 0, + 'Date::Format' => 0, + 'Test::More' => 0, + 'Class::Std' => q/v0.0.8/, + 'Class::Std::Storable' => 0, + 'List::Util' => 0, + 'LWP::UserAgent' => 0, + 'File::Basename' => 0, + 'File::Path' => 0, + 'XML::Parser::Expat' => 0, + 'Template' => 0, + 'Getopt::Long' => 0, + 'Cwd' => 0, + 'File::Find' => 0, + 'Storable' => 0, + }, + recursive_test_files => 1, +)->create_build_script; diff --git a/CHANGES b/CHANGES index 5c2e318..f3605ea 100644 --- a/CHANGES +++ b/CHANGES @@ -26,10 +26,49 @@ Features: The following changes have been made: +2.00_13 +---- +The following features were added (the numbers in square brackets are the +tracker IDs from https://sourceforge.net/tracker/?group_id=111978&atid=660924): + * [ 1790619 ] Test transport backend + A test transport backend has been implemented (SOAP::WSDL::Transport::Test). + It returns the contents from a file and discards the response. + The filename is determined from the soap_action field. + + * [ 1785196 ] Replace outputsom(1) by deserializer plugin + outputsom(1) in SOAP::WSDL is now implemented via using the deserializer + plugin SOAP::WSDL::Deserializer::SOM. + + * [1785195] Support deserializer plugins + Deserializer plugin API added via SOAP::WSDL::Factory::Deserializer. + +The following bugs have been fixed (the numbers in square brackets are the +tracker IDs from https://sourceforge.net/tracker/?group_id=111978&atid=660921): + + * [1789581] Support ComplexType mixed + WSDL parser now supports using the mixed="true" attribute in complexType + definitions. Mixed content in messages is only supported via SOAP::SOM yet. + + * [1787975] 016_client_object.t fails due to testing XML as string + Removed string test. + + * [1787959] Test wsdl seems to be broken + Corrected typo. + + * [1787955] ::XSD::Typelib::date is broken + SOAP::WSDL::XSD::Typelib::Builtin::date now converts time-zoned dates properly, + and adds the local time zone if none is given. + + * [1785646] SOAPAction header not set from soap:operation soapAction + SOAP::WSDL now sets the SOAPAction header correctly. + +The following uncategorized improvements have been mad: + + * Documentation improvements 2.00_12 ---- - + The following bugs have been fixed (the numbers in square brackets are the tracker IDs from https://sourceforge.net/tracker/?group_id=111978&atid=660921): @@ -40,6 +79,16 @@ tracker IDs from https://sourceforge.net/tracker/?group_id=111978&atid=660921): * [1787054] Test suite requires XML::LibXML in 2.00_11 The test suite no longer requires XML::LibXML to pass. + * [1785678] SOAP envelope not checked for namespace + The SOAP envelope is now checked for the correct namespace. + + * [1786644] SOAP::WSDL::Manual - doc error + Documentation improvements + +The following uncategorized improvements have been made + + * The SOAPAction header is now alway quoted (R1109 in WS-I BP 1.0). + 2.00_11 ---- @@ -75,7 +124,8 @@ The following uncategorized improvements have been made - XML::LibXML * The missing prerequisite Template has been added. - * Documentation has been improved. + * Documentation has been improved: + - WS-I Compliance document added. 2.00_10 diff --git a/HACKING b/HACKING index d680422..cc27f04 100644 --- a/HACKING +++ b/HACKING @@ -15,31 +15,31 @@ The (my) current roadmap for SOAP::WSDL is: 1.* Development of the 1.* tree has stopped - I won't get past 1.2x anymore... 2.* WSDL -> Perl Class factory with offline WSDL processing - -2.01 -- WSDL support for the most common type definitions -- Online-facility (SOAP::WSDL) using WSDL object tree directly -- usable code generator + +2.01 +- WSDL support for the most common type definitions +- Online-facility (SOAP::WSDL) using WSDL object tree directly +- usable code generator - full namespace support when processing WSDL - high performance when parsing WSDL messages - get nearly as fast as - XML::Simple... - -2.02 -- Support for Apache-SOAP datatypes -- support for embedded atomic simpleType/complexType definitions -- Caching of WSDL object tree + generated code (when using SOAP::WSDL). -- Online-facility (SOAP::WSDL) using code generator via cache directory - -Somewhere on the TODO list (in no particular order): - -- validation -- typemaps for use with the type="tns:MyComplexType" XML attribute -- external entities support when parsing WSDL -- support all these XML Schema variants -- support creating XML Schmema definitions via SOAP::WSDL::XSD::* ('minimal conformant') + XML::Simple... + +2.02 +- Support for Apache-SOAP datatypes +- support for embedded atomic simpleType/complexType definitions +- Caching of WSDL object tree + generated code (when using SOAP::WSDL). +- Online-facility (SOAP::WSDL) using code generator via cache directory + +Somewhere on the TODO list (in no particular order): + +- validation +- typemaps for use with the type="tns:MyComplexType" XML attribute +- external entities support when parsing WSDL +- support all these XML Schema variants +- support creating XML Schmema definitions via SOAP::WSDL::XSD::* ('minimal conformant') - support other Schema definition languages than XML::Schema (maybe RelaxNG?) -- factor out SOAP::WSDL::XSD into it's own namespace (maybe just XSD ?) - +- factor out SOAP::WSDL::XSD into it's own namespace (maybe just XSD ?) + July 2007, Martin Kutter \ No newline at end of file diff --git a/LICENSE b/LICENSE index 41d0626..fd6bcd3 100644 --- a/LICENSE +++ b/LICENSE @@ -1,7 +1,7 @@ -SOAP::WSDL is dual licensed under the same terms as -Perl itself. - -This means at your choice, either the Perl Artistic License, or -the GNU GPL version 1 or higher. - - +SOAP::WSDL is dual licensed under the same terms as +Perl itself. + +This means at your choice, either the Perl Artistic License, or +the GNU GPL version 1 or higher. + + diff --git a/MANIFEST b/MANIFEST index 4452f08..7b65424 100644 --- a/MANIFEST +++ b/MANIFEST @@ -1,206 +1,214 @@ -benchmark/01_expat.t -bin/wsdl2perl.pl -Build.PL -CHANGES -example/fortune.pl -example/lib/MyElements/CountCookies.pm -example/lib/MyElements/CountCookiesResponse.pm -example/lib/MyElements/GetCitiesByCountry.pm -example/lib/MyElements/GetCitiesByCountryResponse.pm -example/lib/MyElements/GetFortuneCookie.pm -example/lib/MyElements/GetFortuneCookieResponse.pm -example/lib/MyElements/GetSpecificCookie.pm -example/lib/MyElements/GetSpecificCookieResponse.pm -example/lib/MyElements/GetWeather.pm -example/lib/MyElements/GetWeatherResponse.pm -example/lib/MyElements/int.pm -example/lib/MyElements/readNodeCount.pm -example/lib/MyElements/readNodeCountResponse.pm -example/lib/MyElements/string.pm -example/lib/MyInterfaces/FullerData_x0020_Fortune_x0020_Cookie.pm -example/lib/MyInterfaces/GlobalWeather.pm -example/lib/MyTypemaps/FullerData_x0020_Fortune_x0020_Cookie.pm -example/lib/MyTypemaps/GlobalWeather.pm -example/weather.pl -example/weather_wsdl.pl -example/wsdl/FortuneCookie.xml -example/wsdl/genericbarcode.xml -example/wsdl/globalweather.xml -HACKING -lib/SOAP/WSDL.pm -lib/SOAP/WSDL/Base.pm -lib/SOAP/WSDL/Binding.pm -lib/SOAP/WSDL/Client.pm -lib/SOAP/WSDL/Client/Base.pm -lib/SOAP/WSDL/Definitions.pm -lib/SOAP/WSDL/Expat/MessageParser.pm -lib/SOAP/WSDL/Expat/MessageStreamParser.pm -lib/SOAP/WSDL/Expat/MessageSubParser.pm -lib/SOAP/WSDL/Expat/SubParser.pm -lib/SOAP/WSDL/Expat/WSDLParser.pm -lib/SOAP/WSDL/Factory/Serializer.pm -lib/SOAP/WSDL/Factory/Transport.pm -lib/SOAP/WSDL/Manual.pod -lib/SOAP/WSDL/Manual/Glossary.pod -lib/SOAP/WSDL/Manual/WS_I.pod -lib/SOAP/WSDL/Message.pm -lib/SOAP/WSDL/Operation.pm -lib/SOAP/WSDL/OpMessage.pm -lib/SOAP/WSDL/Parser.pod -lib/SOAP/WSDL/Part.pm -lib/SOAP/WSDL/Port.pm -lib/SOAP/WSDL/PortType.pm -lib/SOAP/WSDL/SAX/MessageHandler.pm -lib/SOAP/WSDL/SAX/WSDLHandler.pm -lib/SOAP/WSDL/Serializer/SOAP11.pm -lib/SOAP/WSDL/Service.pm -lib/SOAP/WSDL/SOAP/Typelib/Fault11.pm -lib/SOAP/WSDL/SoapOperation.pm -lib/SOAP/WSDL/Transport/HTTP.pm -lib/SOAP/WSDL/TypeLookup.pm -lib/SOAP/WSDL/Types.pm -lib/SOAP/WSDL/XSD/Builtin.pm -lib/SOAP/WSDL/XSD/ComplexType.pm -lib/SOAP/WSDL/XSD/Element.pm -lib/SOAP/WSDL/XSD/Schema.pm -lib/SOAP/WSDL/XSD/Schema/Builtin.pm -lib/SOAP/WSDL/XSD/SimpleType.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/anySimpleType.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/anyType.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/anyURI.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/base64Binary.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/boolean.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/byte.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/date.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/dateTime.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/decimal.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/double.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/duration.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/ENTITY.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/float.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/gDay.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/gMonth.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/gMonthDay.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/gYear.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/gYearMonth.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/hexBinary.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/ID.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/IDREF.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/IDREFS.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/int.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/integer.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/language.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/list.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/long.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/Name.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/NCName.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/negativeInteger.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/NMTOKEN.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/NMTOKENS.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/nonNegativeInteger.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/nonPositiveInteger.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/normalizedString.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/NOTATION.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/positiveInteger.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/QName.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/short.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/string.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/time.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/token.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/unsignedByte.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/unsignedInt.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/unsignedLong.pm -lib/SOAP/WSDL/XSD/Typelib/Builtin/unsignedShort.pm -lib/SOAP/WSDL/XSD/Typelib/ComplexType.pm -lib/SOAP/WSDL/XSD/Typelib/Element.pm -lib/SOAP/WSDL/XSD/Typelib/SimpleType.pm -LICENSE -Makefile.PL -MANIFEST This list of files -META.yml -README -t/001_use.t -t/002_parse_wsdl.t -t/002_sax.t -t/003_sax_serializer.t -t/003_wsdl_based_serializer.t -t/004_parse_wsdl.t -t/004_sax_wsdl.t -t/005_parse_contributed.t -t/005_sax_contributed_wsdl.t -t/006_client.t -t/007_envelope.t -t/008_client_wsdl_complexType.t -t/009_data_classes.t -t/011_simpleType.t -t/012_element.t -t/013_complexType.t -t/014_sax_typelib.t -t/015_to_typemap.t -t/016_client_object.t -t/017_generator_expat.t -t/017_generator_libxml.t -t/018_generator_expat.t -t/018_generator_libxml.t -t/020_storable.t -t/021_generator_element_ref_expat.t -t/021_generator_element_ref_libxml.t -t/098_pod.t -t/acceptance/results/03_complexType-all.xml -t/acceptance/results/03_complexType-sequence.xml -t/acceptance/results/04_element-simpleType.xml -t/acceptance/results/04_element.xml -t/acceptance/results/05_simpleType-list.xml -t/acceptance/results/05_simpleType-restriction.xml -t/acceptance/results/05_simpleType-union.xml -t/acceptance/results/11_helloworld.xml -t/acceptance/wsdl/006_sax_client.wsdl -t/acceptance/wsdl/008_complexType.wsdl -t/acceptance/wsdl/02_port.wsdl -t/acceptance/wsdl/03_complexType-all.wsdl -t/acceptance/wsdl/03_complexType-element-ref.wsdl -t/acceptance/wsdl/03_complexType-sequence.wsdl -t/acceptance/wsdl/04_element-simpleType.wsdl -t/acceptance/wsdl/04_element.wsdl -t/acceptance/wsdl/05_simpleType-list.wsdl -t/acceptance/wsdl/05_simpleType-restriction.wsdl -t/acceptance/wsdl/05_simpleType-union.wsdl -t/acceptance/wsdl/10_helloworld.asmx.xml -t/acceptance/wsdl/11_helloworld.wsdl -t/acceptance/wsdl/contributed/Axis.wsdl -t/acceptance/wsdl/contributed/ETest.wsdl -t/acceptance/wsdl/contributed/OITest.wsdl -t/acceptance/wsdl/contributed/tools.wsdl -t/acceptance/wsdl/email_account.wsdl -t/Expat/01_expat.t -t/Expat/02_sub_parser.t -t/Expat/03_wsdl.t -t/lib/MyComplexType.pm -t/lib/MyElement.pm -t/lib/MySimpleType.pm -t/lib/Test/SOAPMessage.pm -t/lib/Typelib/Base.pm -t/lib/Typelib/TEnqueueMessage.pm -t/lib/Typelib/TMessage.pm -t/SOAP/WSDL/01_use.t -t/SOAP/WSDL/02_port.t -t/SOAP/WSDL/03_complexType-all.t -t/SOAP/WSDL/03_complexType-choice.t -t/SOAP/WSDL/03_complexType-complexContent.t -t/SOAP/WSDL/03_complexType-element-ref.t -t/SOAP/WSDL/03_complexType-group.t -t/SOAP/WSDL/03_complexType-sequence.t -t/SOAP/WSDL/03_complexType-simpleContent.t -t/SOAP/WSDL/04_element-complexType.t -t/SOAP/WSDL/04_element-simpleType.t -t/SOAP/WSDL/04_element.t -t/SOAP/WSDL/05_simpleType-list.t -t/SOAP/WSDL/05_simpleType-restriction.t -t/SOAP/WSDL/05_simpleType-union.t -t/SOAP/WSDL/11_helloworld.NET.t -t/SOAP/WSDL/12_binding.pl -t/SOAP/WSDL/XSD/Typelib/Builtin/001_string.t -t/SOAP/WSDL/XSD/Typelib/Builtin/002_dateTime.t -t/SOAP/WSDL/XSD/Typelib/Builtin/003_date.t -TODO +benchmark/01_expat.t +benchmark/XSD/01_anyType.t +benchmark/XSD/02_anySimpleType.t +benchmark/XSD/03_string.t +bin/wsdl2perl.pl +Build.PL +CHANGES +example/fortune.pl +example/lib/MyElements/CountCookies.pm +example/lib/MyElements/CountCookiesResponse.pm +example/lib/MyElements/GetCitiesByCountry.pm +example/lib/MyElements/GetCitiesByCountryResponse.pm +example/lib/MyElements/GetFortuneCookie.pm +example/lib/MyElements/GetFortuneCookieResponse.pm +example/lib/MyElements/GetSpecificCookie.pm +example/lib/MyElements/GetSpecificCookieResponse.pm +example/lib/MyElements/GetWeather.pm +example/lib/MyElements/GetWeatherResponse.pm +example/lib/MyElements/int.pm +example/lib/MyElements/readNodeCount.pm +example/lib/MyElements/readNodeCountResponse.pm +example/lib/MyElements/string.pm +example/lib/MyInterfaces/FullerData_x0020_Fortune_x0020_Cookie.pm +example/lib/MyInterfaces/GlobalWeather.pm +example/lib/MyTypemaps/FullerData_x0020_Fortune_x0020_Cookie.pm +example/lib/MyTypemaps/GlobalWeather.pm +example/weather.pl +example/weather_wsdl.pl +example/wsdl/FortuneCookie.xml +example/wsdl/genericbarcode.xml +example/wsdl/globalweather.xml +HACKING +lib/SOAP/WSDL.pm +lib/SOAP/WSDL/Base.pm +lib/SOAP/WSDL/Binding.pm +lib/SOAP/WSDL/Client.pm +lib/SOAP/WSDL/Client/Base.pm +lib/SOAP/WSDL/Definitions.pm +lib/SOAP/WSDL/Deserializer/SOAP11.pm +lib/SOAP/WSDL/Deserializer/SOM.pm +lib/SOAP/WSDL/Expat/MessageParser.pm +lib/SOAP/WSDL/Expat/MessageStreamParser.pm +lib/SOAP/WSDL/Expat/MessageSubParser.pm +lib/SOAP/WSDL/Expat/SubParser.pm +lib/SOAP/WSDL/Expat/WSDLParser.pm +lib/SOAP/WSDL/Factory/Deserializer.pm +lib/SOAP/WSDL/Factory/Serializer.pm +lib/SOAP/WSDL/Factory/Transport.pm +lib/SOAP/WSDL/Manual.pod +lib/SOAP/WSDL/Manual/Glossary.pod +lib/SOAP/WSDL/Manual/WS_I.pod +lib/SOAP/WSDL/Message.pm +lib/SOAP/WSDL/Operation.pm +lib/SOAP/WSDL/OpMessage.pm +lib/SOAP/WSDL/Parser.pod +lib/SOAP/WSDL/Part.pm +lib/SOAP/WSDL/Port.pm +lib/SOAP/WSDL/PortType.pm +lib/SOAP/WSDL/SAX/MessageHandler.pm +lib/SOAP/WSDL/SAX/WSDLHandler.pm +lib/SOAP/WSDL/Serializer/SOAP11.pm +lib/SOAP/WSDL/Service.pm +lib/SOAP/WSDL/SOAP/Typelib/Fault11.pm +lib/SOAP/WSDL/SoapOperation.pm +lib/SOAP/WSDL/Transport/HTTP.pm +lib/SOAP/WSDL/TypeLookup.pm +lib/SOAP/WSDL/Types.pm +lib/SOAP/WSDL/XSD/Builtin.pm +lib/SOAP/WSDL/XSD/ComplexType.pm +lib/SOAP/WSDL/XSD/Element.pm +lib/SOAP/WSDL/XSD/Schema.pm +lib/SOAP/WSDL/XSD/Schema/Builtin.pm +lib/SOAP/WSDL/XSD/SimpleType.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/anySimpleType.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/anyType.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/anyURI.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/base64Binary.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/boolean.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/byte.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/date.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/dateTime.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/decimal.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/double.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/duration.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/ENTITY.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/float.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/gDay.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/gMonth.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/gMonthDay.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/gYear.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/gYearMonth.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/hexBinary.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/ID.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/IDREF.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/IDREFS.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/int.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/integer.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/language.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/list.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/long.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/Name.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/NCName.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/negativeInteger.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/NMTOKEN.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/NMTOKENS.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/nonNegativeInteger.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/nonPositiveInteger.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/normalizedString.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/NOTATION.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/positiveInteger.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/QName.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/short.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/string.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/time.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/token.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/unsignedByte.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/unsignedInt.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/unsignedLong.pm +lib/SOAP/WSDL/XSD/Typelib/Builtin/unsignedShort.pm +lib/SOAP/WSDL/XSD/Typelib/ComplexType.pm +lib/SOAP/WSDL/XSD/Typelib/Element.pm +lib/SOAP/WSDL/XSD/Typelib/SimpleType.pm +LICENSE +Makefile.PL +MANIFEST This list of files +META.yml +README +t/001_use.t +t/002_parse_wsdl.t +t/002_sax.t +t/003_sax_serializer.t +t/003_wsdl_based_serializer.t +t/004_parse_wsdl.t +t/004_sax_wsdl.t +t/005_parse_contributed.t +t/005_sax_contributed_wsdl.t +t/006_client.t +t/007_envelope.t +t/008_client_wsdl_complexType.t +t/009_data_classes.t +t/011_simpleType.t +t/012_element.t +t/013_complexType.t +t/014_sax_typelib.t +t/015_to_typemap.t +t/016_client_object.t +t/017_generator_expat.t +t/017_generator_libxml.t +t/018_generator_expat.t +t/018_generator_libxml.t +t/020_storable.t +t/021_generator_element_ref_expat.t +t/021_generator_element_ref_libxml.t +t/098_pod.t +t/acceptance/results/03_complexType-all.xml +t/acceptance/results/03_complexType-sequence.xml +t/acceptance/results/04_element-simpleType.xml +t/acceptance/results/04_element.xml +t/acceptance/results/05_simpleType-list.xml +t/acceptance/results/05_simpleType-restriction.xml +t/acceptance/results/05_simpleType-union.xml +t/acceptance/results/11_helloworld.xml +t/acceptance/wsdl/006_sax_client.wsdl +t/acceptance/wsdl/008_complexType.wsdl +t/acceptance/wsdl/02_port.wsdl +t/acceptance/wsdl/03_complexType-all.wsdl +t/acceptance/wsdl/03_complexType-element-ref.wsdl +t/acceptance/wsdl/03_complexType-sequence.wsdl +t/acceptance/wsdl/04_element-simpleType.wsdl +t/acceptance/wsdl/04_element.wsdl +t/acceptance/wsdl/05_simpleType-list.wsdl +t/acceptance/wsdl/05_simpleType-restriction.wsdl +t/acceptance/wsdl/05_simpleType-union.wsdl +t/acceptance/wsdl/10_helloworld.asmx.xml +t/acceptance/wsdl/11_helloworld.wsdl +t/acceptance/wsdl/contributed/Axis.wsdl +t/acceptance/wsdl/contributed/ETest.wsdl +t/acceptance/wsdl/contributed/OITest.wsdl +t/acceptance/wsdl/contributed/tools.wsdl +t/acceptance/wsdl/email_account.wsdl +t/Expat/01_expat.t +t/Expat/02_sub_parser.t +t/Expat/03_wsdl.t +t/lib/MyComplexType.pm +t/lib/MyElement.pm +t/lib/MySimpleType.pm +t/lib/Test/SOAPMessage.pm +t/lib/Typelib/Base.pm +t/lib/Typelib/TEnqueueMessage.pm +t/lib/Typelib/TMessage.pm +t/SOAP/WSDL/01_use.t +t/SOAP/WSDL/02_port.t +t/SOAP/WSDL/03_complexType-all.t +t/SOAP/WSDL/03_complexType-choice.t +t/SOAP/WSDL/03_complexType-complexContent.t +t/SOAP/WSDL/03_complexType-element-ref.t +t/SOAP/WSDL/03_complexType-group.t +t/SOAP/WSDL/03_complexType-sequence.t +t/SOAP/WSDL/03_complexType-simpleContent.t +t/SOAP/WSDL/04_element-complexType.t +t/SOAP/WSDL/04_element-simpleType.t +t/SOAP/WSDL/04_element.t +t/SOAP/WSDL/05_simpleType-list.t +t/SOAP/WSDL/05_simpleType-restriction.t +t/SOAP/WSDL/05_simpleType-union.t +t/SOAP/WSDL/11_helloworld.NET.t +t/SOAP/WSDL/12_binding.pl +t/SOAP/WSDL/XSD/Typelib/Builtin/001_string.t +t/SOAP/WSDL/XSD/Typelib/Builtin/002_dateTime.t +t/SOAP/WSDL/XSD/Typelib/Builtin/003_date.t +t/SOAP/WSDL/XSD/Typelib/Builtin/004_time.t +t/test.pl +TODO diff --git a/META.yml b/META.yml index e60f0ef..838a34d 100644 --- a/META.yml +++ b/META.yml @@ -1,6 +1,6 @@ --- name: SOAP-WSDL -version: 2.00_12 +version: 2.00_13 author: abstract: SOAP with WSDL support license: artistic @@ -23,24 +23,32 @@ meta-spec: provides: SOAP::WSDL: file: lib/SOAP/WSDL.pm - version: 2.00_12 + version: 2.00_13 SOAP::WSDL::Base: file: lib/SOAP/WSDL/Base.pm SOAP::WSDL::Binding: file: lib/SOAP/WSDL/Binding.pm SOAP::WSDL::Client: file: lib/SOAP/WSDL/Client.pm - version: 2.00_12 + version: 2.00_13 SOAP::WSDL::Client::Base: file: lib/SOAP/WSDL/Client/Base.pm SOAP::WSDL::Definitions: file: lib/SOAP/WSDL/Definitions.pm + SOAP::WSDL::Deserializer::SOAP11: + file: lib/SOAP/WSDL/Deserializer/SOAP11.pm + version: 2.00_13 + SOAP::WSDL::Deserializer::SOM: + file: lib/SOAP/WSDL/Deserializer/SOM.pm + version: 2.00_13 SOAP::WSDL::Expat::MessageParser: file: lib/SOAP/WSDL/Expat/MessageParser.pm SOAP::WSDL::Expat::MessageStreamParser: file: lib/SOAP/WSDL/Expat/MessageStreamParser.pm SOAP::WSDL::Expat::MessageSubParser: file: lib/SOAP/WSDL/Expat/MessageSubParser.pm + SOAP::WSDL::Factory::Deserializer: + file: lib/SOAP/WSDL/Factory/Deserializer.pm SOAP::WSDL::Factory::Serializer: file: lib/SOAP/WSDL/Factory/Serializer.pm SOAP::WSDL::Factory::Transport: @@ -63,6 +71,7 @@ provides: file: lib/SOAP/WSDL/SOAP/Typelib/Fault11.pm SOAP::WSDL::Serializer::SOAP11: file: lib/SOAP/WSDL/Serializer/SOAP11.pm + version: 2.00_13 SOAP::WSDL::Service: file: lib/SOAP/WSDL/Service.pm SOAP::WSDL::SoapOperation: diff --git a/README b/README index 92b9c61..d7e76c8 100644 --- a/README +++ b/README @@ -1,26 +1,26 @@ -INTRO ------ - -SOAP-WSDL provides a SOAP client with WSDL support. - +INTRO +----- + +SOAP-WSDL provides a SOAP client with WSDL support. + This is a developer release - everything may (and most things will) change. - -INSTALLING ----------- - -Use the following mantra: - - perl Build.PL - perl Build - perl Build test - perl Build install - -If you don't have Module::Build installed, you may also use - - perl Makefile.PL - make - make test - make install - -Note that Module::Build is the recommended installer - make will not run + +INSTALLING +---------- + +Use the following mantra: + + perl Build.PL + perl Build + perl Build test + perl Build install + +If you don't have Module::Build installed, you may also use + + perl Makefile.PL + make + make test + make install + +Note that Module::Build is the recommended installer - make will not run all tests provided with SOAP-WSDL. \ No newline at end of file diff --git a/TODO b/TODO index 793436a..79be6dd 100644 --- a/TODO +++ b/TODO @@ -1,35 +1,36 @@ -TODO list for SOAP::WSDL - -2.00 Pre-releases --------- -* SOAP Header support (#1764845) - -* Implement a interface similar to SOAP::Schema (#1783639) - -* (#1785195) Support deserializer plugins - * Support XML::Compiled as one serializer/deserializer - -* Check & probably fix simpleType support. -The WS at http://www.webservicex.net/genericbarcode.asmx?wsdl should -make up a good example for simpleType definitions. - -* Remove benchmarks from test. Create benchmark/ directory to store benchmarks. - -* write inheritance Test for all XSD::Typelib::Builtin::* classes - -* support embedded atomic types (#1761532) -Implement by including a second (and third and fourth) - -package type_prefix::complex_type::element_name; - -element package. -Maybe even allow unlimited depth? What does the specs say? - -2.1 release --------- - - -Past 2.1 release --------- -* XML schema support ("minimal conformant") (#1764845) -* Support SOAP attachments \ No newline at end of file +TODO list for SOAP::WSDL + +2.00 Pre-releases +-------- +* SOAP Header support (#1764845) + +* Implement a interface similar to SOAP::Schema (#1783639) + +* Check & probably fix simpleType support. +The WS at http://www.webservicex.net/genericbarcode.asmx?wsdl should +make up a good example for simpleType definitions. + +* Remove benchmarks from test. Create benchmark/ directory to store benchmarks. + +* write inheritance Test for all XSD::Typelib::Builtin::* classes + +* support embedded atomic types (#1761532) +Implement by including a second (and third and fourth) + +package type_prefix::complex_type::element_name; + +element package. +Maybe even allow unlimited depth? What does the specs say? + +2.1 release +-------- + + +2.2 release +-------- +* XML schema support ("minimal conformant") (#1764845) +* Support SOAP attachments + +3.0 release +-------- +We're not thinking that far ahead right now. \ No newline at end of file diff --git a/benchmark/01_expat.t b/benchmark/01_expat.t index edbf5d6..6a740eb 100644 --- a/benchmark/01_expat.t +++ b/benchmark/01_expat.t @@ -5,10 +5,10 @@ use lib '../lib'; use lib 'lib'; use lib '../t/lib'; use SOAP::WSDL::SAX::MessageHandler; - -use Benchmark; + +use Benchmark; use SOAP::WSDL::Expat::MessageParser; -use XML::Simple; +use XML::Simple; use XML::LibXML; use MyComplexType; use MyElement; @@ -18,32 +18,32 @@ my $xml = q{ Test - Test2 + Test2 }; - + my $parser = SOAP::WSDL::Expat::MessageParser->new({ class_resolver => 'FakeResolver' }); - -$XML::Simple::PREFERRED_PARSER = 'XML::Parser'; - -my $libxml = XML::LibXML->new(); - -timethese 1000, -{ - 'SOAP::WSDL' => sub { $parser->parse( $xml ) }, + +$XML::Simple::PREFERRED_PARSER = 'XML::Parser'; + +my $libxml = XML::LibXML->new(); + +timethese 1000, +{ + 'SOAP::WSDL' => sub { $parser->parse( $xml ) }, #'XML::Simple (Hash)' => sub { XMLin $xml }, - 'XML::LibXML (DOM)' => sub { my $dom = $libxml->parse_string( $xml ) }, -}; - + 'XML::LibXML (DOM)' => sub { my $dom = $libxml->parse_string( $xml ) }, +}; + use Test::More tests => 1; is $parser->get_data(), q{} . q{TestTest2} - , 'Content comparison'; - + , 'Content comparison'; + $parser->class_resolver( 'FakeResolver2' ); - + # data classes reside in t/lib/Typelib/ BEGIN { @@ -54,8 +54,8 @@ BEGIN { 'MyAtomicComplexTypeElement/test' => 'MyTestElement', 'MyAtomicComplexTypeElement/test2' => 'MyTestElement2', ); - - sub get_map { return \%class_list }; + + sub get_map { return \%class_list }; sub new { return bless {}, 'FakeResolver' }; @@ -65,4 +65,4 @@ BEGIN { : warn "no class found for $name"; }; }; -}; +}; diff --git a/benchmark/XSD/01_anyType.t b/benchmark/XSD/01_anyType.t new file mode 100644 index 0000000..a4ef438 --- /dev/null +++ b/benchmark/XSD/01_anyType.t @@ -0,0 +1,21 @@ +use strict; +use warnings; +use Benchmark; +use lib '../../lib'; +use SOAP::WSDL::XSD::Typelib::Builtin::anyType; + +my $obj = SOAP::WSDL::XSD::Typelib::Builtin::anyType->new(); + +timethese 10000, { + 'new' => sub { SOAP::WSDL::XSD::Typelib::Builtin::anyType->new() }, + 'new with params' => sub { SOAP::WSDL::XSD::Typelib::Builtin::anyType->new({ + xmlns => 'urn:Test' + }) }, + 'set_FOO' => sub { $obj->set_xmlns('Test') }, +}; + +my $data; +timethese 1000000, { + 'set_FOO' => sub { $obj->set_xmlns('Test') }, + 'get_FOO' => sub { $data = $obj->get_xmlns() }, +}; diff --git a/benchmark/XSD/02_anySimpleType.t b/benchmark/XSD/02_anySimpleType.t new file mode 100644 index 0000000..5a1e09c --- /dev/null +++ b/benchmark/XSD/02_anySimpleType.t @@ -0,0 +1,22 @@ +use strict; +use warnings; +use Benchmark; +use lib '../../lib'; +use SOAP::WSDL::XSD::Typelib::Builtin::anySimpleType; + +my $obj = SOAP::WSDL::XSD::Typelib::Builtin::anySimpleType->new(); + +timethese 10000, { + 'new' => sub { SOAP::WSDL::XSD::Typelib::Builtin::anySimpleType->new() }, + 'new + params' => sub { SOAP::WSDL::XSD::Typelib::Builtin::anySimpleType->new({ + xmlns => 'urn:Test', + value => 'Teststring' + }) }, + 'set_FOO' => sub { $obj->set_xmlns('Test') }, +}; + +my $data; +timethese 1000000, { + 'set_FOO' => sub { $obj->set_xmlns('Test') }, + 'get_FOO' => sub { $data = $obj->get_xmlns() }, +}; diff --git a/benchmark/XSD/03_string.t b/benchmark/XSD/03_string.t new file mode 100644 index 0000000..5bd4e49 --- /dev/null +++ b/benchmark/XSD/03_string.t @@ -0,0 +1,22 @@ +use strict; +use warnings; +use Benchmark; +use lib '../../lib'; +use SOAP::WSDL::XSD::Typelib::Builtin::string; + +my $obj = SOAP::WSDL::XSD::Typelib::Builtin::string->new(); + +timethese 10000, { + 'new' => sub { SOAP::WSDL::XSD::Typelib::Builtin::string->new() }, + 'new + params' => sub { SOAP::WSDL::XSD::Typelib::Builtin::string->new({ + xmlns => 'urn:Test', + value => 'Teststring' + }) }, + 'set_FOO' => sub { $obj->set_xmlns('Test') }, +}; + +my $data; +timethese 1000000, { + 'set_FOO' => sub { $obj->set_xmlns('Test') }, + 'get_FOO' => sub { $data = $obj->get_xmlns() }, +}; diff --git a/bin/wsdl2perl.pl b/bin/wsdl2perl.pl index 5b57121..1448355 100644 --- a/bin/wsdl2perl.pl +++ b/bin/wsdl2perl.pl @@ -1,125 +1,125 @@ -#!/usr/bin/perl -w -use strict; -use warnings; -use Pod::Usage; -use Getopt::Long; -use LWP::UserAgent; -use SOAP::WSDL::Expat::WSDLParser; - -my %opt = ( - url => '', - prefix => undef, - type_prefix => 'MyTypes::', - element_prefix => 'MyElements::', - typemap_prefix => 'MyTypemaps::', - interface_prefix => 'MyInterfaces::', - base_path => 'lib/', - proxy => undef -); - -GetOptions(\%opt, - qw( - url|u=s - prefix|p=s - type_prefix|t=s - element_prefix|e=s - typemap_prefix|m=s - base_path|b=s - typemap_include|mi=s - help|h - proxy|x=s - ) -); - -my $url = $ARGV[0]; - -pod2usage( -exit => 1 , verbose => 2 ) if ($opt{help}); -pod2usage( -exit => 1 , verbose => 1 ) if not ($url); - -my $parser = SOAP::WSDL::Expat::WSDLParser->new(); - -local $ENV{HTTP_PROXY} = $opt{proxy} if $opt{proxy}; -my $lwp = LWP::UserAgent->new(); -my $response = $lwp->get($url); -die $response->message(), "\n" if $response->code != 200; - -my $xml = $response->content(); - -my $wsdl = $parser->parse_string( $xml ); - -if ($opt{typemap_include}) { - open my $fh , $opt{typemap_include} - or die "cannot open typemap_include file $opt{typemap_include}\n"; - $opt{custom_types} .= join q{}, <$fh>; - close $fh; - delete $opt{typemap_include}; -} - -$wsdl->create({ %opt }); - -=pod - -=head1 NAME - -wsdl2perl.pl - create perl bindings for SOAP webservices. - -=head1 SYNOPSIS - - wsdl2perl.pl -t TYPE_PREFIX -e ELEMENT_PREFIX -m TYPEMAP_PREFIX \ - -i INTERFACE_PREFIX -b BASE_DIR URL - -=head1 OPTIONS - - NAME SHORT DESCRITPION - ---------------------------------------------------------------------------- - prefix p Prefix for both type and element classes. - type_prefix t Prefix for type classes. Should end with '::' - Default: MyTypes:: - element_prefix e Prefix for element classes. Should end with '::' - Default: MyElements:: - typemap_prefix m Prefix for typemap classes. Should end with '::' - Default: MyTypemaps:: - interface_prefix i Prefix for interface classes. Should end with '::' - Default: MyInterfaces:: - base_path b Path to create classes in. - Default: ./lib - typemap_include mi File to include in typemap. - help h Show help content - -=head1 DESCRIPTION - -Generates a interface class for a SOAP web service described by a WSDL -definition. - -The following classes are created: - -=over - -=item * A interface class for every service - -Interface classes are what you will mainly deal with: They provide a method -for accessing every web service method. - -=item * A typemap for every service - -Typemaps are used internally by SOAP::WSDL for parsing the SOAP message into -object trees. - -If the WSDL definition is incomplete, you may need to add some lines to -your typemap. Especially definitions for faults are sometimes left out. - -Additional typemap content may be included by passing a file name as -typemap_include (mi) option. - -=item * A type class for every element, complexType or simpleType definition - -You may need to write additional type classes if your WSDL is incomplete. - -For writing your own lib classes, see L, +#!/usr/bin/perl -w +use strict; +use warnings; +use Pod::Usage; +use Getopt::Long; +use LWP::UserAgent; +use SOAP::WSDL::Expat::WSDLParser; + +my %opt = ( + url => '', + prefix => undef, + type_prefix => 'MyTypes::', + element_prefix => 'MyElements::', + typemap_prefix => 'MyTypemaps::', + interface_prefix => 'MyInterfaces::', + base_path => 'lib/', + proxy => undef +); + +GetOptions(\%opt, + qw( + url|u=s + prefix|p=s + type_prefix|t=s + element_prefix|e=s + typemap_prefix|m=s + base_path|b=s + typemap_include|mi=s + help|h + proxy|x=s + ) +); + +my $url = $ARGV[0]; + +pod2usage( -exit => 1 , verbose => 2 ) if ($opt{help}); +pod2usage( -exit => 1 , verbose => 1 ) if not ($url); + +my $parser = SOAP::WSDL::Expat::WSDLParser->new(); + +local $ENV{HTTP_PROXY} = $opt{proxy} if $opt{proxy}; +my $lwp = LWP::UserAgent->new(); +my $response = $lwp->get($url); +die $response->message(), "\n" if $response->code != 200; + +my $xml = $response->content(); + +my $wsdl = $parser->parse_string( $xml ); + +if ($opt{typemap_include}) { + open my $fh , $opt{typemap_include} + or die "cannot open typemap_include file $opt{typemap_include}\n"; + $opt{custom_types} .= join q{}, <$fh>; + close $fh; + delete $opt{typemap_include}; +} + +$wsdl->create({ %opt }); + +=pod + +=head1 NAME + +wsdl2perl.pl - create perl bindings for SOAP webservices. + +=head1 SYNOPSIS + + wsdl2perl.pl -t TYPE_PREFIX -e ELEMENT_PREFIX -m TYPEMAP_PREFIX \ + -i INTERFACE_PREFIX -b BASE_DIR URL + +=head1 OPTIONS + + NAME SHORT DESCRITPION + ---------------------------------------------------------------------------- + prefix p Prefix for both type and element classes. + type_prefix t Prefix for type classes. Should end with '::' + Default: MyTypes:: + element_prefix e Prefix for element classes. Should end with '::' + Default: MyElements:: + typemap_prefix m Prefix for typemap classes. Should end with '::' + Default: MyTypemaps:: + interface_prefix i Prefix for interface classes. Should end with '::' + Default: MyInterfaces:: + base_path b Path to create classes in. + Default: ./lib + typemap_include mi File to include in typemap. + help h Show help content + +=head1 DESCRIPTION + +Generates a interface class for a SOAP web service described by a WSDL +definition. + +The following classes are created: + +=over + +=item * A interface class for every service + +Interface classes are what you will mainly deal with: They provide a method +for accessing every web service method. + +=item * A typemap for every service + +Typemaps are used internally by SOAP::WSDL for parsing the SOAP message into +object trees. + +If the WSDL definition is incomplete, you may need to add some lines to +your typemap. Especially definitions for faults are sometimes left out. + +Additional typemap content may be included by passing a file name as +typemap_include (mi) option. + +=item * A type class for every element, complexType or simpleType definition + +You may need to write additional type classes if your WSDL is incomplete. + +For writing your own lib classes, see L, L and L. - -=back - + +=back + =head1 LICENSE Copyright 2007 Martin Kutter. diff --git a/example/fortune.pl b/example/fortune.pl index 8a20e18..3a52148 100644 --- a/example/fortune.pl +++ b/example/fortune.pl @@ -1,47 +1,47 @@ -# Accessing the fortune cookie service at -# www.fullerdata.com/FortuneCookie/FortuneCookie.asmx -# -# I have no connection to www.fullerdata.com -# -# Use this script at your own risk. - -# Run before: -# D:\Eigene Dateien\Martin\SOAP-WSDL\trunk>perl -I../lib wsdl2perl.pl "file:///D:/ -# Eigene Dateien/Martin/SOAP-WSDL/trunk/bin/FortuneCookie.xml" - -use lib 'lib/'; -use MyInterfaces::FullerData_x0020_Fortune_x0020_Cookie; -my $cookieService = MyInterfaces::FullerData_x0020_Fortune_x0020_Cookie->new(); - -my $cookie; -$cookie = $cookieService->GetFortuneCookie() - or die "$cookie"; - -print $cookie; # ->get_GetFortuneCookieResult()->get_value, "\n"; - -$cookie = $cookieService->GetSpecificCookie({ index => 23 }) - or die "$cookie"; - -print $cookie->get_GetSpecificCookieResult(), "\n"; - -print $cookie; - - -=for demo: - -# the same in SOAP lite (second call) -# - -use SOAP::Lite; - -my $lite = SOAP::Lite->new()->on_action(sub { join '/', @_ } ) - ->proxy('http://www.fullerdata.com/FortuneCookie/FortuneCookie.asmx'); - -$lite->call( - SOAP::Data->name('GetSpecificCookie') - ->attr({ 'xmlns', 'http://www.fullerdata.com/FortuneCookie/FortuneCookie.asmx' }), - SOAP::Data->name('index')->value(23) - ); - -die $soap->message() if ($soap->fault()); +# Accessing the fortune cookie service at +# www.fullerdata.com/FortuneCookie/FortuneCookie.asmx +# +# I have no connection to www.fullerdata.com +# +# Use this script at your own risk. + +# Run before: +# D:\Eigene Dateien\Martin\SOAP-WSDL\trunk>perl -I../lib wsdl2perl.pl "file:///D:/ +# Eigene Dateien/Martin/SOAP-WSDL/trunk/bin/FortuneCookie.xml" + +use lib 'lib/'; +use MyInterfaces::FullerData_x0020_Fortune_x0020_Cookie; +my $cookieService = MyInterfaces::FullerData_x0020_Fortune_x0020_Cookie->new(); + +my $cookie; +$cookie = $cookieService->GetFortuneCookie() + or die "$cookie"; + +print $cookie; # ->get_GetFortuneCookieResult()->get_value, "\n"; + +$cookie = $cookieService->GetSpecificCookie({ index => 23 }) + or die "$cookie"; + +print $cookie->get_GetSpecificCookieResult(), "\n"; + +print $cookie; + + +=for demo: + +# the same in SOAP lite (second call) +# + +use SOAP::Lite; + +my $lite = SOAP::Lite->new()->on_action(sub { join '/', @_ } ) + ->proxy('http://www.fullerdata.com/FortuneCookie/FortuneCookie.asmx'); + +$lite->call( + SOAP::Data->name('GetSpecificCookie') + ->attr({ 'xmlns', 'http://www.fullerdata.com/FortuneCookie/FortuneCookie.asmx' }), + SOAP::Data->name('index')->value(23) + ); + +die $soap->message() if ($soap->fault()); print $soap->result(); \ No newline at end of file diff --git a/example/lib/MyElements/CountCookies.pm b/example/lib/MyElements/CountCookies.pm index abd3e09..c57423f 100644 --- a/example/lib/MyElements/CountCookies.pm +++ b/example/lib/MyElements/CountCookies.pm @@ -1,71 +1,71 @@ -package MyElements::CountCookies; -use strict; -use Class::Std::Storable; -use SOAP::WSDL::XSD::Typelib::Element; - -# atomic complexType -# definition -use SOAP::WSDL::XSD::Typelib::ComplexType; -use base qw( - SOAP::WSDL::XSD::Typelib::Element - SOAP::WSDL::XSD::Typelib::ComplexType -); - - - -__PACKAGE__->_factory( - [ qw() ], - { - - }, - { - - } -); - - - -sub get_xmlns { 'http://www.fullerdata.com/FortuneCookie/FortuneCookie.asmx' } - -__PACKAGE__->__set_name('CountCookies'); -__PACKAGE__->__set_nillable(); -__PACKAGE__->__set_minOccurs(); -__PACKAGE__->__set_maxOccurs(); -__PACKAGE__->__set_ref(''); - -1; - - -__END__ - -=pod - -=head1 NAME MyElements::CountCookies - -=head1 SYNOPSIS - -=head1 DESCRIPTION - -Type class for the XML element CountCookies. - -=head1 PROPERTIES - -The following properties may be accessed using get_PROPERTY / set_PROPERTY -methods: - - -=head1 Object structure - - -Structure as perl hash: - - The object structure is displayed as hash below though this is not correct. - Complex hash elements actually are objects of their corresponding classes - (look for classes of the same name in your typleib). - new() will accept a hash structure like this, but transform it to a object - tree. - - - -=cut - +package MyElements::CountCookies; +use strict; +use Class::Std::Storable; +use SOAP::WSDL::XSD::Typelib::Element; + +# atomic complexType +# definition +use SOAP::WSDL::XSD::Typelib::ComplexType; +use base qw( + SOAP::WSDL::XSD::Typelib::Element + SOAP::WSDL::XSD::Typelib::ComplexType +); + + + +__PACKAGE__->_factory( + [ qw() ], + { + + }, + { + + } +); + + + +sub get_xmlns { 'http://www.fullerdata.com/FortuneCookie/FortuneCookie.asmx' } + +__PACKAGE__->__set_name('CountCookies'); +__PACKAGE__->__set_nillable(); +__PACKAGE__->__set_minOccurs(); +__PACKAGE__->__set_maxOccurs(); +__PACKAGE__->__set_ref(''); + +1; + + +__END__ + +=pod + +=head1 NAME MyElements::CountCookies + +=head1 SYNOPSIS + +=head1 DESCRIPTION + +Type class for the XML element CountCookies. + +=head1 PROPERTIES + +The following properties may be accessed using get_PROPERTY / set_PROPERTY +methods: + + +=head1 Object structure + + +Structure as perl hash: + + The object structure is displayed as hash below though this is not correct. + Complex hash elements actually are objects of their corresponding classes + (look for classes of the same name in your typleib). + new() will accept a hash structure like this, but transform it to a object + tree. + + + +=cut + diff --git a/example/lib/MyElements/CountCookiesResponse.pm b/example/lib/MyElements/CountCookiesResponse.pm index 6168dc4..93f48d3 100644 --- a/example/lib/MyElements/CountCookiesResponse.pm +++ b/example/lib/MyElements/CountCookiesResponse.pm @@ -1,85 +1,85 @@ -package MyElements::CountCookiesResponse; -use strict; -use Class::Std::Storable; -use SOAP::WSDL::XSD::Typelib::Element; - -# atomic complexType -# definition -use SOAP::WSDL::XSD::Typelib::ComplexType; -use base qw( - SOAP::WSDL::XSD::Typelib::Element - SOAP::WSDL::XSD::Typelib::ComplexType -); - - -my %CountCookiesResult_of :ATTR(:get); - - -__PACKAGE__->_factory( - [ qw( - CountCookiesResult - ) ], - { - CountCookiesResult => \%CountCookiesResult_of, - - }, - { - - CountCookiesResult => 'SOAP::WSDL::XSD::Typelib::Builtin::int', - - - } -); - - - -sub get_xmlns { 'http://www.fullerdata.com/FortuneCookie/FortuneCookie.asmx' } - -__PACKAGE__->__set_name('CountCookiesResponse'); -__PACKAGE__->__set_nillable(); -__PACKAGE__->__set_minOccurs(); -__PACKAGE__->__set_maxOccurs(); -__PACKAGE__->__set_ref(''); - -1; - - -__END__ - -=pod - -=head1 NAME MyElements::CountCookiesResponse - -=head1 SYNOPSIS - -=head1 DESCRIPTION - -Type class for the XML element CountCookiesResponse. - -=head1 PROPERTIES - -The following properties may be accessed using get_PROPERTY / set_PROPERTY -methods: - - CountCookiesResult - -=head1 Object structure - - CountCookiesResult => 'SOAP::WSDL::XSD::Typelib::Builtin::int', - - -Structure as perl hash: - - The object structure is displayed as hash below though this is not correct. - Complex hash elements actually are objects of their corresponding classes - (look for classes of the same name in your typleib). - new() will accept a hash structure like this, but transform it to a object - tree. - - 'CountCookiesResponse'=> { - 'CountCookiesResult' => $someValue, - }, - - -=cut - +package MyElements::CountCookiesResponse; +use strict; +use Class::Std::Storable; +use SOAP::WSDL::XSD::Typelib::Element; + +# atomic complexType +# definition +use SOAP::WSDL::XSD::Typelib::ComplexType; +use base qw( + SOAP::WSDL::XSD::Typelib::Element + SOAP::WSDL::XSD::Typelib::ComplexType +); + + +my %CountCookiesResult_of :ATTR(:get); + + +__PACKAGE__->_factory( + [ qw( + CountCookiesResult + ) ], + { + CountCookiesResult => \%CountCookiesResult_of, + + }, + { + + CountCookiesResult => 'SOAP::WSDL::XSD::Typelib::Builtin::int', + + + } +); + + + +sub get_xmlns { 'http://www.fullerdata.com/FortuneCookie/FortuneCookie.asmx' } + +__PACKAGE__->__set_name('CountCookiesResponse'); +__PACKAGE__->__set_nillable(); +__PACKAGE__->__set_minOccurs(); +__PACKAGE__->__set_maxOccurs(); +__PACKAGE__->__set_ref(''); + +1; + + +__END__ + +=pod + +=head1 NAME MyElements::CountCookiesResponse + +=head1 SYNOPSIS + +=head1 DESCRIPTION + +Type class for the XML element CountCookiesResponse. + +=head1 PROPERTIES + +The following properties may be accessed using get_PROPERTY / set_PROPERTY +methods: + + CountCookiesResult + +=head1 Object structure + + CountCookiesResult => 'SOAP::WSDL::XSD::Typelib::Builtin::int', + + +Structure as perl hash: + + The object structure is displayed as hash below though this is not correct. + Complex hash elements actually are objects of their corresponding classes + (look for classes of the same name in your typleib). + new() will accept a hash structure like this, but transform it to a object + tree. + + 'CountCookiesResponse'=> { + 'CountCookiesResult' => $someValue, + }, + + +=cut + diff --git a/example/lib/MyElements/GetCitiesByCountry.pm b/example/lib/MyElements/GetCitiesByCountry.pm index 0775531..a294ade 100644 --- a/example/lib/MyElements/GetCitiesByCountry.pm +++ b/example/lib/MyElements/GetCitiesByCountry.pm @@ -1,93 +1,93 @@ -package MyElements::GetCitiesByCountry; -use strict; -use Class::Std::Storable; -use SOAP::WSDL::XSD::Typelib::Element; - - -# atomic complexType -# definition -use SOAP::WSDL::XSD::Typelib::ComplexType; -use base qw( - SOAP::WSDL::XSD::Typelib::Element - SOAP::WSDL::XSD::Typelib::ComplexType -); - - -my %CountryName_of :ATTR(:get); - - -__PACKAGE__->_factory( - [ qw( - CountryName - ) ], - { - CountryName => \%CountryName_of, - - }, - { - - CountryName => 'SOAP::WSDL::XSD::Typelib::Builtin::string', - - - } -); - - - -sub get_xmlns { 'http://www.webserviceX.NET' } - -__PACKAGE__->__set_name('GetCitiesByCountry'); -__PACKAGE__->__set_nillable(); -__PACKAGE__->__set_minOccurs(); -__PACKAGE__->__set_maxOccurs(); -__PACKAGE__->__set_ref(''); - -1; - - -__END__ - - - - - - -=pod - -=head1 NAME - -MyElements::GetCitiesByCountry - -=head1 SYNOPSIS - -=head1 DESCRIPTION - -Type class for the XML element GetCitiesByCountry. - -=head1 PROPERTIES - -The following properties may be accessed using get_PROPERTY / set_PROPERTY -methods: - - CountryName - -=head1 Object structure - - CountryName => 'SOAP::WSDL::XSD::Typelib::Builtin::string', - - -Structure as perl hash: - - The object structure is displayed as hash below though this is not correct. - Complex hash elements actually are objects of their corresponding classes - (look for classes of the same name in your typleib). - new() will accept a hash structure like this, but transform it to a object - tree. - - 'GetCitiesByCountry'=> { - 'CountryName' => $someValue, - }, - - -=cut - +package MyElements::GetCitiesByCountry; +use strict; +use Class::Std::Storable; +use SOAP::WSDL::XSD::Typelib::Element; + + +# atomic complexType +# definition +use SOAP::WSDL::XSD::Typelib::ComplexType; +use base qw( + SOAP::WSDL::XSD::Typelib::Element + SOAP::WSDL::XSD::Typelib::ComplexType +); + + +my %CountryName_of :ATTR(:get); + + +__PACKAGE__->_factory( + [ qw( + CountryName + ) ], + { + CountryName => \%CountryName_of, + + }, + { + + CountryName => 'SOAP::WSDL::XSD::Typelib::Builtin::string', + + + } +); + + + +sub get_xmlns { 'http://www.webserviceX.NET' } + +__PACKAGE__->__set_name('GetCitiesByCountry'); +__PACKAGE__->__set_nillable(); +__PACKAGE__->__set_minOccurs(); +__PACKAGE__->__set_maxOccurs(); +__PACKAGE__->__set_ref(''); + +1; + + +__END__ + + + + + + +=pod + +=head1 NAME + +MyElements::GetCitiesByCountry + +=head1 SYNOPSIS + +=head1 DESCRIPTION + +Type class for the XML element GetCitiesByCountry. + +=head1 PROPERTIES + +The following properties may be accessed using get_PROPERTY / set_PROPERTY +methods: + + CountryName + +=head1 Object structure + + CountryName => 'SOAP::WSDL::XSD::Typelib::Builtin::string', + + +Structure as perl hash: + + The object structure is displayed as hash below though this is not correct. + Complex hash elements actually are objects of their corresponding classes + (look for classes of the same name in your typleib). + new() will accept a hash structure like this, but transform it to a object + tree. + + 'GetCitiesByCountry'=> { + 'CountryName' => $someValue, + }, + + +=cut + diff --git a/example/lib/MyElements/GetCitiesByCountryResponse.pm b/example/lib/MyElements/GetCitiesByCountryResponse.pm index 835bf39..7f4e87b 100644 --- a/example/lib/MyElements/GetCitiesByCountryResponse.pm +++ b/example/lib/MyElements/GetCitiesByCountryResponse.pm @@ -1,93 +1,93 @@ -package MyElements::GetCitiesByCountryResponse; -use strict; -use Class::Std::Storable; -use SOAP::WSDL::XSD::Typelib::Element; - - -# atomic complexType -# definition -use SOAP::WSDL::XSD::Typelib::ComplexType; -use base qw( - SOAP::WSDL::XSD::Typelib::Element - SOAP::WSDL::XSD::Typelib::ComplexType -); - - -my %GetCitiesByCountryResult_of :ATTR(:get); - - -__PACKAGE__->_factory( - [ qw( - GetCitiesByCountryResult - ) ], - { - GetCitiesByCountryResult => \%GetCitiesByCountryResult_of, - - }, - { - - GetCitiesByCountryResult => 'SOAP::WSDL::XSD::Typelib::Builtin::string', - - - } -); - - - -sub get_xmlns { 'http://www.webserviceX.NET' } - -__PACKAGE__->__set_name('GetCitiesByCountryResponse'); -__PACKAGE__->__set_nillable(); -__PACKAGE__->__set_minOccurs(); -__PACKAGE__->__set_maxOccurs(); -__PACKAGE__->__set_ref(''); - -1; - - -__END__ - - - - - - -=pod - -=head1 NAME - -MyElements::GetCitiesByCountryResponse - -=head1 SYNOPSIS - -=head1 DESCRIPTION - -Type class for the XML element GetCitiesByCountryResponse. - -=head1 PROPERTIES - -The following properties may be accessed using get_PROPERTY / set_PROPERTY -methods: - - GetCitiesByCountryResult - -=head1 Object structure - - GetCitiesByCountryResult => 'SOAP::WSDL::XSD::Typelib::Builtin::string', - - -Structure as perl hash: - - The object structure is displayed as hash below though this is not correct. - Complex hash elements actually are objects of their corresponding classes - (look for classes of the same name in your typleib). - new() will accept a hash structure like this, but transform it to a object - tree. - - 'GetCitiesByCountryResponse'=> { - 'GetCitiesByCountryResult' => $someValue, - }, - - -=cut - +package MyElements::GetCitiesByCountryResponse; +use strict; +use Class::Std::Storable; +use SOAP::WSDL::XSD::Typelib::Element; + + +# atomic complexType +# definition +use SOAP::WSDL::XSD::Typelib::ComplexType; +use base qw( + SOAP::WSDL::XSD::Typelib::Element + SOAP::WSDL::XSD::Typelib::ComplexType +); + + +my %GetCitiesByCountryResult_of :ATTR(:get); + + +__PACKAGE__->_factory( + [ qw( + GetCitiesByCountryResult + ) ], + { + GetCitiesByCountryResult => \%GetCitiesByCountryResult_of, + + }, + { + + GetCitiesByCountryResult => 'SOAP::WSDL::XSD::Typelib::Builtin::string', + + + } +); + + + +sub get_xmlns { 'http://www.webserviceX.NET' } + +__PACKAGE__->__set_name('GetCitiesByCountryResponse'); +__PACKAGE__->__set_nillable(); +__PACKAGE__->__set_minOccurs(); +__PACKAGE__->__set_maxOccurs(); +__PACKAGE__->__set_ref(''); + +1; + + +__END__ + + + + + + +=pod + +=head1 NAME + +MyElements::GetCitiesByCountryResponse + +=head1 SYNOPSIS + +=head1 DESCRIPTION + +Type class for the XML element GetCitiesByCountryResponse. + +=head1 PROPERTIES + +The following properties may be accessed using get_PROPERTY / set_PROPERTY +methods: + + GetCitiesByCountryResult + +=head1 Object structure + + GetCitiesByCountryResult => 'SOAP::WSDL::XSD::Typelib::Builtin::string', + + +Structure as perl hash: + + The object structure is displayed as hash below though this is not correct. + Complex hash elements actually are objects of their corresponding classes + (look for classes of the same name in your typleib). + new() will accept a hash structure like this, but transform it to a object + tree. + + 'GetCitiesByCountryResponse'=> { + 'GetCitiesByCountryResult' => $someValue, + }, + + +=cut + diff --git a/example/lib/MyElements/GetFortuneCookie.pm b/example/lib/MyElements/GetFortuneCookie.pm index fd6c4d6..a0041e4 100644 --- a/example/lib/MyElements/GetFortuneCookie.pm +++ b/example/lib/MyElements/GetFortuneCookie.pm @@ -1,71 +1,71 @@ -package MyElements::GetFortuneCookie; -use strict; -use Class::Std::Storable; -use SOAP::WSDL::XSD::Typelib::Element; - -# atomic complexType -# definition -use SOAP::WSDL::XSD::Typelib::ComplexType; -use base qw( - SOAP::WSDL::XSD::Typelib::Element - SOAP::WSDL::XSD::Typelib::ComplexType -); - - - -__PACKAGE__->_factory( - [ qw() ], - { - - }, - { - - } -); - - - -sub get_xmlns { 'http://www.fullerdata.com/FortuneCookie/FortuneCookie.asmx' } - -__PACKAGE__->__set_name('GetFortuneCookie'); -__PACKAGE__->__set_nillable(); -__PACKAGE__->__set_minOccurs(); -__PACKAGE__->__set_maxOccurs(); -__PACKAGE__->__set_ref(''); - -1; - - -__END__ - -=pod - -=head1 NAME MyElements::GetFortuneCookie - -=head1 SYNOPSIS - -=head1 DESCRIPTION - -Type class for the XML element GetFortuneCookie. - -=head1 PROPERTIES - -The following properties may be accessed using get_PROPERTY / set_PROPERTY -methods: - - -=head1 Object structure - - -Structure as perl hash: - - The object structure is displayed as hash below though this is not correct. - Complex hash elements actually are objects of their corresponding classes - (look for classes of the same name in your typleib). - new() will accept a hash structure like this, but transform it to a object - tree. - - - -=cut - +package MyElements::GetFortuneCookie; +use strict; +use Class::Std::Storable; +use SOAP::WSDL::XSD::Typelib::Element; + +# atomic complexType +# definition +use SOAP::WSDL::XSD::Typelib::ComplexType; +use base qw( + SOAP::WSDL::XSD::Typelib::Element + SOAP::WSDL::XSD::Typelib::ComplexType +); + + + +__PACKAGE__->_factory( + [ qw() ], + { + + }, + { + + } +); + + + +sub get_xmlns { 'http://www.fullerdata.com/FortuneCookie/FortuneCookie.asmx' } + +__PACKAGE__->__set_name('GetFortuneCookie'); +__PACKAGE__->__set_nillable(); +__PACKAGE__->__set_minOccurs(); +__PACKAGE__->__set_maxOccurs(); +__PACKAGE__->__set_ref(''); + +1; + + +__END__ + +=pod + +=head1 NAME MyElements::GetFortuneCookie + +=head1 SYNOPSIS + +=head1 DESCRIPTION + +Type class for the XML element GetFortuneCookie. + +=head1 PROPERTIES + +The following properties may be accessed using get_PROPERTY / set_PROPERTY +methods: + + +=head1 Object structure + + +Structure as perl hash: + + The object structure is displayed as hash below though this is not correct. + Complex hash elements actually are objects of their corresponding classes + (look for classes of the same name in your typleib). + new() will accept a hash structure like this, but transform it to a object + tree. + + + +=cut + diff --git a/example/lib/MyElements/GetFortuneCookieResponse.pm b/example/lib/MyElements/GetFortuneCookieResponse.pm index 638f15e..571951a 100644 --- a/example/lib/MyElements/GetFortuneCookieResponse.pm +++ b/example/lib/MyElements/GetFortuneCookieResponse.pm @@ -1,85 +1,85 @@ -package MyElements::GetFortuneCookieResponse; -use strict; -use Class::Std::Storable; -use SOAP::WSDL::XSD::Typelib::Element; - -# atomic complexType -# definition -use SOAP::WSDL::XSD::Typelib::ComplexType; -use base qw( - SOAP::WSDL::XSD::Typelib::Element - SOAP::WSDL::XSD::Typelib::ComplexType -); - - -my %GetFortuneCookieResult_of :ATTR(:get); - - -__PACKAGE__->_factory( - [ qw( - GetFortuneCookieResult - ) ], - { - GetFortuneCookieResult => \%GetFortuneCookieResult_of, - - }, - { - - GetFortuneCookieResult => 'SOAP::WSDL::XSD::Typelib::Builtin::string', - - - } -); - - - -sub get_xmlns { 'http://www.fullerdata.com/FortuneCookie/FortuneCookie.asmx' } - -__PACKAGE__->__set_name('GetFortuneCookieResponse'); -__PACKAGE__->__set_nillable(); -__PACKAGE__->__set_minOccurs(); -__PACKAGE__->__set_maxOccurs(); -__PACKAGE__->__set_ref(''); - -1; - - -__END__ - -=pod - -=head1 NAME MyElements::GetFortuneCookieResponse - -=head1 SYNOPSIS - -=head1 DESCRIPTION - -Type class for the XML element GetFortuneCookieResponse. - -=head1 PROPERTIES - -The following properties may be accessed using get_PROPERTY / set_PROPERTY -methods: - - GetFortuneCookieResult - -=head1 Object structure - - GetFortuneCookieResult => 'SOAP::WSDL::XSD::Typelib::Builtin::string', - - -Structure as perl hash: - - The object structure is displayed as hash below though this is not correct. - Complex hash elements actually are objects of their corresponding classes - (look for classes of the same name in your typleib). - new() will accept a hash structure like this, but transform it to a object - tree. - - 'GetFortuneCookieResponse'=> { - 'GetFortuneCookieResult' => $someValue, - }, - - -=cut - +package MyElements::GetFortuneCookieResponse; +use strict; +use Class::Std::Storable; +use SOAP::WSDL::XSD::Typelib::Element; + +# atomic complexType +# definition +use SOAP::WSDL::XSD::Typelib::ComplexType; +use base qw( + SOAP::WSDL::XSD::Typelib::Element + SOAP::WSDL::XSD::Typelib::ComplexType +); + + +my %GetFortuneCookieResult_of :ATTR(:get); + + +__PACKAGE__->_factory( + [ qw( + GetFortuneCookieResult + ) ], + { + GetFortuneCookieResult => \%GetFortuneCookieResult_of, + + }, + { + + GetFortuneCookieResult => 'SOAP::WSDL::XSD::Typelib::Builtin::string', + + + } +); + + + +sub get_xmlns { 'http://www.fullerdata.com/FortuneCookie/FortuneCookie.asmx' } + +__PACKAGE__->__set_name('GetFortuneCookieResponse'); +__PACKAGE__->__set_nillable(); +__PACKAGE__->__set_minOccurs(); +__PACKAGE__->__set_maxOccurs(); +__PACKAGE__->__set_ref(''); + +1; + + +__END__ + +=pod + +=head1 NAME MyElements::GetFortuneCookieResponse + +=head1 SYNOPSIS + +=head1 DESCRIPTION + +Type class for the XML element GetFortuneCookieResponse. + +=head1 PROPERTIES + +The following properties may be accessed using get_PROPERTY / set_PROPERTY +methods: + + GetFortuneCookieResult + +=head1 Object structure + + GetFortuneCookieResult => 'SOAP::WSDL::XSD::Typelib::Builtin::string', + + +Structure as perl hash: + + The object structure is displayed as hash below though this is not correct. + Complex hash elements actually are objects of their corresponding classes + (look for classes of the same name in your typleib). + new() will accept a hash structure like this, but transform it to a object + tree. + + 'GetFortuneCookieResponse'=> { + 'GetFortuneCookieResult' => $someValue, + }, + + +=cut + diff --git a/example/lib/MyElements/GetSpecificCookie.pm b/example/lib/MyElements/GetSpecificCookie.pm index cd26c3d..766438d 100644 --- a/example/lib/MyElements/GetSpecificCookie.pm +++ b/example/lib/MyElements/GetSpecificCookie.pm @@ -1,85 +1,85 @@ -package MyElements::GetSpecificCookie; -use strict; -use Class::Std::Storable; -use SOAP::WSDL::XSD::Typelib::Element; - -# atomic complexType -# definition -use SOAP::WSDL::XSD::Typelib::ComplexType; -use base qw( - SOAP::WSDL::XSD::Typelib::Element - SOAP::WSDL::XSD::Typelib::ComplexType -); - - -my %index_of :ATTR(:get); - - -__PACKAGE__->_factory( - [ qw( - index - ) ], - { - index => \%index_of, - - }, - { - - index => 'SOAP::WSDL::XSD::Typelib::Builtin::int', - - - } -); - - - -sub get_xmlns { 'http://www.fullerdata.com/FortuneCookie/FortuneCookie.asmx' } - -__PACKAGE__->__set_name('GetSpecificCookie'); -__PACKAGE__->__set_nillable(); -__PACKAGE__->__set_minOccurs(); -__PACKAGE__->__set_maxOccurs(); -__PACKAGE__->__set_ref(''); - -1; - - -__END__ - -=pod - -=head1 NAME MyElements::GetSpecificCookie - -=head1 SYNOPSIS - -=head1 DESCRIPTION - -Type class for the XML element GetSpecificCookie. - -=head1 PROPERTIES - -The following properties may be accessed using get_PROPERTY / set_PROPERTY -methods: - - index - -=head1 Object structure - - index => 'SOAP::WSDL::XSD::Typelib::Builtin::int', - - -Structure as perl hash: - - The object structure is displayed as hash below though this is not correct. - Complex hash elements actually are objects of their corresponding classes - (look for classes of the same name in your typleib). - new() will accept a hash structure like this, but transform it to a object - tree. - - 'GetSpecificCookie'=> { - 'index' => $someValue, - }, - - -=cut - +package MyElements::GetSpecificCookie; +use strict; +use Class::Std::Storable; +use SOAP::WSDL::XSD::Typelib::Element; + +# atomic complexType +# definition +use SOAP::WSDL::XSD::Typelib::ComplexType; +use base qw( + SOAP::WSDL::XSD::Typelib::Element + SOAP::WSDL::XSD::Typelib::ComplexType +); + + +my %index_of :ATTR(:get); + + +__PACKAGE__->_factory( + [ qw( + index + ) ], + { + index => \%index_of, + + }, + { + + index => 'SOAP::WSDL::XSD::Typelib::Builtin::int', + + + } +); + + + +sub get_xmlns { 'http://www.fullerdata.com/FortuneCookie/FortuneCookie.asmx' } + +__PACKAGE__->__set_name('GetSpecificCookie'); +__PACKAGE__->__set_nillable(); +__PACKAGE__->__set_minOccurs(); +__PACKAGE__->__set_maxOccurs(); +__PACKAGE__->__set_ref(''); + +1; + + +__END__ + +=pod + +=head1 NAME MyElements::GetSpecificCookie + +=head1 SYNOPSIS + +=head1 DESCRIPTION + +Type class for the XML element GetSpecificCookie. + +=head1 PROPERTIES + +The following properties may be accessed using get_PROPERTY / set_PROPERTY +methods: + + index + +=head1 Object structure + + index => 'SOAP::WSDL::XSD::Typelib::Builtin::int', + + +Structure as perl hash: + + The object structure is displayed as hash below though this is not correct. + Complex hash elements actually are objects of their corresponding classes + (look for classes of the same name in your typleib). + new() will accept a hash structure like this, but transform it to a object + tree. + + 'GetSpecificCookie'=> { + 'index' => $someValue, + }, + + +=cut + diff --git a/example/lib/MyElements/GetSpecificCookieResponse.pm b/example/lib/MyElements/GetSpecificCookieResponse.pm index af90c63..ab29b06 100644 --- a/example/lib/MyElements/GetSpecificCookieResponse.pm +++ b/example/lib/MyElements/GetSpecificCookieResponse.pm @@ -1,85 +1,85 @@ -package MyElements::GetSpecificCookieResponse; -use strict; -use Class::Std::Storable; -use SOAP::WSDL::XSD::Typelib::Element; - -# atomic complexType -# definition -use SOAP::WSDL::XSD::Typelib::ComplexType; -use base qw( - SOAP::WSDL::XSD::Typelib::Element - SOAP::WSDL::XSD::Typelib::ComplexType -); - - -my %GetSpecificCookieResult_of :ATTR(:get); - - -__PACKAGE__->_factory( - [ qw( - GetSpecificCookieResult - ) ], - { - GetSpecificCookieResult => \%GetSpecificCookieResult_of, - - }, - { - - GetSpecificCookieResult => 'SOAP::WSDL::XSD::Typelib::Builtin::string', - - - } -); - - - -sub get_xmlns { 'http://www.fullerdata.com/FortuneCookie/FortuneCookie.asmx' } - -__PACKAGE__->__set_name('GetSpecificCookieResponse'); -__PACKAGE__->__set_nillable(); -__PACKAGE__->__set_minOccurs(); -__PACKAGE__->__set_maxOccurs(); -__PACKAGE__->__set_ref(''); - -1; - - -__END__ - -=pod - -=head1 NAME MyElements::GetSpecificCookieResponse - -=head1 SYNOPSIS - -=head1 DESCRIPTION - -Type class for the XML element GetSpecificCookieResponse. - -=head1 PROPERTIES - -The following properties may be accessed using get_PROPERTY / set_PROPERTY -methods: - - GetSpecificCookieResult - -=head1 Object structure - - GetSpecificCookieResult => 'SOAP::WSDL::XSD::Typelib::Builtin::string', - - -Structure as perl hash: - - The object structure is displayed as hash below though this is not correct. - Complex hash elements actually are objects of their corresponding classes - (look for classes of the same name in your typleib). - new() will accept a hash structure like this, but transform it to a object - tree. - - 'GetSpecificCookieResponse'=> { - 'GetSpecificCookieResult' => $someValue, - }, - - -=cut - +package MyElements::GetSpecificCookieResponse; +use strict; +use Class::Std::Storable; +use SOAP::WSDL::XSD::Typelib::Element; + +# atomic complexType +# definition +use SOAP::WSDL::XSD::Typelib::ComplexType; +use base qw( + SOAP::WSDL::XSD::Typelib::Element + SOAP::WSDL::XSD::Typelib::ComplexType +); + + +my %GetSpecificCookieResult_of :ATTR(:get); + + +__PACKAGE__->_factory( + [ qw( + GetSpecificCookieResult + ) ], + { + GetSpecificCookieResult => \%GetSpecificCookieResult_of, + + }, + { + + GetSpecificCookieResult => 'SOAP::WSDL::XSD::Typelib::Builtin::string', + + + } +); + + + +sub get_xmlns { 'http://www.fullerdata.com/FortuneCookie/FortuneCookie.asmx' } + +__PACKAGE__->__set_name('GetSpecificCookieResponse'); +__PACKAGE__->__set_nillable(); +__PACKAGE__->__set_minOccurs(); +__PACKAGE__->__set_maxOccurs(); +__PACKAGE__->__set_ref(''); + +1; + + +__END__ + +=pod + +=head1 NAME MyElements::GetSpecificCookieResponse + +=head1 SYNOPSIS + +=head1 DESCRIPTION + +Type class for the XML element GetSpecificCookieResponse. + +=head1 PROPERTIES + +The following properties may be accessed using get_PROPERTY / set_PROPERTY +methods: + + GetSpecificCookieResult + +=head1 Object structure + + GetSpecificCookieResult => 'SOAP::WSDL::XSD::Typelib::Builtin::string', + + +Structure as perl hash: + + The object structure is displayed as hash below though this is not correct. + Complex hash elements actually are objects of their corresponding classes + (look for classes of the same name in your typleib). + new() will accept a hash structure like this, but transform it to a object + tree. + + 'GetSpecificCookieResponse'=> { + 'GetSpecificCookieResult' => $someValue, + }, + + +=cut + diff --git a/example/lib/MyElements/GetWeather.pm b/example/lib/MyElements/GetWeather.pm index 283ce3f..0070896 100644 --- a/example/lib/MyElements/GetWeather.pm +++ b/example/lib/MyElements/GetWeather.pm @@ -1,105 +1,105 @@ -package MyElements::GetWeather; -use strict; -use Class::Std::Storable; -use SOAP::WSDL::XSD::Typelib::Element; - - -# atomic complexType -# definition -use SOAP::WSDL::XSD::Typelib::ComplexType; -use base qw( - SOAP::WSDL::XSD::Typelib::Element - SOAP::WSDL::XSD::Typelib::ComplexType -); - - -my %CityName_of :ATTR(:get); - -my %CountryName_of :ATTR(:get); - - -__PACKAGE__->_factory( - [ qw( - CityName - - CountryName - ) ], - { - CityName => \%CityName_of, - CountryName => \%CountryName_of, - - }, - { - - CityName => 'SOAP::WSDL::XSD::Typelib::Builtin::string', - - - CountryName => 'SOAP::WSDL::XSD::Typelib::Builtin::string', - - - } -); - - - -sub get_xmlns { 'http://www.webserviceX.NET' } - -__PACKAGE__->__set_name('GetWeather'); -__PACKAGE__->__set_nillable(); -__PACKAGE__->__set_minOccurs(); -__PACKAGE__->__set_maxOccurs(); -__PACKAGE__->__set_ref(''); - -1; - - -__END__ - - - - - - -=pod - -=head1 NAME - -MyElements::GetWeather - -=head1 SYNOPSIS - -=head1 DESCRIPTION - -Type class for the XML element GetWeather. - -=head1 PROPERTIES - -The following properties may be accessed using get_PROPERTY / set_PROPERTY -methods: - - CityName - CountryName - -=head1 Object structure - - CityName => 'SOAP::WSDL::XSD::Typelib::Builtin::string', - - CountryName => 'SOAP::WSDL::XSD::Typelib::Builtin::string', - - -Structure as perl hash: - - The object structure is displayed as hash below though this is not correct. - Complex hash elements actually are objects of their corresponding classes - (look for classes of the same name in your typleib). - new() will accept a hash structure like this, but transform it to a object - tree. - - 'GetWeather'=> { - 'CityName' => $someValue, - 'CountryName' => $someValue, - }, - - -=cut - +package MyElements::GetWeather; +use strict; +use Class::Std::Storable; +use SOAP::WSDL::XSD::Typelib::Element; + + +# atomic complexType +# definition +use SOAP::WSDL::XSD::Typelib::ComplexType; +use base qw( + SOAP::WSDL::XSD::Typelib::Element + SOAP::WSDL::XSD::Typelib::ComplexType +); + + +my %CityName_of :ATTR(:get); + +my %CountryName_of :ATTR(:get); + + +__PACKAGE__->_factory( + [ qw( + CityName + + CountryName + ) ], + { + CityName => \%CityName_of, + CountryName => \%CountryName_of, + + }, + { + + CityName => 'SOAP::WSDL::XSD::Typelib::Builtin::string', + + + CountryName => 'SOAP::WSDL::XSD::Typelib::Builtin::string', + + + } +); + + + +sub get_xmlns { 'http://www.webserviceX.NET' } + +__PACKAGE__->__set_name('GetWeather'); +__PACKAGE__->__set_nillable(); +__PACKAGE__->__set_minOccurs(); +__PACKAGE__->__set_maxOccurs(); +__PACKAGE__->__set_ref(''); + +1; + + +__END__ + + + + + + +=pod + +=head1 NAME + +MyElements::GetWeather + +=head1 SYNOPSIS + +=head1 DESCRIPTION + +Type class for the XML element GetWeather. + +=head1 PROPERTIES + +The following properties may be accessed using get_PROPERTY / set_PROPERTY +methods: + + CityName + CountryName + +=head1 Object structure + + CityName => 'SOAP::WSDL::XSD::Typelib::Builtin::string', + + CountryName => 'SOAP::WSDL::XSD::Typelib::Builtin::string', + + +Structure as perl hash: + + The object structure is displayed as hash below though this is not correct. + Complex hash elements actually are objects of their corresponding classes + (look for classes of the same name in your typleib). + new() will accept a hash structure like this, but transform it to a object + tree. + + 'GetWeather'=> { + 'CityName' => $someValue, + 'CountryName' => $someValue, + }, + + +=cut + diff --git a/example/lib/MyElements/GetWeatherResponse.pm b/example/lib/MyElements/GetWeatherResponse.pm index 416c300..c259ea1 100644 --- a/example/lib/MyElements/GetWeatherResponse.pm +++ b/example/lib/MyElements/GetWeatherResponse.pm @@ -1,93 +1,93 @@ -package MyElements::GetWeatherResponse; -use strict; -use Class::Std::Storable; -use SOAP::WSDL::XSD::Typelib::Element; - - -# atomic complexType -# definition -use SOAP::WSDL::XSD::Typelib::ComplexType; -use base qw( - SOAP::WSDL::XSD::Typelib::Element - SOAP::WSDL::XSD::Typelib::ComplexType -); - - -my %GetWeatherResult_of :ATTR(:get); - - -__PACKAGE__->_factory( - [ qw( - GetWeatherResult - ) ], - { - GetWeatherResult => \%GetWeatherResult_of, - - }, - { - - GetWeatherResult => 'SOAP::WSDL::XSD::Typelib::Builtin::string', - - - } -); - - - -sub get_xmlns { 'http://www.webserviceX.NET' } - -__PACKAGE__->__set_name('GetWeatherResponse'); -__PACKAGE__->__set_nillable(); -__PACKAGE__->__set_minOccurs(); -__PACKAGE__->__set_maxOccurs(); -__PACKAGE__->__set_ref(''); - -1; - - -__END__ - - - - - - -=pod - -=head1 NAME - -MyElements::GetWeatherResponse - -=head1 SYNOPSIS - -=head1 DESCRIPTION - -Type class for the XML element GetWeatherResponse. - -=head1 PROPERTIES - -The following properties may be accessed using get_PROPERTY / set_PROPERTY -methods: - - GetWeatherResult - -=head1 Object structure - - GetWeatherResult => 'SOAP::WSDL::XSD::Typelib::Builtin::string', - - -Structure as perl hash: - - The object structure is displayed as hash below though this is not correct. - Complex hash elements actually are objects of their corresponding classes - (look for classes of the same name in your typleib). - new() will accept a hash structure like this, but transform it to a object - tree. - - 'GetWeatherResponse'=> { - 'GetWeatherResult' => $someValue, - }, - - -=cut - +package MyElements::GetWeatherResponse; +use strict; +use Class::Std::Storable; +use SOAP::WSDL::XSD::Typelib::Element; + + +# atomic complexType +# definition +use SOAP::WSDL::XSD::Typelib::ComplexType; +use base qw( + SOAP::WSDL::XSD::Typelib::Element + SOAP::WSDL::XSD::Typelib::ComplexType +); + + +my %GetWeatherResult_of :ATTR(:get); + + +__PACKAGE__->_factory( + [ qw( + GetWeatherResult + ) ], + { + GetWeatherResult => \%GetWeatherResult_of, + + }, + { + + GetWeatherResult => 'SOAP::WSDL::XSD::Typelib::Builtin::string', + + + } +); + + + +sub get_xmlns { 'http://www.webserviceX.NET' } + +__PACKAGE__->__set_name('GetWeatherResponse'); +__PACKAGE__->__set_nillable(); +__PACKAGE__->__set_minOccurs(); +__PACKAGE__->__set_maxOccurs(); +__PACKAGE__->__set_ref(''); + +1; + + +__END__ + + + + + + +=pod + +=head1 NAME + +MyElements::GetWeatherResponse + +=head1 SYNOPSIS + +=head1 DESCRIPTION + +Type class for the XML element GetWeatherResponse. + +=head1 PROPERTIES + +The following properties may be accessed using get_PROPERTY / set_PROPERTY +methods: + + GetWeatherResult + +=head1 Object structure + + GetWeatherResult => 'SOAP::WSDL::XSD::Typelib::Builtin::string', + + +Structure as perl hash: + + The object structure is displayed as hash below though this is not correct. + Complex hash elements actually are objects of their corresponding classes + (look for classes of the same name in your typleib). + new() will accept a hash structure like this, but transform it to a object + tree. + + 'GetWeatherResponse'=> { + 'GetWeatherResult' => $someValue, + }, + + +=cut + diff --git a/example/lib/MyElements/int.pm b/example/lib/MyElements/int.pm index 7872abf..51a3f4e 100644 --- a/example/lib/MyElements/int.pm +++ b/example/lib/MyElements/int.pm @@ -1,60 +1,60 @@ -package MyElements::int; -use strict; -use Class::Std::Storable; -use SOAP::WSDL::XSD::Typelib::Element; - -# -# definition -# - -use base qw( - SOAP::WSDL::XSD::Typelib::Element - SOAP::WSDL::XSD::Typelib::Builtin::int -); - - -sub get_xmlns { 'http://www.fullerdata.com/FortuneCookie/FortuneCookie.asmx' } - -__PACKAGE__->__set_name('int'); -__PACKAGE__->__set_nillable(); -__PACKAGE__->__set_minOccurs(); -__PACKAGE__->__set_maxOccurs(); -__PACKAGE__->__set_ref(''); - -1; - - -__END__ - -=pod - -=head1 NAME MyElements::int - -=head1 SYNOPSIS - -=head1 DESCRIPTION - -Type class for the XML element int. - -=head1 PROPERTIES - -The following properties may be accessed using get_PROPERTY / set_PROPERTY -methods: - - -=head1 Object structure - - -Structure as perl hash: - - The object structure is displayed as hash below though this is not correct. - Complex hash elements actually are objects of their corresponding classes - (look for classes of the same name in your typleib). - new() will accept a hash structure like this, but transform it to a object - tree. - - 'int' => $someValue, - - -=cut - +package MyElements::int; +use strict; +use Class::Std::Storable; +use SOAP::WSDL::XSD::Typelib::Element; + +# +# definition +# + +use base qw( + SOAP::WSDL::XSD::Typelib::Element + SOAP::WSDL::XSD::Typelib::Builtin::int +); + + +sub get_xmlns { 'http://www.fullerdata.com/FortuneCookie/FortuneCookie.asmx' } + +__PACKAGE__->__set_name('int'); +__PACKAGE__->__set_nillable(); +__PACKAGE__->__set_minOccurs(); +__PACKAGE__->__set_maxOccurs(); +__PACKAGE__->__set_ref(''); + +1; + + +__END__ + +=pod + +=head1 NAME MyElements::int + +=head1 SYNOPSIS + +=head1 DESCRIPTION + +Type class for the XML element int. + +=head1 PROPERTIES + +The following properties may be accessed using get_PROPERTY / set_PROPERTY +methods: + + +=head1 Object structure + + +Structure as perl hash: + + The object structure is displayed as hash below though this is not correct. + Complex hash elements actually are objects of their corresponding classes + (look for classes of the same name in your typleib). + new() will accept a hash structure like this, but transform it to a object + tree. + + 'int' => $someValue, + + +=cut + diff --git a/example/lib/MyElements/readNodeCount.pm b/example/lib/MyElements/readNodeCount.pm index 995aa8c..405975d 100644 --- a/example/lib/MyElements/readNodeCount.pm +++ b/example/lib/MyElements/readNodeCount.pm @@ -1,71 +1,71 @@ -package MyElements::readNodeCount; -use strict; -use Class::Std::Storable; -use SOAP::WSDL::XSD::Typelib::Element; - -# atomic complexType -# definition -use SOAP::WSDL::XSD::Typelib::ComplexType; -use base qw( - SOAP::WSDL::XSD::Typelib::Element - SOAP::WSDL::XSD::Typelib::ComplexType -); - - - -__PACKAGE__->_factory( - [ qw() ], - { - - }, - { - - } -); - - - -sub get_xmlns { 'http://www.fullerdata.com/FortuneCookie/FortuneCookie.asmx' } - -__PACKAGE__->__set_name('readNodeCount'); -__PACKAGE__->__set_nillable(); -__PACKAGE__->__set_minOccurs(); -__PACKAGE__->__set_maxOccurs(); -__PACKAGE__->__set_ref(''); - -1; - - -__END__ - -=pod - -=head1 NAME MyElements::readNodeCount - -=head1 SYNOPSIS - -=head1 DESCRIPTION - -Type class for the XML element readNodeCount. - -=head1 PROPERTIES - -The following properties may be accessed using get_PROPERTY / set_PROPERTY -methods: - - -=head1 Object structure - - -Structure as perl hash: - - The object structure is displayed as hash below though this is not correct. - Complex hash elements actually are objects of their corresponding classes - (look for classes of the same name in your typleib). - new() will accept a hash structure like this, but transform it to a object - tree. - - - -=cut - +package MyElements::readNodeCount; +use strict; +use Class::Std::Storable; +use SOAP::WSDL::XSD::Typelib::Element; + +# atomic complexType +# definition +use SOAP::WSDL::XSD::Typelib::ComplexType; +use base qw( + SOAP::WSDL::XSD::Typelib::Element + SOAP::WSDL::XSD::Typelib::ComplexType +); + + + +__PACKAGE__->_factory( + [ qw() ], + { + + }, + { + + } +); + + + +sub get_xmlns { 'http://www.fullerdata.com/FortuneCookie/FortuneCookie.asmx' } + +__PACKAGE__->__set_name('readNodeCount'); +__PACKAGE__->__set_nillable(); +__PACKAGE__->__set_minOccurs(); +__PACKAGE__->__set_maxOccurs(); +__PACKAGE__->__set_ref(''); + +1; + + +__END__ + +=pod + +=head1 NAME MyElements::readNodeCount + +=head1 SYNOPSIS + +=head1 DESCRIPTION + +Type class for the XML element readNodeCount. + +=head1 PROPERTIES + +The following properties may be accessed using get_PROPERTY / set_PROPERTY +methods: + + +=head1 Object structure + + +Structure as perl hash: + + The object structure is displayed as hash below though this is not correct. + Complex hash elements actually are objects of their corresponding classes + (look for classes of the same name in your typleib). + new() will accept a hash structure like this, but transform it to a object + tree. + + + +=cut + diff --git a/example/lib/MyElements/readNodeCountResponse.pm b/example/lib/MyElements/readNodeCountResponse.pm index 1ae98f3..f7f769b 100644 --- a/example/lib/MyElements/readNodeCountResponse.pm +++ b/example/lib/MyElements/readNodeCountResponse.pm @@ -1,85 +1,85 @@ -package MyElements::readNodeCountResponse; -use strict; -use Class::Std::Storable; -use SOAP::WSDL::XSD::Typelib::Element; - -# atomic complexType -# definition -use SOAP::WSDL::XSD::Typelib::ComplexType; -use base qw( - SOAP::WSDL::XSD::Typelib::Element - SOAP::WSDL::XSD::Typelib::ComplexType -); - - -my %readNodeCountResult_of :ATTR(:get); - - -__PACKAGE__->_factory( - [ qw( - readNodeCountResult - ) ], - { - readNodeCountResult => \%readNodeCountResult_of, - - }, - { - - readNodeCountResult => 'SOAP::WSDL::XSD::Typelib::Builtin::int', - - - } -); - - - -sub get_xmlns { 'http://www.fullerdata.com/FortuneCookie/FortuneCookie.asmx' } - -__PACKAGE__->__set_name('readNodeCountResponse'); -__PACKAGE__->__set_nillable(); -__PACKAGE__->__set_minOccurs(); -__PACKAGE__->__set_maxOccurs(); -__PACKAGE__->__set_ref(''); - -1; - - -__END__ - -=pod - -=head1 NAME MyElements::readNodeCountResponse - -=head1 SYNOPSIS - -=head1 DESCRIPTION - -Type class for the XML element readNodeCountResponse. - -=head1 PROPERTIES - -The following properties may be accessed using get_PROPERTY / set_PROPERTY -methods: - - readNodeCountResult - -=head1 Object structure - - readNodeCountResult => 'SOAP::WSDL::XSD::Typelib::Builtin::int', - - -Structure as perl hash: - - The object structure is displayed as hash below though this is not correct. - Complex hash elements actually are objects of their corresponding classes - (look for classes of the same name in your typleib). - new() will accept a hash structure like this, but transform it to a object - tree. - - 'readNodeCountResponse'=> { - 'readNodeCountResult' => $someValue, - }, - - -=cut - +package MyElements::readNodeCountResponse; +use strict; +use Class::Std::Storable; +use SOAP::WSDL::XSD::Typelib::Element; + +# atomic complexType +# definition +use SOAP::WSDL::XSD::Typelib::ComplexType; +use base qw( + SOAP::WSDL::XSD::Typelib::Element + SOAP::WSDL::XSD::Typelib::ComplexType +); + + +my %readNodeCountResult_of :ATTR(:get); + + +__PACKAGE__->_factory( + [ qw( + readNodeCountResult + ) ], + { + readNodeCountResult => \%readNodeCountResult_of, + + }, + { + + readNodeCountResult => 'SOAP::WSDL::XSD::Typelib::Builtin::int', + + + } +); + + + +sub get_xmlns { 'http://www.fullerdata.com/FortuneCookie/FortuneCookie.asmx' } + +__PACKAGE__->__set_name('readNodeCountResponse'); +__PACKAGE__->__set_nillable(); +__PACKAGE__->__set_minOccurs(); +__PACKAGE__->__set_maxOccurs(); +__PACKAGE__->__set_ref(''); + +1; + + +__END__ + +=pod + +=head1 NAME MyElements::readNodeCountResponse + +=head1 SYNOPSIS + +=head1 DESCRIPTION + +Type class for the XML element readNodeCountResponse. + +=head1 PROPERTIES + +The following properties may be accessed using get_PROPERTY / set_PROPERTY +methods: + + readNodeCountResult + +=head1 Object structure + + readNodeCountResult => 'SOAP::WSDL::XSD::Typelib::Builtin::int', + + +Structure as perl hash: + + The object structure is displayed as hash below though this is not correct. + Complex hash elements actually are objects of their corresponding classes + (look for classes of the same name in your typleib). + new() will accept a hash structure like this, but transform it to a object + tree. + + 'readNodeCountResponse'=> { + 'readNodeCountResult' => $someValue, + }, + + +=cut + diff --git a/example/lib/MyElements/string.pm b/example/lib/MyElements/string.pm index 8208b0f..b148ea3 100644 --- a/example/lib/MyElements/string.pm +++ b/example/lib/MyElements/string.pm @@ -1,68 +1,68 @@ -package MyElements::string; -use strict; -use Class::Std::Storable; -use SOAP::WSDL::XSD::Typelib::Element; - - -# -# definition -# - -use base qw( - SOAP::WSDL::XSD::Typelib::Element - SOAP::WSDL::XSD::Typelib::Builtin::string -); - - -sub get_xmlns { 'http://www.webserviceX.NET' } - -__PACKAGE__->__set_name('string'); -__PACKAGE__->__set_nillable(true); -__PACKAGE__->__set_minOccurs(); -__PACKAGE__->__set_maxOccurs(); -__PACKAGE__->__set_ref(''); - -1; - - -__END__ - - - - - - -=pod - -=head1 NAME - -MyElements::string - -=head1 SYNOPSIS - -=head1 DESCRIPTION - -Type class for the XML element string. - -=head1 PROPERTIES - -The following properties may be accessed using get_PROPERTY / set_PROPERTY -methods: - - -=head1 Object structure - - -Structure as perl hash: - - The object structure is displayed as hash below though this is not correct. - Complex hash elements actually are objects of their corresponding classes - (look for classes of the same name in your typleib). - new() will accept a hash structure like this, but transform it to a object - tree. - - 'string' => $someValue, - - -=cut - +package MyElements::string; +use strict; +use Class::Std::Storable; +use SOAP::WSDL::XSD::Typelib::Element; + + +# +# definition +# + +use base qw( + SOAP::WSDL::XSD::Typelib::Element + SOAP::WSDL::XSD::Typelib::Builtin::string +); + + +sub get_xmlns { 'http://www.webserviceX.NET' } + +__PACKAGE__->__set_name('string'); +__PACKAGE__->__set_nillable(true); +__PACKAGE__->__set_minOccurs(); +__PACKAGE__->__set_maxOccurs(); +__PACKAGE__->__set_ref(''); + +1; + + +__END__ + + + + + + +=pod + +=head1 NAME + +MyElements::string + +=head1 SYNOPSIS + +=head1 DESCRIPTION + +Type class for the XML element string. + +=head1 PROPERTIES + +The following properties may be accessed using get_PROPERTY / set_PROPERTY +methods: + + +=head1 Object structure + + +Structure as perl hash: + + The object structure is displayed as hash below though this is not correct. + Complex hash elements actually are objects of their corresponding classes + (look for classes of the same name in your typleib). + new() will accept a hash structure like this, but transform it to a object + tree. + + 'string' => $someValue, + + +=cut + diff --git a/example/lib/MyInterfaces/FullerData_x0020_Fortune_x0020_Cookie.pm b/example/lib/MyInterfaces/FullerData_x0020_Fortune_x0020_Cookie.pm index fcc2be9..fab733e 100644 --- a/example/lib/MyInterfaces/FullerData_x0020_Fortune_x0020_Cookie.pm +++ b/example/lib/MyInterfaces/FullerData_x0020_Fortune_x0020_Cookie.pm @@ -1,327 +1,327 @@ -package MyInterfaces::FullerData_x0020_Fortune_x0020_Cookie; -use strict; -use warnings; -use MyTypemaps::FullerData_x0020_Fortune_x0020_Cookie; -use base 'SOAP::WSDL::Client::Base'; - -sub new { - my $class = shift; - my $arg_ref = shift || {}; - my $self = $class->SUPER::new({ - class_resolver => 'MyTypemaps::FullerData_x0020_Fortune_x0020_Cookie', - proxy => 'http://www.fullerdata.com/FortuneCookie/FortuneCookie.asmx', - %{ $arg_ref } - }); - return bless $self, $class; -} - -__PACKAGE__->__create_methods( - GetSpecificCookie => [ 'MyElements::GetSpecificCookie', ], - CountCookies => [ 'MyElements::CountCookies', ], - readNodeCount => [ 'MyElements::readNodeCount', ], - GetFortuneCookie => [ 'MyElements::GetFortuneCookie', ], - -); - -1; - -__END__ - -=pod - -=head1 NAME - -MyInterfaces::FullerData_x0020_Fortune_x0020_Cookie - SOAP interface to FullerData_x0020_Fortune_x0020_Cookie at -http://www.fullerdata.com/FortuneCookie/FortuneCookie.asmx - -=head1 SYNOPSIS - - my $interface = MyInterfaces::FullerData_x0020_Fortune_x0020_Cookie->new(); - my $CountCookies = $interface->CountCookies(); - - -=head1 Service FullerData_x0020_Fortune_x0020_Cookie - -=head2 Service information: - - Port name: FullerData_x0020_Fortune_x0020_CookieSoap - Binding: tns:FullerData_x0020_Fortune_x0020_CookieSoap - Location: http://www.fullerdata.com/FortuneCookie/FortuneCookie.asmx - -=head2 SOAP Operations - -B - - Input, output and fault messages are stated as perl hash refs. - - These are only for informational purposes - the actual implementation - normally uses object trees, not hash refs, though the input messages - may be passed to the respective methods as hash refs and will be - converted to object trees automatically. - - -=head3 readNodeCount - -B - - { - } - - -B - - { - } - - -B - - - - -=head3 GetFortuneCookie - -B - - { - } - - -B - - { - } - - -B - - - - -=head3 CountCookies - -B - - { - } - - -B - - { - } - - -B - - - - -=head3 GetSpecificCookie - -B - - { - } - - -B - - { - } - - -B - - - -=head2 Service information: - - Port name: FullerData_x0020_Fortune_x0020_CookieHttpGet - Binding: tns:FullerData_x0020_Fortune_x0020_CookieHttpGet - Location: - -=head2 SOAP Operations - -B - - Input, output and fault messages are stated as perl hash refs. - - These are only for informational purposes - the actual implementation - normally uses object trees, not hash refs, though the input messages - may be passed to the respective methods as hash refs and will be - converted to object trees automatically. - - -=head3 readNodeCount - -B - - { - } - - -B - - { - } - - -B - - - - -=head3 GetFortuneCookie - -B - - { - } - - -B - - { - } - - -B - - - - -=head3 CountCookies - -B - - { - } - - -B - - { - } - - -B - - - - -=head3 GetSpecificCookie - -B - - { - } - - -B - - { - } - - -B - - - -=head2 Service information: - - Port name: FullerData_x0020_Fortune_x0020_CookieHttpPost - Binding: tns:FullerData_x0020_Fortune_x0020_CookieHttpPost - Location: - -=head2 SOAP Operations - -B - - Input, output and fault messages are stated as perl hash refs. - - These are only for informational purposes - the actual implementation - normally uses object trees, not hash refs, though the input messages - may be passed to the respective methods as hash refs and will be - converted to object trees automatically. - - -=head3 readNodeCount - -B - - { - } - - -B - - { - } - - -B - - - - -=head3 GetFortuneCookie - -B - - { - } - - -B - - { - } - - -B - - - - -=head3 CountCookies - -B - - { - } - - -B - - { - } - - -B - - - - -=head3 GetSpecificCookie - -B - - { - } - - -B - - { - } - - -B - - - - - -=cut - +package MyInterfaces::FullerData_x0020_Fortune_x0020_Cookie; +use strict; +use warnings; +use MyTypemaps::FullerData_x0020_Fortune_x0020_Cookie; +use base 'SOAP::WSDL::Client::Base'; + +sub new { + my $class = shift; + my $arg_ref = shift || {}; + my $self = $class->SUPER::new({ + class_resolver => 'MyTypemaps::FullerData_x0020_Fortune_x0020_Cookie', + proxy => 'http://www.fullerdata.com/FortuneCookie/FortuneCookie.asmx', + %{ $arg_ref } + }); + return bless $self, $class; +} + +__PACKAGE__->__create_methods( + GetSpecificCookie => [ 'MyElements::GetSpecificCookie', ], + CountCookies => [ 'MyElements::CountCookies', ], + readNodeCount => [ 'MyElements::readNodeCount', ], + GetFortuneCookie => [ 'MyElements::GetFortuneCookie', ], + +); + +1; + +__END__ + +=pod + +=head1 NAME + +MyInterfaces::FullerData_x0020_Fortune_x0020_Cookie - SOAP interface to FullerData_x0020_Fortune_x0020_Cookie at +http://www.fullerdata.com/FortuneCookie/FortuneCookie.asmx + +=head1 SYNOPSIS + + my $interface = MyInterfaces::FullerData_x0020_Fortune_x0020_Cookie->new(); + my $CountCookies = $interface->CountCookies(); + + +=head1 Service FullerData_x0020_Fortune_x0020_Cookie + +=head2 Service information: + + Port name: FullerData_x0020_Fortune_x0020_CookieSoap + Binding: tns:FullerData_x0020_Fortune_x0020_CookieSoap + Location: http://www.fullerdata.com/FortuneCookie/FortuneCookie.asmx + +=head2 SOAP Operations + +B + + Input, output and fault messages are stated as perl hash refs. + + These are only for informational purposes - the actual implementation + normally uses object trees, not hash refs, though the input messages + may be passed to the respective methods as hash refs and will be + converted to object trees automatically. + + +=head3 readNodeCount + +B + + { + } + + +B + + { + } + + +B + + + + +=head3 GetFortuneCookie + +B + + { + } + + +B + + { + } + + +B + + + + +=head3 CountCookies + +B + + { + } + + +B + + { + } + + +B + + + + +=head3 GetSpecificCookie + +B + + { + } + + +B + + { + } + + +B + + + +=head2 Service information: + + Port name: FullerData_x0020_Fortune_x0020_CookieHttpGet + Binding: tns:FullerData_x0020_Fortune_x0020_CookieHttpGet + Location: + +=head2 SOAP Operations + +B + + Input, output and fault messages are stated as perl hash refs. + + These are only for informational purposes - the actual implementation + normally uses object trees, not hash refs, though the input messages + may be passed to the respective methods as hash refs and will be + converted to object trees automatically. + + +=head3 readNodeCount + +B + + { + } + + +B + + { + } + + +B + + + + +=head3 GetFortuneCookie + +B + + { + } + + +B + + { + } + + +B + + + + +=head3 CountCookies + +B + + { + } + + +B + + { + } + + +B + + + + +=head3 GetSpecificCookie + +B + + { + } + + +B + + { + } + + +B + + + +=head2 Service information: + + Port name: FullerData_x0020_Fortune_x0020_CookieHttpPost + Binding: tns:FullerData_x0020_Fortune_x0020_CookieHttpPost + Location: + +=head2 SOAP Operations + +B + + Input, output and fault messages are stated as perl hash refs. + + These are only for informational purposes - the actual implementation + normally uses object trees, not hash refs, though the input messages + may be passed to the respective methods as hash refs and will be + converted to object trees automatically. + + +=head3 readNodeCount + +B + + { + } + + +B + + { + } + + +B + + + + +=head3 GetFortuneCookie + +B + + { + } + + +B + + { + } + + +B + + + + +=head3 CountCookies + +B + + { + } + + +B + + { + } + + +B + + + + +=head3 GetSpecificCookie + +B + + { + } + + +B + + { + } + + +B + + + + + +=cut + diff --git a/example/lib/MyInterfaces/GlobalWeather.pm b/example/lib/MyInterfaces/GlobalWeather.pm index 634fd72..af188a1 100644 --- a/example/lib/MyInterfaces/GlobalWeather.pm +++ b/example/lib/MyInterfaces/GlobalWeather.pm @@ -1,83 +1,83 @@ -package MyInterfaces::GlobalWeather; - -use strict; -use warnings; -use MyTypemaps::GlobalWeather; -use base 'SOAP::WSDL::Client::Base'; - -sub new { - my $class = shift; - my $arg_ref = shift || {}; - my $self = $class->SUPER::new({ - class_resolver => 'MyTypemaps::GlobalWeather', - proxy => 'http://www.webservicex.net/globalweather.asmx', - %{ $arg_ref } - }); - return bless $self, $class; -} - -__PACKAGE__->__create_methods( - GetWeather => { - parts => [ 'MyElements::GetWeather', ], - soap_action => 'http://www.webserviceX.NET/GetWeather', - style => 'document', - # use => '', # use not implemented yet - }, - GetCitiesByCountry => { - parts => [ 'MyElements::GetCitiesByCountry', ], - soap_action => 'http://www.webserviceX.NET/GetCitiesByCountry', - style => 'document', - # use => '', # use not implemented yet - }, - -); - -1; - -__END__ - - - - - -=pod - -=head1 NAME - -MyInterfaces::GlobalWeather - SOAP interface to GlobalWeather at -http://www.webservicex.net/globalweather.asmx - -=head1 SYNOPSIS - - my $interface = MyInterfaces::GlobalWeather->new(); - my $GetCitiesByCountry = $interface->GetCitiesByCountry(); - - -=head1 METHODS - -=head2 GetWeather - -Get weather report for all major cities around the world. - -SYNOPSIS: - - $service->GetWeather({ - 'CityName' => $someValue, - 'CountryName' => $someValue, - }); - - -=head2 GetCitiesByCountry - -Get all major cities by country name(full / part). - -SYNOPSIS: - - $service->GetCitiesByCountry({ - 'CountryName' => $someValue, - }); - - - -=pod - +package MyInterfaces::GlobalWeather; + +use strict; +use warnings; +use MyTypemaps::GlobalWeather; +use base 'SOAP::WSDL::Client::Base'; + +sub new { + my $class = shift; + my $arg_ref = shift || {}; + my $self = $class->SUPER::new({ + class_resolver => 'MyTypemaps::GlobalWeather', + proxy => 'http://www.webservicex.net/globalweather.asmx', + %{ $arg_ref } + }); + return bless $self, $class; +} + +__PACKAGE__->__create_methods( + GetWeather => { + parts => [ 'MyElements::GetWeather', ], + soap_action => 'http://www.webserviceX.NET/GetWeather', + style => 'document', + # use => '', # use not implemented yet + }, + GetCitiesByCountry => { + parts => [ 'MyElements::GetCitiesByCountry', ], + soap_action => 'http://www.webserviceX.NET/GetCitiesByCountry', + style => 'document', + # use => '', # use not implemented yet + }, + +); + +1; + +__END__ + + + + + +=pod + +=head1 NAME + +MyInterfaces::GlobalWeather - SOAP interface to GlobalWeather at +http://www.webservicex.net/globalweather.asmx + +=head1 SYNOPSIS + + my $interface = MyInterfaces::GlobalWeather->new(); + my $GetCitiesByCountry = $interface->GetCitiesByCountry(); + + +=head1 METHODS + +=head2 GetWeather + +Get weather report for all major cities around the world. + +SYNOPSIS: + + $service->GetWeather({ + 'CityName' => $someValue, + 'CountryName' => $someValue, + }); + + +=head2 GetCitiesByCountry + +Get all major cities by country name(full / part). + +SYNOPSIS: + + $service->GetCitiesByCountry({ + 'CountryName' => $someValue, + }); + + + +=pod + diff --git a/example/lib/MyTypemaps/FullerData_x0020_Fortune_x0020_Cookie.pm b/example/lib/MyTypemaps/FullerData_x0020_Fortune_x0020_Cookie.pm index 2e41302..4859370 100644 --- a/example/lib/MyTypemaps/FullerData_x0020_Fortune_x0020_Cookie.pm +++ b/example/lib/MyTypemaps/FullerData_x0020_Fortune_x0020_Cookie.pm @@ -1,49 +1,49 @@ -package MyTypemaps::FullerData_x0020_Fortune_x0020_Cookie; -use strict; -use warnings; - -my %typemap = ( -'readNodeCount' => 'MyElements::readNodeCount', -'readNodeCountResponse' => 'MyElements::readNodeCountResponse', -# atomic complex type (sequence) -'readNodeCountResponse/readNodeCountResult' => 'SOAP::WSDL::XSD::Typelib::Builtin::int', - -# end atomic complex type (sequence) -'GetFortuneCookie' => 'MyElements::GetFortuneCookie', -'GetFortuneCookieResponse' => 'MyElements::GetFortuneCookieResponse', -# atomic complex type (sequence) -'GetFortuneCookieResponse/GetFortuneCookieResult' => 'SOAP::WSDL::XSD::Typelib::Builtin::string', - -# end atomic complex type (sequence) -'CountCookies' => 'MyElements::CountCookies', -'CountCookiesResponse' => 'MyElements::CountCookiesResponse', -# atomic complex type (sequence) -'CountCookiesResponse/CountCookiesResult' => 'SOAP::WSDL::XSD::Typelib::Builtin::int', - -# end atomic complex type (sequence) -'GetSpecificCookie' => 'MyElements::GetSpecificCookie', -# atomic complex type (sequence) -'GetSpecificCookie/index' => 'SOAP::WSDL::XSD::Typelib::Builtin::int', - -# end atomic complex type (sequence) -'GetSpecificCookieResponse' => 'MyElements::GetSpecificCookieResponse', -# atomic complex type (sequence) -'GetSpecificCookieResponse/GetSpecificCookieResult' => 'SOAP::WSDL::XSD::Typelib::Builtin::string', - -# end atomic complex type (sequence) - - - - -); - -sub get_class { - my $name = join '/', @{ $_[1] }; - exists $typemap{ $name } or die "Cannot resolve $name via " . __PACKAGE__; - return $typemap{ $name }; -} - -1; - -__END__ - +package MyTypemaps::FullerData_x0020_Fortune_x0020_Cookie; +use strict; +use warnings; + +my %typemap = ( +'readNodeCount' => 'MyElements::readNodeCount', +'readNodeCountResponse' => 'MyElements::readNodeCountResponse', +# atomic complex type (sequence) +'readNodeCountResponse/readNodeCountResult' => 'SOAP::WSDL::XSD::Typelib::Builtin::int', + +# end atomic complex type (sequence) +'GetFortuneCookie' => 'MyElements::GetFortuneCookie', +'GetFortuneCookieResponse' => 'MyElements::GetFortuneCookieResponse', +# atomic complex type (sequence) +'GetFortuneCookieResponse/GetFortuneCookieResult' => 'SOAP::WSDL::XSD::Typelib::Builtin::string', + +# end atomic complex type (sequence) +'CountCookies' => 'MyElements::CountCookies', +'CountCookiesResponse' => 'MyElements::CountCookiesResponse', +# atomic complex type (sequence) +'CountCookiesResponse/CountCookiesResult' => 'SOAP::WSDL::XSD::Typelib::Builtin::int', + +# end atomic complex type (sequence) +'GetSpecificCookie' => 'MyElements::GetSpecificCookie', +# atomic complex type (sequence) +'GetSpecificCookie/index' => 'SOAP::WSDL::XSD::Typelib::Builtin::int', + +# end atomic complex type (sequence) +'GetSpecificCookieResponse' => 'MyElements::GetSpecificCookieResponse', +# atomic complex type (sequence) +'GetSpecificCookieResponse/GetSpecificCookieResult' => 'SOAP::WSDL::XSD::Typelib::Builtin::string', + +# end atomic complex type (sequence) + + + + +); + +sub get_class { + my $name = join '/', @{ $_[1] }; + exists $typemap{ $name } or die "Cannot resolve $name via " . __PACKAGE__; + return $typemap{ $name }; +} + +1; + +__END__ + diff --git a/example/lib/MyTypemaps/GlobalWeather.pm b/example/lib/MyTypemaps/GlobalWeather.pm index 888380e..67f07f6 100644 --- a/example/lib/MyTypemaps/GlobalWeather.pm +++ b/example/lib/MyTypemaps/GlobalWeather.pm @@ -1,50 +1,50 @@ -package MyTypemaps::GlobalWeather; -use strict; -use warnings; - -my %typemap = ( -# SOAP 1.1 fault typemap -'Fault' => 'SOAP::WSDL::SOAP::Typelib::Fault11', -'Fault/faultcode' => 'SOAP::WSDL::XSD::Typelib::Builtin::anyURI', -'Fault/faultactor' => 'SOAP::WSDL::XSD::Typelib::Builtin::TOKEN', -'Fault/faultstring' => 'SOAP::WSDL::XSD::Typelib::Builtin::string', -'Fault/detail' => 'SOAP::WSDL::XSD::Typelib::Builtin::string', - -# generated typemap -'GetWeather' => 'MyElements::GetWeather', -# atomic complex type (sequence) -'GetWeather/CityName' => 'SOAP::WSDL::XSD::Typelib::Builtin::string', -'GetWeather/CountryName' => 'SOAP::WSDL::XSD::Typelib::Builtin::string', - -# end atomic complex type (sequence) -'GetWeatherResponse' => 'MyElements::GetWeatherResponse', -# atomic complex type (sequence) -'GetWeatherResponse/GetWeatherResult' => 'SOAP::WSDL::XSD::Typelib::Builtin::string', - -# end atomic complex type (sequence) -'GetCitiesByCountry' => 'MyElements::GetCitiesByCountry', -# atomic complex type (sequence) -'GetCitiesByCountry/CountryName' => 'SOAP::WSDL::XSD::Typelib::Builtin::string', - -# end atomic complex type (sequence) -'GetCitiesByCountryResponse' => 'MyElements::GetCitiesByCountryResponse', -# atomic complex type (sequence) -'GetCitiesByCountryResponse/GetCitiesByCountryResult' => 'SOAP::WSDL::XSD::Typelib::Builtin::string', - -# end atomic complex type (sequence) - - - - -); - -sub get_class { - my $name = join '/', @{ $_[1] }; - exists $typemap{ $name } or die "Cannot resolve $name via " . __PACKAGE__; - return $typemap{ $name }; -} - -1; - -__END__ - +package MyTypemaps::GlobalWeather; +use strict; +use warnings; + +my %typemap = ( +# SOAP 1.1 fault typemap +'Fault' => 'SOAP::WSDL::SOAP::Typelib::Fault11', +'Fault/faultcode' => 'SOAP::WSDL::XSD::Typelib::Builtin::anyURI', +'Fault/faultactor' => 'SOAP::WSDL::XSD::Typelib::Builtin::TOKEN', +'Fault/faultstring' => 'SOAP::WSDL::XSD::Typelib::Builtin::string', +'Fault/detail' => 'SOAP::WSDL::XSD::Typelib::Builtin::string', + +# generated typemap +'GetWeather' => 'MyElements::GetWeather', +# atomic complex type (sequence) +'GetWeather/CityName' => 'SOAP::WSDL::XSD::Typelib::Builtin::string', +'GetWeather/CountryName' => 'SOAP::WSDL::XSD::Typelib::Builtin::string', + +# end atomic complex type (sequence) +'GetWeatherResponse' => 'MyElements::GetWeatherResponse', +# atomic complex type (sequence) +'GetWeatherResponse/GetWeatherResult' => 'SOAP::WSDL::XSD::Typelib::Builtin::string', + +# end atomic complex type (sequence) +'GetCitiesByCountry' => 'MyElements::GetCitiesByCountry', +# atomic complex type (sequence) +'GetCitiesByCountry/CountryName' => 'SOAP::WSDL::XSD::Typelib::Builtin::string', + +# end atomic complex type (sequence) +'GetCitiesByCountryResponse' => 'MyElements::GetCitiesByCountryResponse', +# atomic complex type (sequence) +'GetCitiesByCountryResponse/GetCitiesByCountryResult' => 'SOAP::WSDL::XSD::Typelib::Builtin::string', + +# end atomic complex type (sequence) + + + + +); + +sub get_class { + my $name = join '/', @{ $_[1] }; + exists $typemap{ $name } or die "Cannot resolve $name via " . __PACKAGE__; + return $typemap{ $name }; +} + +1; + +__END__ + diff --git a/example/weather.pl b/example/weather.pl index 7307c8b..e1e5260 100644 --- a/example/weather.pl +++ b/example/weather.pl @@ -1,20 +1,20 @@ -# Accessing the globalweather service at -# www.webservicex.net/GlobalWeather/GlobalWeather.asmx -# -# Note that the GlobalWeather web service returns a (quoted) XML structure - -# don't be surprised by the response's format. -# -# I have no connection to www.webservicex.net -# Use this script at your own risk. -# -# This script demonstrates the use of a interface generated by wsdl2perl.pl - -use lib 'lib/'; -use MyInterfaces::GlobalWeather; -my $weather = MyInterfaces::GlobalWeather->new(); -my $result = $weather->GetWeather({ CountryName => 'Germany', CityName => 'Munich' }); - -# boolean comparison overloaded -die $result->get_faultstring()->get_value() if not ($result); - -print $result->get_GetWeatherResult()->get_value() , "\n"; +# Accessing the globalweather service at +# www.webservicex.net/GlobalWeather/GlobalWeather.asmx +# +# Note that the GlobalWeather web service returns a (quoted) XML structure - +# don't be surprised by the response's format. +# +# I have no connection to www.webservicex.net +# Use this script at your own risk. +# +# This script demonstrates the use of a interface generated by wsdl2perl.pl + +use lib 'lib/'; +use MyInterfaces::GlobalWeather; +my $weather = MyInterfaces::GlobalWeather->new(); +my $result = $weather->GetWeather({ CountryName => 'Germany', CityName => 'Munich' }); + +# boolean comparison overloaded +die $result->get_faultstring()->get_value() if not ($result); + +print $result->get_GetWeatherResult()->get_value() , "\n"; diff --git a/example/weather_wsdl.pl b/example/weather_wsdl.pl index 05acc8e..b3f3040 100644 --- a/example/weather_wsdl.pl +++ b/example/weather_wsdl.pl @@ -1,39 +1,43 @@ -# Accessing the globalweather service at -# www.webservicex.net/GlobalWeather/GlobalWeather.asmx -# -# Note that the GlobalWeather web service returns a (quoted) XML structure - -# don't be surprised by the response's format. -# -# I have no connection to www.webservicex.net -# Use this script at your own risk. -# -# This script demonstrates the use of SOAP::WSDL in SOAP::Lite style. - -use lib 'lib/'; -use lib '../lib'; -use SOAP::WSDL; -use File::Basename qw(dirname); -use File::Spec; -my $path = File::Spec->rel2abs( dirname __FILE__); - -my $soap = SOAP::WSDL->new(); -my $som = $soap->wsdl("file:///$path/wsdl/globalweather.xml") - ->call('GetWeather', GetWeather => { CountryName => 'Germany', CityName => 'Munich' }); - -die $som->message() if $som->fault(); - -print $som->result(); - - -# SOAP::Lite variant: - -use SOAP::Lite; -my $soap = SOAP::Lite->new()->on_action( sub { join'/', @_ } ) - ->proxy("http://www.webservicex.net/globalweather.asmx"); -my $som = $soap->call( - SOAP::Data->name('GetWeather')->attr({ xmlns => 'http://www.webserviceX.NET' }), - SOAP::Data->name('CountryName')->value('Germany'), - SOAP::Data->name('CityName')->value('Munich') -); - -print $som->result(); +# Accessing the globalweather service at +# www.webservicex.net/GlobalWeather/GlobalWeather.asmx +# +# Note that the GlobalWeather web service returns a (quoted) XML structure - +# don't be surprised by the response's format. +# +# I have no connection to www.webservicex.net +# Use this script at your own risk. +# +# This script demonstrates the use of SOAP::WSDL in SOAP::Lite style. + +use lib 'lib/'; +use lib '../lib'; +use File::Basename qw(dirname); +use File::Spec; +my $path = File::Spec->rel2abs( dirname __FILE__); + +# SOAP::WSDL variant +use SOAP::WSDL; +my $soap = SOAP::WSDL->new(); +my $som = $soap->wsdl("file:///$path/wsdl/globalweather.xml") + ->call('GetWeather', GetWeather => + { CountryName => 'Germany', CityName => 'Munich' } +); + +die "Error" if $som->fault(); +print $som->result(); + +# SOAP::Lite variant: +# Note that you have to look both the proxy and the xmlns attribute +# set on the GetWeather SOAP::Data object from the WSDL. + +use SOAP::Lite; # +trace; +my $soap = SOAP::Lite->new()->on_action( sub { join'/', @_ } ) + ->proxy("http://www.webservicex.net/globalweather.asmx"); # from WSDL +my $som = $soap->call( + SOAP::Data->name('GetWeather') + ->attr({ xmlns => 'http://www.webserviceX.NET' }), # from WSDL + SOAP::Data->name('CountryName')->value('Germany'), + SOAP::Data->name('CityName')->value('Munich') +); +die "Error" if $som->fault(); +print $som->result(); diff --git a/example/wsdl/FortuneCookie.xml b/example/wsdl/FortuneCookie.xml index f35f93f..09afdc7 100644 --- a/example/wsdl/FortuneCookie.xml +++ b/example/wsdl/FortuneCookie.xml @@ -1,308 +1,308 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Display the number of nodes specified in fortune XML document - - - - - Get a random fortune cookie from the XML document - - - - - Count the actual number of nodes in the XML document of fortunes - - - - - Get a specific cookie by the XML node number - - - - - - - Display the number of nodes specified in fortune XML document - - - - - Get a random fortune cookie from the XML document - - - - - Count the actual number of nodes in the XML document of fortunes - - - - - Get a specific cookie by the XML node number - - - - - - - Display the number of nodes specified in fortune XML document - - - - - Get a random fortune cookie from the XML document - - - - - Count the actual number of nodes in the XML document of fortunes - - - - - Get a specific cookie by the XML node number - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Simple XML-based fortune cookie - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Display the number of nodes specified in fortune XML document + + + + + Get a random fortune cookie from the XML document + + + + + Count the actual number of nodes in the XML document of fortunes + + + + + Get a specific cookie by the XML node number + + + + + + + Display the number of nodes specified in fortune XML document + + + + + Get a random fortune cookie from the XML document + + + + + Count the actual number of nodes in the XML document of fortunes + + + + + Get a specific cookie by the XML node number + + + + + + + Display the number of nodes specified in fortune XML document + + + + + Get a random fortune cookie from the XML document + + + + + Count the actual number of nodes in the XML document of fortunes + + + + + Get a specific cookie by the XML node number + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Simple XML-based fortune cookie + + + + + + + + + + \ No newline at end of file diff --git a/example/wsdl/genericbarcode.xml b/example/wsdl/genericbarcode.xml index 7082b70..6363039 100644 --- a/example/wsdl/genericbarcode.xml +++ b/example/wsdl/genericbarcode.xml @@ -1,153 +1,153 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - WebserviceX.NET barcode library that provides the means to create barcodes for printing and display in any internet enabled applications. This web service supports Code 128, Industrial 2 of 5, Interleaved 2 of 5, Code 2 5 Matrix, Code 39, Code 39 Extended, Code 93, Code 93 Extended, Codabar, EAN13, EAN8, MSI, Postnet, Supp2, Supp5, UPC A, UPC E0 and UPC E1 barcode formats. This Barcodes returns byte image. It supports following image format JPEG, GIF, PNG, BMP, EMF, EXIF, ICON, MEMORY BMP, TIFF and WMF. - - - - - - - - - - - - - - - - - - - - - - - - - - Barcode generator - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + WebserviceX.NET barcode library that provides the means to create barcodes for printing and display in any internet enabled applications. This web service supports Code 128, Industrial 2 of 5, Interleaved 2 of 5, Code 2 5 Matrix, Code 39, Code 39 Extended, Code 93, Code 93 Extended, Codabar, EAN13, EAN8, MSI, Postnet, Supp2, Supp5, UPC A, UPC E0 and UPC E1 barcode formats. This Barcodes returns byte image. It supports following image format JPEG, GIF, PNG, BMP, EMF, EXIF, ICON, MEMORY BMP, TIFF and WMF. + + + + + + + + + + + + + + + + + + + + + + + + + + Barcode generator + + + + + + + + + + \ No newline at end of file diff --git a/example/wsdl/globalweather.xml b/example/wsdl/globalweather.xml index e5001cc..b28974d 100644 --- a/example/wsdl/globalweather.xml +++ b/example/wsdl/globalweather.xml @@ -1,185 +1,185 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Get weather report for all major cities around the world. - - - - - Get all major cities by country name(full / part). - - - - - - - Get weather report for all major cities around the world. - - - - - Get all major cities by country name(full / part). - - - - - - - Get weather report for all major cities around the world. - - - - - Get all major cities by country name(full / part). - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Get weather report for all major cities around the world. + + + + + Get all major cities by country name(full / part). + + + + + + + Get weather report for all major cities around the world. + + + + + Get all major cities by country name(full / part). + + + + + + + Get weather report for all major cities around the world. + + + + + Get all major cities by country name(full / part). + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/lib/SOAP/WSDL.pm b/lib/SOAP/WSDL.pm index dea81e5..c0ee5ee 100644 --- a/lib/SOAP/WSDL.pm +++ b/lib/SOAP/WSDL.pm @@ -1,104 +1,105 @@ package SOAP::WSDL; use strict; use warnings; -use vars qw($AUTOLOAD); -use Carp; +use vars qw($AUTOLOAD); +use Carp; use Scalar::Util qw(blessed); -use SOAP::WSDL::Client; +use SOAP::WSDL::Client; use SOAP::WSDL::Expat::WSDLParser; -use Class::Std; -use LWP::UserAgent; - -our $VERSION='2.00_12'; - -my %no_dispatch_of :ATTR(:name); -my %wsdl_of :ATTR(:name); -my %proxy_of :ATTR(:name); -my %readable_of :ATTR(:name); -my %autotype_of :ATTR(:name); -my %outputxml_of :ATTR(:name); -my %outputtree_of :ATTR(:name); -my %outputhash_of :ATTR(:name); -my %servicename_of :ATTR(:name); -my %portname_of :ATTR(:name); -my %class_resolver_of :ATTR(:name); - -my %method_info_of :ATTR(:default<()>); -my %port_of :ATTR(:default<()>); -my %porttype_of :ATTR(:default<()>); -my %binding_of :ATTR(:default<()>); -my %service_of :ATTR(:default<()>); -my %definitions_of :ATTR(:get :default<()>); -my %serialize_options_of :ATTR(:default<()>); -my %explain_options_of :ATTR(:default<()>); - -my %client_of :ATTR(:name :default<()>); - -my %LOOKUP = ( - no_dispatch => \%no_dispatch_of, - class_resolver => \%class_resolver_of, - wsdl => \%wsdl_of, - proxy => \%proxy_of, - readable => \%readable_of, - autotype => \%autotype_of, - outputxml => \%outputxml_of, - outputtree => \%outputtree_of, - outputhash => \%outputhash_of, - portname => \%portname_of, - servicename => \%servicename_of, -); - -for my $method (keys %LOOKUP ) { - no strict qw(refs); - *{ $method } = sub { - my $self = shift; - my $ident = ident $self; - if (@_) { - $LOOKUP{ $method }->{ $ident } = shift; - return $self; - } - return $LOOKUP{ $method }->{ $ident }; - }; -} - -{ - # we need to roll our own for supporting - # SOAP::WSDL->new( key => value ) syntax, - # like SOAP::Lite does - no warnings qw(redefine); - sub new { - my $class = shift; - my %args_from = @_; - my $self = \do { my $foo = undef }; - bless $self, $class; - - for (keys %args_from) { - my $method = $self->can("set_$_") - or croak "unknown parameter $_ passed to new"; - $method->($self, $args_from{$_}); - } - my $ident = ident $self; - $self->wsdlinit() if ($wsdl_of{ $ident }); - - $client_of{ $ident } = SOAP::WSDL::Client->new(); - - return $self; - } -} +use Class::Std; +use SOAP::WSDL::XSD::Typelib::Builtin::anySimpleType; +use LWP::UserAgent; + +our $VERSION='2.00_13'; + +my %no_dispatch_of :ATTR(:name); +my %wsdl_of :ATTR(:name); +my %proxy_of :ATTR(:name); +my %readable_of :ATTR(:name); +my %autotype_of :ATTR(:name); +my %outputxml_of :ATTR(:name :default<0>); +my %outputtree_of :ATTR(:name); +my %outputhash_of :ATTR(:name); +my %servicename_of :ATTR(:name); +my %portname_of :ATTR(:name); +my %class_resolver_of :ATTR(:name); + +my %method_info_of :ATTR(:default<()>); +my %port_of :ATTR(:default<()>); +my %porttype_of :ATTR(:default<()>); +my %binding_of :ATTR(:default<()>); +my %service_of :ATTR(:default<()>); +my %definitions_of :ATTR(:get :default<()>); +my %serialize_options_of :ATTR(:default<()>); +my %explain_options_of :ATTR(:default<()>); + +my %client_of :ATTR(:name :default<()>); + +my %LOOKUP = ( + no_dispatch => \%no_dispatch_of, + class_resolver => \%class_resolver_of, + wsdl => \%wsdl_of, + proxy => \%proxy_of, + readable => \%readable_of, + autotype => \%autotype_of, + outputxml => \%outputxml_of, + outputtree => \%outputtree_of, + outputhash => \%outputhash_of, + portname => \%portname_of, + servicename => \%servicename_of, +); + +for my $method (keys %LOOKUP ) { + no strict qw(refs); + *{ $method } = sub { + my $self = shift; + my $ident = ident $self; + if (@_) { + $LOOKUP{ $method }->{ $ident } = shift; + return $self; + } + return $LOOKUP{ $method }->{ $ident }; + }; +} + +{ + # we need to roll our own for supporting + # SOAP::WSDL->new( key => value ) syntax, + # like SOAP::Lite does + no warnings qw(redefine); + sub new { + my $class = shift; + my %args_from = @_; + my $self = \do { my $foo = undef }; + bless $self, $class; + + for (keys %args_from) { + my $method = $self->can("set_$_") + or croak "unknown parameter $_ passed to new"; + $method->($self, $args_from{$_}); + } + my $ident = ident $self; + $self->wsdlinit() if ($wsdl_of{ $ident }); + + $client_of{ $ident } = SOAP::WSDL::Client->new(); + + return $self; + } +} sub wsdlinit { - my $self = shift; + my $self = shift; my $ident = ident $self; - my %opt = @_; - - my $lwp = LWP::UserAgent->new(); - my $response = $lwp->get( $wsdl_of{ $ident } ); - croak $response->message() if ($response->code != 200); - - # TODO: Port parser to expat and remove XML::LibXML dependency + my %opt = @_; + + my $lwp = LWP::UserAgent->new(); + my $response = $lwp->get( $wsdl_of{ $ident } ); + croak $response->message() if ($response->code != 200); + + # TODO: Port parser to expat and remove XML::LibXML dependency my $parser = SOAP::WSDL::Expat::WSDLParser->new(); $parser->parse_string( $response->content() ); - + # sanity checks my $wsdl_definitions = $parser->get_data() or die "unable to parse WSDL"; my $types = $wsdl_definitions->first_types() @@ -112,7 +113,7 @@ sub wsdlinit { $serialize_options_of{ $ident } = { autotype => 0, typelib => $types, - namespace => $ns, + namespace => $ns, }; $explain_options_of{ $ident } = { readable => $self->readable(), @@ -120,8 +121,8 @@ sub wsdlinit { namespace => $ns, typelib => $types, }; - - $servicename_of{ $ident } = $opt{servicename} if $opt{servicename}; + + $servicename_of{ $ident } = $opt{servicename} if $opt{servicename}; $portname_of{ $ident } = $opt{portname} if $opt{portname}; return $self; } ## end sub wsdlinit @@ -129,22 +130,22 @@ sub wsdlinit { sub _wsdl_get_service :PRIVATE { my $ident = ident shift; my $wsdl = $definitions_of{ $ident }; - return $service_of{ $ident } = $servicename_of{ $ident } + return $service_of{ $ident } = $servicename_of{ $ident } ? $wsdl->find_service( $wsdl->get_targetNamespace() , $servicename_of{ $ident } ) : $service_of{ $ident } = $wsdl->get_service()->[ 0 ]; } ## end sub _wsdl_get_service -sub _wsdl_get_port :PRIVATE { +sub _wsdl_get_port :PRIVATE { my $ident = ident shift; my $wsdl = $definitions_of{ $ident }; my $ns = $wsdl->get_targetNamespace(); - return $port_of{ $ident } = $portname_of{ $ident } - ? $service_of{ $ident }->get_port( $ns, $portname_of{ $ident } ) + return $port_of{ $ident } = $portname_of{ $ident } + ? $service_of{ $ident }->get_port( $ns, $portname_of{ $ident } ) : $port_of{ $ident } = $service_of{ $ident }->get_port()->[ 0 ]; } sub _wsdl_get_binding :PRIVATE { - my $self = shift; + my $self = shift; my $ident = ident $self; my $wsdl = $definitions_of{ $ident }; my $port = $port_of{ $ident } || $self->_wsdl_get_port(); @@ -153,24 +154,24 @@ sub _wsdl_get_binding :PRIVATE { return $binding_of{ $ident }; } -sub _wsdl_get_portType :PRIVATE { +sub _wsdl_get_portType :PRIVATE { my $self = shift; my $ident = ident $self; my $wsdl = $definitions_of{ $ident }; my $binding = $binding_of{ $ident } || $self->_wsdl_get_binding(); - $porttype_of{ $ident } = $wsdl->find_portType( $wsdl->_expand( $binding->get_type() ) ) + $porttype_of{ $ident } = $wsdl->find_portType( $wsdl->_expand( $binding->get_type() ) ) or die "cannot find portType for " . $binding->get_type(); return $porttype_of{ $ident }; } sub _wsdl_init_methods :PRIVATE { - my $self = shift; + my $self = shift; my $ident = ident $self; my $wsdl = $definitions_of{ $ident }; my $ns = $wsdl->get_targetNamespace(); # get bindings, portType, message, part(s) - use private methods for clear separation... - $self->_wsdl_get_service if not ($service_of{ $ident }); + $self->_wsdl_get_service if not ($service_of{ $ident }); my $binding = $binding_of{ $ident } || $self->_wsdl_get_binding() || die "Can't find binding"; my $portType = $porttype_of{ $ident } || $self->_wsdl_get_portType(); @@ -197,66 +198,90 @@ sub _wsdl_init_methods :PRIVATE { $operation->first_input()->get_message(); # 3. get input message - my $message = $wsdl->find_message( $ns, $localname ) + my $message = $wsdl->find_message( $ns, $localname ) or die "Message {$ns}$localname not found in WSDL definition"; $method->{ parts } = $message->get_part(); - + # rpc / encoded methods may have a namespace specified. # look it up and set it... - $method->{ namespace } = $binding_operation - ? do { - my $input = $binding_operation->first_input(); - $input ? $input->get_namespace() : undef; - } + $method->{ namespace } = $binding_operation + ? do { + my $input = $binding_operation->first_input(); + $input ? $input->get_namespace() : undef; + } : undef; $method_info_of{ $ident }->{ $binding_operation->get_name() } = $method; } - + return $method_info_of{ $ident }; } - + sub call { - my $self = shift; + my ($self, $method, @data_from) = @_; my $ident = ident $self; - my $method = shift; - my $data = ref $_[0] ? $_[0] : { @_ }; - - $self->wsdlinit() if not ($definitions_of{ $ident }); - $self->_wsdl_init_methods() if not ($method_info_of{ $ident }); - - my $client = $client_of{ $ident }; - $client->set_proxy( $proxy_of{ $ident } || $port_of{ $ident }->get_location() ); - $client->set_no_dispatch( $no_dispatch_of{ $ident } ); - $client->set_outputxml( $outputtree_of{ $ident } ? 0 : 1 ); - - my $response = (blessed $data) - ? $client->call( $method, $data ) - : do { - my $content = ''; - # TODO support RPC-encoding: Top-Level element + namespace... - foreach my $part ( @{ $method_info_of{ $ident }->{ $method }->{ parts } } ) { - $client->set_on_action( sub { $part->get_targetNamespace() . '/' . $_[1] } ); - $content .= $part->serialize( $method, $data, - { - %{ $serialize_options_of{ $ident } }, - readable => $readable_of{ $ident }, - } ); - } - $client->call($method, $content); - }; - - return $response if ( - $outputxml_of{ $ident } -# || $outputhash_of{ $ident } - || $outputtree_of{ $ident } - || $no_dispatch_of{ $ident } ); - - return unless $response; # nothing to do for one-ways - # now convert into SOAP::SOM - bah ! - require SOAP::Lite; - return SOAP::Deserializer->new()->deserialize( $response ); + + my ($data, $header) = ref $data_from[0] + ? ($data_from[0], $data_from[1] ) + : (@data_from>1) + ? ( { @data_from }, undef ) + : ( $data_from[0], undef ); + + $self->wsdlinit() if not ($definitions_of{ $ident }); + $self->_wsdl_init_methods() if not ($method_info_of{ $ident }); + + my $client = $client_of{ $ident }; + $client->set_proxy( $proxy_of{ $ident } || $port_of{ $ident }->get_location() ); + $client->set_no_dispatch( $no_dispatch_of{ $ident } ); + + $client->set_outputxml( $outputxml_of{ $ident } ? 1 : 0 ); + + # maybe we should introduce something like $output{ $ident } with a fixed + # set of values - m{^(TREE|HASH|XML|SOM)$}xms ? + if ( ( ! $outputtree_of{ $ident } ) + && ( ! $outputhash_of{ $ident } ) + && ( ! $outputxml_of{ $ident } ) ) { + require SOAP::WSDL::Deserializer::SOM; + $client->set_deserializer( SOAP::WSDL::Deserializer::SOM->new() ); + }; + + my $method_info = $method_info_of{ $ident }->{ $method }; + + # TODO serialize both header and body, not only header + my $response = (blessed $data) + ? $client->call( { + operation => $method, + soap_action => $method_info->{ soap_action }, + }, $data ) + : do { + my $content = ''; + # TODO support RPC-encoding: Top-Level element + namespace... + foreach my $part ( @{ $method_info->{ parts } } ) { + $content .= $part->serialize( $method, $data, + { + %{ $serialize_options_of{ $ident } }, + readable => $readable_of{ $ident }, + } ); + } + $client->call( + { + operation => $method, + soap_action => $method_info->{ soap_action } + }, + # absolutely stupid, but we need a reference which + # serializes to XML on stringification... + SOAP::WSDL::XSD::Typelib::Builtin::anySimpleType->new({ + value => $content + }), + SOAP::WSDL::XSD::Typelib::Builtin::anySimpleType->new({ + value => $header + }) + ); + }; + + return unless defined $response; # nothing to do for one-ways + return $response; } sub explain { @@ -270,18 +295,18 @@ sub explain { __END__ =pod - -=head1 NAME - -SOAP::WSDL - SOAP with WSDL support - -=head1 Overview - -For creating Perl classes instrumenting a web service with a WSDL definition, -read L. - -For using an interpreting (thus slow and somewhat troublesome) WSDL based -SOAP client, which mimics L's API, read on. + +=head1 NAME + +SOAP::WSDL - SOAP with WSDL support + +=head1 Overview + +For creating Perl classes instrumenting a web service with a WSDL definition, +read L. + +For using an interpreting (thus slow and somewhat troublesome) WSDL based +SOAP client, which mimics L's API, read on. =head1 SYNOPSIS @@ -292,30 +317,47 @@ SOAP client, which mimics L's API, read on. my $result = $soap->call('MyMethod', %data); -=head1 DESCRIPTION +=head1 DESCRIPTION + +SOAP::WSDL provides easy access to Web Services with WSDL descriptions. -SOAP::WSDL provides easy access to Web Services with WSDL descriptions. - The WSDL is parsed and stored in memory. Your data is serialized according to the rules in the WSDL. - -The only transport mechanisms currently supported are http and https. -=head1 METHODS - -=head2 new - -Constructor. All parameters passed are passed to the corresponding methods. - +The only transport mechanisms currently supported are http and https. + +=head1 METHODS + +=head2 new + +Constructor. All parameters passed are passed to the corresponding methods. + =head2 call Performs a SOAP call. The result is either an object tree (with outputtree), a hash reference (with outputhash), plain XML (with outputxml) or a SOAP::SOM object (with neither of the above set). +call() can be called in different ways: + +=over + +=item * Old-style idiom + my $result = $soap->call('method', %data); +Does not support SOAP header data. + +=item * New-style idiom + + my $result = $soap->call('method', $body_ref, $header_ref ); + +Does support SOAP header data. $body_ref and $header ref may either be +hash refs or SOAP::WSDL::XSD::Typelib::* derived objects. + +=back + =head2 wsdlinit Reads the WSDL file and initializes SOAP::WSDL for working with it. @@ -405,30 +447,30 @@ Returns the soap object, so you can chain calls like When set, call() returns the plain request XML instead of dispatching the SOAP call to the SOAP service. Handy for testing/debugging. - -=head1 ACCESS TO SOAP::WSDL's internals - -=head2 get_client / set_client - -Returns the SOAP client implementation used (normally a SOAP::WSDL::Client -object). - -Useful for enabling tracing: - - # enable tracing via 'warn' - $soap->get_client->set_trace(1); - - # enable tracing via a custom facility - - # Log::Log4perl in this case... - $soap->get_client->set_trace(sub { Log::Log4perl->get_logger->info(@_) } ); - -=head1 EXAMPLES - -See the examples/ directory. - -=head1 Differences to previous versions -=over +=head1 ACCESS TO SOAP::WSDL's internals + +=head2 get_client / set_client + +Returns the SOAP client implementation used (normally a SOAP::WSDL::Client +object). + +Useful for enabling tracing: + + # enable tracing via 'warn' + $soap->get_client->set_trace(1); + + # enable tracing via a custom facility - + # Log::Log4perl in this case... + $soap->get_client->set_trace(sub { Log::Log4perl->get_logger->info(@_) } ); + +=head1 EXAMPLES + +See the examples/ directory. + +=head1 Differences to previous versions + +=over =item * WSDL handling @@ -440,68 +482,68 @@ it's content. The object tree has two main functions: It knows how to serialize data passed as hash ref, and how to render the WSDL elements found into perl classes. -Yup your're right, there's a builting code generation facility. Read +Yup your're right, there's a builting code generation facility. Read L for using it. =item * no_dispatch call() with outputtxml set to true now returns the complete SOAP envelope, not only the body's content. - -=item * outputxml - -call() with outputxml set to true now returns the complete SOAP -envelope, not only the body's content. + +=item * outputxml + +call() with outputxml set to true now returns the complete SOAP +envelope, not only the body's content. =item * servicename/portname Both servicename and portname can only be called B calling wsdlinit(). You may pass the servicename and portname as attributes to wsdlinit, though. - -=back - -=head1 Differences to SOAP::Lite - -=head2 Message style/encoding - -While SOAP::Lite supports rpc/encoded style/encoding only, SOAP::WSDL currently -supports document/literal style/encoding. - -=head2 autotype / type information - -SOAP::Lite defaults to transmitting XML type information by default, where -SOAP::WSDL defaults to leaving it out. - -autotype(1) might even be broken in SOAP::WSDL - it's not well-tested, yet. - -=head2 Output formats - -In contrast to SOAP::Lite, SOAP::WSDL supports the following output formats: - -=over - -=item * SOAP::SOM objects. - -This is the default. SOAP::Lite is required for outputting SOAP::SOM objects. - -=item * Object trees. - -This is the recommended output format. -You need a class resolver (typemap) for outputting object trees. -See L above. - -=item * Hash refs - -This is for convnience: A single hash ref containing the content of the -SOAP body. - -=item * xml - -See below. - -=back - + +=back + +=head1 Differences to SOAP::Lite + +=head2 Message style/encoding + +While SOAP::Lite supports rpc/encoded style/encoding only, SOAP::WSDL currently +supports document/literal style/encoding. + +=head2 autotype / type information + +SOAP::Lite defaults to transmitting XML type information by default, where +SOAP::WSDL defaults to leaving it out. + +autotype(1) might even be broken in SOAP::WSDL - it's not well-tested, yet. + +=head2 Output formats + +In contrast to SOAP::Lite, SOAP::WSDL supports the following output formats: + +=over + +=item * SOAP::SOM objects. + +This is the default. SOAP::Lite is required for outputting SOAP::SOM objects. + +=item * Object trees. + +This is the recommended output format. +You need a class resolver (typemap) for outputting object trees. +See L above. + +=item * Hash refs + +This is for convnience: A single hash ref containing the content of the +SOAP body. + +=item * xml + +See below. + +=back + =head2 outputxml SOAP::Lite returns only the content of the SOAP body when outputxml is set @@ -519,34 +561,34 @@ SOAP::WSDL::Client and implementing something like $soap_wsdl_client->call( mySoapMethod, @_); } -You may even do this in a class factory - see L for creating +You may even do this in a class factory - see L for creating such interfaces. - -=head3 Debugging / Tracing - -While SOAP::Lite features a global tracing facility, SOAP::WSDL -allows to switch tracing on/of on a per-object base. - -This has to be done in the SOAP client used by SOAP::WSDL - see -L for an example and L for -details. + +=head3 Debugging / Tracing + +While SOAP::Lite features a global tracing facility, SOAP::WSDL +allows to switch tracing on/of on a per-object base. + +This has to be done in the SOAP client used by SOAP::WSDL - see +L for an example and L for +details. =head1 Bugs and Limitations =over - -=item * SOAP Headers are not supported - -There's no way to use SOAP Headers with SOAP::WSDL yet. - -=item * Apache SOAP datatypes are not supported - -You currently can't use SOAP::WSDL with Apache SOAP datatypes like map. - -If you want this changed, email me a copy of the specs, please. - -=item * outputhash - + +=item * SOAP Headers are not supported + +There's no way to use SOAP Headers with SOAP::WSDL yet. + +=item * Apache SOAP datatypes are not supported + +You currently can't use SOAP::WSDL with Apache SOAP datatypes like map. + +If you want this changed, email me a copy of the specs, please. + +=item * outputhash + outputhash is not implemented yet. =item * Unsupported XML Schema definitions @@ -591,27 +633,27 @@ The following facets have no influence yet: enumeration =back - -=head1 SEE ALSO - + +=head1 SEE ALSO + =head2 Related projects -=over - -=item * L - -Full featured SOAP-library, little WSDL support. Supports rpc-encoded style only. Many protocols supported. - -=item * - -A promising-looking approach derived from a cool functional DOM-based XML schema parser. - -Will support encoding/decoding of SOAP messages based on WSDL definitions. - -Not yet finished at the time of writing - but you may wish to give it a try, especially -if you need to adhere very closely to the XML Schema / WSDL specs. - -=back +=over + +=item * L + +Full featured SOAP-library, little WSDL support. Supports rpc-encoded style only. Many protocols supported. + +=item * + +A promising-looking approach derived from a cool functional DOM-based XML schema parser. + +Will support encoding/decoding of SOAP messages based on WSDL definitions. + +Not yet finished at the time of writing - but you may wish to give it a try, especially +if you need to adhere very closely to the XML Schema / WSDL specs. + +=back =head2 Sources of documentation @@ -626,25 +668,25 @@ L L =back - -=head1 ACKNOWLEDGMENTS - -There are many people out there who fostered SOAP::WSDL's developement. -I would like to thank them all (and apologize to all those I have forgotten). - -Giovanni S. Fois wrote a improved version of SOAP::WSDL (which eventually became v1.23) - -Damian A. Martinez Gelabert, Dennis S. Hennen, Dan Horne, Peter Orvos, Mark Overmeer, -Jon Robens, Isidro Vila Verde and Glenn Wood spotted bugs and/or -suggested improvements in the 1.2x releases. - -Andreas 'ACID' Specht constantly asked for better performance. - -Numerous people sent me their real-world WSDL files for testing. Thank you. - -Paul Kulchenko and Byrne Reese wrote and maintained SOAP::Lite and thus provided a -base (and counterpart) for SOAP::WSDL. - + +=head1 ACKNOWLEDGMENTS + +There are many people out there who fostered SOAP::WSDL's developement. +I would like to thank them all (and apologize to all those I have forgotten). + +Giovanni S. Fois wrote a improved version of SOAP::WSDL (which eventually became v1.23) + +Damian A. Martinez Gelabert, Dennis S. Hennen, Dan Horne, Peter Orvos, Mark Overmeer, +Jon Robens, Isidro Vila Verde and Glenn Wood spotted bugs and/or +suggested improvements in the 1.2x releases. + +Andreas 'ACID' Specht constantly asked for better performance. + +Numerous people sent me their real-world WSDL files for testing. Thank you. + +Paul Kulchenko and Byrne Reese wrote and maintained SOAP::Lite and thus provided a +base (and counterpart) for SOAP::WSDL. + =head1 LICENSE Copyright 2004-2007 Martin Kutter. @@ -655,13 +697,13 @@ the same terms as perl itself =head1 AUTHOR Martin Kutter Emartin.kutter fen-net.deE - -=head1 REPOSITORY INFORMATION - - $Rev: 188 $ - $LastChangedBy: kutterma $ - $Id: WSDL.pm 188 2007-09-03 15:15:19Z kutterma $ - $HeadURL: https://soap-wsdl.svn.sourceforge.net/svnroot/soap-wsdl/SOAP-WSDL/trunk/lib/SOAP/WSDL.pm $ - + +=head1 REPOSITORY INFORMATION + + $Rev: 218 $ + $LastChangedBy: kutterma $ + $Id: WSDL.pm 218 2007-09-10 16:19:23Z kutterma $ + $HeadURL: https://soap-wsdl.svn.sourceforge.net/svnroot/soap-wsdl/SOAP-WSDL/trunk/lib/SOAP/WSDL.pm $ + =cut diff --git a/lib/SOAP/WSDL/Base.pm b/lib/SOAP/WSDL/Base.pm index 629b8df..01d86c5 100644 --- a/lib/SOAP/WSDL/Base.pm +++ b/lib/SOAP/WSDL/Base.pm @@ -3,20 +3,20 @@ use strict; use warnings; use Carp; use Class::Std::Storable; -use List::Util qw(first); +use List::Util qw(first); my %id_of :ATTR(:name :default<()>); -my %name_of :ATTR(:name :default<()>); +my %name_of :ATTR(:name :default<()>); my %documentation_of :ATTR(:name :default<()>); my %targetNamespace_of :ATTR(:name :default<()>); my %xmlns_of :ATTR(:name :default<{}>); -my %parent_of :ATTR(:name :default<()>); - -sub DEMOLISH { - my $self = shift; - # delete upward references - delete $parent_of{ ident $self }; -} +my %parent_of :ATTR(:name :default<()>); + +sub DEMOLISH { + my $self = shift; + # delete upward references + delete $parent_of{ ident $self }; +} sub STORABLE_freeze_pre :CUMULATIVE {}; sub STORABLE_freeze_post :CUMULATIVE {}; @@ -29,15 +29,15 @@ sub STORABLE_thaw_post :CUMULATIVE { return $_[0] }; sub AUTOMETHOD { my ($self, $ident, @values) = @_; my $subname = $_; # Requested subroutine name is passed via $_ - + # we're called as $self->push_something(@values); if ($subname =~s{^push_}{}xms) { my $getter = "get_$subname"; - my $setter = "set_$subname"; - ## Checking here is paranoid - will fail fatally if - ## there is no setter... - ## And we would have to check getters, too. - ## Maybe do it the Conway way via the Symbol table... + my $setter = "set_$subname"; + ## Checking here is paranoid - will fail fatally if + ## there is no setter... + ## And we would have to check getters, too. + ## Maybe do it the Conway way via the Symbol table... ## ... can is way slow... # croak "no set accessor found for push_$subname" # if not ($self->can( $setter )); @@ -112,50 +112,50 @@ sub to_typemap { warn "to_typemap"; return q{}; } - -sub toClass { - my $self = shift; + +sub toClass { + my $self = shift; warn 'toClass is deprecated and will be removed before reaching 2.01 - ' - . 'use to_class instead (' . caller() . ')'; - $self->to_class(@_); -} - -sub to_class { - my $self = shift; - my $opt = shift; - my $template = shift; - + . 'use to_class instead (' . caller() . ')'; + $self->to_class(@_); +} + +sub to_class { + my $self = shift; + my $opt = shift; + my $template = shift; + $opt->{ base_path } ||= '.'; - - my $element_prefix = $opt->{ element_prefix } || $opt->{ prefix }; - my $type_prefix = $opt->{ type_prefix } || $opt->{ prefix }; - - if (($type_prefix) && ($type_prefix !~m{ :: $ }xms ) ) { - warn 'type_prefix should end with "::"'; - $type_prefix .= '::'; - } - - if (($element_prefix) && ($element_prefix !~m{ :: $ }xms) ) { - warn 'element_prefix should end with "::"'; - $element_prefix .= '::'; - } - - # Be careful: a Element may be ComplexType, too - # (but not vice versa) - my $prefix = $self->isa('SOAP::WSDL::XSD::Element') - ? $element_prefix - : $type_prefix; - - die 'No prefix specified' if not $prefix; - - my $filename = $prefix . $self->get_name() . '.pm'; - $filename =~s{::}{/}xmsg; - - my $output = $opt->{ output } || $filename; + + my $element_prefix = $opt->{ element_prefix } || $opt->{ prefix }; + my $type_prefix = $opt->{ type_prefix } || $opt->{ prefix }; + + if (($type_prefix) && ($type_prefix !~m{ :: $ }xms ) ) { + warn 'type_prefix should end with "::"'; + $type_prefix .= '::'; + } + + if (($element_prefix) && ($element_prefix !~m{ :: $ }xms) ) { + warn 'element_prefix should end with "::"'; + $element_prefix .= '::'; + } + + # Be careful: a Element may be ComplexType, too + # (but not vice versa) + my $prefix = $self->isa('SOAP::WSDL::XSD::Element') + ? $element_prefix + : $type_prefix; + + die 'No prefix specified' if not $prefix; + + my $filename = $prefix . $self->get_name() . '.pm'; + $filename =~s{::}{/}xmsg; + + my $output = $opt->{ output } || $filename; require Template; my $tt = Template->new( - RELATIVE => 1, + RELATIVE => 1, OUTPUT_PATH => $opt->{ base_path }, ); @@ -169,5 +169,5 @@ sub to_class { $output ) or die $tt->error(); -} +} 1; diff --git a/lib/SOAP/WSDL/Binding.pm b/lib/SOAP/WSDL/Binding.pm index fed3546..60f11f4 100644 --- a/lib/SOAP/WSDL/Binding.pm +++ b/lib/SOAP/WSDL/Binding.pm @@ -2,26 +2,26 @@ package SOAP::WSDL::Binding; use strict; use warnings; use Class::Std::Storable; -use List::Util qw(first); +use List::Util qw(first); use base qw(SOAP::WSDL::Base); my %operation_of :ATTR(:name :default<()>); my %type_of :ATTR(:name :default<()>); my %transport_of :ATTR(:name :default<()>); my %style_of :ATTR(:name