I'm trying to use some web services via SOAP::Lite and for the most part it has been going smoothly. But now I'm beginning to hit problems with the fast and loose way that perl turns the results into perl structures. I'd rather be returning nicely packaged objects to the user rather than nested hashes. And I'd love not to code such classes by hand if it can be helped

The WSDL defines all the data structures that are used, and in some other languages (for example java), you can generate classes to mirror the complex types defined there. But I haven't found anything in the perl world to do this. stubmaker.pl in the SOAP::Lite package just deals with the connection details and a few details of typing data you send. SOAP::WSDL seems to do a better job of typing the data I need to send. But neither of these do any autogeneration of classes to hold the data I get back from a call.

Is there anything out there that can take a WSDL file and autogenerate some classes to mirror the complex types it defines? Bonus point if the same classes can be used to easily wrap up the data in SOAP::Data objects to send

In reply to auto generating wrapper classes for complex types defined in WSDL by Anonymous Monk

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.