* Greg Lindahl <lind...@pbm.com> [2014-05-13 02:10]: > We're open-sourcing our module that generates the basedomain of a > hostname, i.e. ic.ac.uk or blekko.com. We need a name. > > These existing modules do the same thing, only slower, less > completely, and less correctly: > > Mozilla::PublicSuffix > Domain::PublicSuffix > ParseUtil::Domain > IO::Socket::SSL::PublicSuffix > Net::Domain::Match
Net::Domain::Regex Net::Domain::TldMozilla > Here are some ideas for a new name: > > Domain::BaseDomain (possibly confusing with Domain::PublicSuffix) > Net::BaseDomain > Net::PublicSuffix > Host::BaseDomain > Host::PublicSuffix > Net::Domain::PublicSuffix > > What say you, oh naming consultants? The functionality does not lend itself to an obvious keyword, but if you *do* know a keyword then it’s “public suffix”, so if you ask me the name should be some form of ::PublicSuffix. As for the choice of TLNS, Domain::PublicSuffix appears to be the sole thing under Domain::, and it doesn’t look like there is *anything* yet under Host::, so I’d be disinclined to go with either. And Net:: seems a bit too generic for this module, plus in general it *tends* to be for protocol implementations, when people aren’t randomly using it for all sorts of junk they consider net-related. But Net::Domain:: looks just fine. It’s specific enough, and going by the choices of the other authors of public suffix modules, it also seems like a namespace where other people will expect it. Furthermore all the *other* modules in that namespace are internet domain-related also, so the evidence says that Net::Domain:: universally communicates exactly the concept you want to refer to. And hey, it’s your lucky day: though several authors put their public suffix list modules in Net::Domain::, none of them have squatted on the preferable term, so it’s still yours for the grabbing. So, congratulations on your shiny new Net::Domain::PublicSuffix module. :-) Regards, -- Aristotle Pagaltzis // <http://plasmasturm.org/>