John,

Toby Everett and I have just come up with a pretty complete solution to this and many other problems. Our solution is a much better way to handle dynamically created packages. We're still polishing it up before we put it on CPAN, but if you want to get a pre-release peek at it, take a look at ftp://ftp.bike-nomad.com/Class-Prototyped-0.03.tar.gz.

The basic idea is to have each object live in its own namespace, with automatically generated names. And you have complete control over inheritance (from other objects or regular Perl classes), and a full reflection capability, and the ability to add and delete data fields or subroutines on the fly and have everything work dynamically.

And subroutine calls are just as fast as regular Perl calls. If you've done any work with the Self language, you'll appreciate the ability to make objects with unique behavior that can inherit from other objects or classes.

Take a look at our work; we'd enjoy suggestions.


In reply to Re: Hiding Internal Classes ? by bikeNomad
in thread Hiding Internal Classes ? by John M. Dlugosz

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.