Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change
 
PerlMonks  

Hmmm, how should I name this new module/library ?

by Bloodnok (Vicar)
on Nov 18, 2009 at 12:12 UTC ( [id://807889]=perlquestion: print w/replies, xml ) Need Help??

Bloodnok has asked for the wisdom of the Perl Monks concerning the following question:

Good local time one and all ,

Just when you thought it was safe ... along I come and spoil it all by asking yet another in my infrequent series of questions of stupidity defying proportions.

I've spent quite a while googling (yes, I do have the time ... ever since my last client engagement was pre-emptorarily finished due to project cutbacks:-(( for the answer to the question: Are there any recommendations, heuristics, guidelines, rules of thumb, or indeed anything else, regarding the naming/location of new modules/libraries.

Specifically, the question of the moment is: Where should a library to implement a compound data type as a class', live - under Class::*, Data::* or even elsewhere ??

A user level that continues to overstate my experience :-))

Replies are listed 'Best First'.
Re: Hmmm, how should I name this new module/library ?
by zentara (Archbishop) on Nov 18, 2009 at 12:59 UTC
    stupidity defying proportions

    oooh that sounds like my department.. :-)

    ....if i was to start looking for such a monstrosity ;-), i would first look under Data_and_Data_Types .... and name it something like Data::Object_MY_SPECIAL_FEATURE

    ... i used this reasoning to name my Tk::CanvasDirTree.... its a Tk::Canvas with a directory(DIR) tree on it..... so try to find some short 3 or 4 letter acronyms that poetically convey the essence of the module :-) and form a string


    I'm not really a human, but I play one on earth.
    Old Perl Programmer Haiku
Re: Hmmm, how should I name this new module/library ?
by moritz (Cardinal) on Nov 18, 2009 at 13:35 UTC
    Don't name it Class:: - such names usually refer to modules that make object orientation easier - i.e. writing classes (the notable exception being Class::Path, which IMHO is badly named).

    Also most classes implement compound data types in some sense, so that alone shouldn't be your naming criterion.

    So, name your class after the field it works in, and after what it does. Without knowing specifics it's hard to give general advise, except to look at existing CPAN root namespaces and try to re-use them where appropriate.

    Perl 6 - links to (nearly) everything that is Perl 6.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://807889]
Approved by BioLion
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others perusing the Monastery: (4)
As of 2024-03-28 08:40 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found