"Classes are just packages" pre-supposes a class-based paradigm. I want to put less emphasis on classes and more on objects. It's possible to create objects by composing roles on-the-fly, for example. And even though these objects are still backed by packages and stashes and stuff, you don't have to think of each class being a package and being defined in a module.

This is stuff which is hard to do properly in languages like Java, but you can still use it to conceive how you design your program, and then "down translate" that into whatever programming language you're using. For example, something like roles/traits/mixins can be emulated in Java using a combination of interfaces and delegation.


In reply to Re^6: RFC: OO Perl using Moo/Moose book by tobyink
in thread RFC: OO Perl using Moo/Moose book by Perl300

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.