99% of the time, the fact that multi-tier collections of collections being exposed to a single module, points to poor modulization of code, or lack of OO design.
That's a pretty bold statement. Do you have anything to back up this claim? 99%? How large was your sample?
If the code happens to have a OO face, then it indicates lack of genuine understanding of OO.
Another bold statement. Please explain why this is.
As a matter of fact, 99% of the time, OO classes should only see one level of collection. The elements of the collection, whatever how complex they are, their internal structure should not be exposed to the class that holds the collection.
Oh? Why? It's not very interesting just to state opinions as facts, without giving any justification.
There is absolutely no reason for a person to believe that his/her data is complex enough and cannot be clearly contained in layers.
Yes, but that doesn't mean data shouldn't be stored in hashes of hashes, or arrays of hashes. Nor does it mean that OO is the answer. (In fact, considering that most Perl objects use a reference to a hash to store their state, you're even creating more layers of hashes of hashes of hashes of hashes if you go the OO world).
Naked complex data structure can easily create maintainance nightmares.
OTOH, the world has run for thousands of years using hierarchical storage systems. And a maze of twisty little classes, all different is easily created, and a maintainance nightmare.

Abigail


In reply to Re: multi-tier collections & lack of modulization/OO by Abigail-II
in thread multi-tier collections & lack of modulization/OO by pg

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.