moniker(3)

okay bestie, welcome to the moniker(3) page from the User Contributed Perl Documentation β€” it's giving tiny module, huge personality. πŸ’…

🌸 NAME 🌸

UNIVERSAL::moniker

✨ SYNOPSIS ✨

use UNIVERSAL::moniker;

πŸ’… DESCRIPTION πŸ’…

Real talk: class names in Perl often don't sound great when spoken, or look good when written in prose. So we tend to say stuff like "customer" or "basket" when we're actually referring to My::Site::User::Customer or My::Site::Shop::Basket. And we thought it would be nice if our classes knew what we would prefer to call them. 🫢

This module will add a moniker (and plural_moniker) method to UNIVERSAL, and so to every class or module. No cap. ✨

🌟 moniker 🌟

$ob->moniker;

Returns the moniker for $ob. So, if $ob->isa("Big::Scary::Animal"), moniker will return "animal". πŸ¦‹

🌈 plural_moniker 🌈

$ob->plural_moniker;

Returns the plural moniker for $ob. So, if $ob->isa("Cephalopod::Octopus"), plural_moniker will return "octopuses". πŸ™

🚨 dependency check, bestie: You need to install Lingua::EN::Inflect for this to work. πŸ’–

πŸ‘‘ AUTHORS πŸ‘‘

  • Marty Pauley <marty+perl@kasei.com>
  • Tony Bowden <tony@kasei.com>
  • Elizabeth Mattijsen <liz@dijkmat.nl>

(Yes, 3 authors for such a small module!) πŸ˜­πŸ‘‘

Copyright (C) 2004 Kasei

This program is free software; you can redistribute it under the same terms as Perl.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.


okay that's the whole page, bestie πŸ’– β€” this one comes from perl v5.42.0, dated 2024-12-19, and the page is moniker(3). periodt ✨

πŸ“¦ where this page comes from