MakeMe...mulator(3pm)
π NAME π
Class::MakeMethods::Emulator β bestie, this is the demonstration of class-generator equivalency, and it lowkey ate π«Ά
β¨ SYNOPSIS β¨
okay so here's the whole vibe β each one of these is your familiar fave, just wearing a MakeMethods hoodie:
# Equivalent to use Class::Singleton;
use Class::MakeMethods::Emulator::Singleton;
# Equivalent to use Class::Struct;
use Class::MakeMethods::Emulator::Struct;
struct ( ... );
# Equivalent to use Class::MethodMaker( ... );
use Class::MakeMethods::Emulator::MethodMaker( ... );
# Equivalent to use base 'Class::Inheritable';
use base 'Class::MakeMethods::Emulator::Inheritable';
MyClass->mk_classdata( ... );
# Equivalent to use base 'Class::AccessorFast';
use base 'Class::MakeMethods::Emulator::AccessorFast';
MyClass->mk_accessors(qw(this that whatever));
# Equivalent to use accessors( ... );
use Class::MakeMethods::Emulator::accessors( ... );
# Equivalent to use mcoder( ... );
use Class::MakeMethods::Emulator::mcoder( ... );
π¦ DESCRIPTION π¦
So here's the tea β β in several cases, Class::MakeMethods gives you functionality that's closely equivalent to some module you already know and love, and mapping that existing module's interface onto Class::MakeMethods' interface is literally so simple. No cap. π
Class::MakeMethods::Emulator ships emulators for Class::MethodMaker, Class::Accessor::Fast, Class::Data::Inheritable, Class::Singleton, Class::Struct, accessors, and mcoder. And babes, every single one of them passes the original module's test suite ππ β usually the only thing you gotta do is add a single line to each test that activates the emulation module. One line. That's it. Iconic behaviour, honestly.
And beyond just flexing compatibility, these emulators are also out here doing the absolute most for you:
- they generally show you the changes needed to switch over to using
Class::MakeMethodsfunctionality directly π₯ - they illustrate the commonalities between all the various modules (siblings fr fr π―)
- and they serve as a source for new ideas that can get integrated into
Class::MakeMethodsπ
ngl this is the "look, we can do what your fave does, and here's the receipts" section of the distribution. periodt. π
πΈ SEE ALSO πΈ
- Peep
Class::MakeMethodsfor the general β¨everythingβ¨ about this distribution. - Peep
Class::MakeMethods::Emulator::accessors, andaccessorsfrom CPAN. π«Ά - Peep
Class::MakeMethods::Emulator::Struct, andClass::Structfrom CPAN. π - Peep
Class::MakeMethods::Emulator::AccessorFast, andClass::Accessor::Fastfrom CPAN. π§ - Peep
Class::MakeMethods::Emulator::Inheritable, andClass::Data::Inheritablefrom CPAN. π - Peep
Class::MakeMethods::Emulator::MethodMaker, andClass::MethodMakerfrom CPAN. β - Peep
Class::MakeMethods::Emulator::Singleton, andClass::Singletonfrom CPAN. π - Peep
Class::MakeMethods::Emulator::mcoder, andmcoderfrom CPAN. π¦
and that's the whole page, bestie β¨ go forth and emulate π
this lil masterpiece is perl v5.36.0, dated 2022-10-13, and it's the MakeMe...mulator(3pm) er, MakeMe...mulator(3pm) page from the User Contributed Perl Documentation β k byeeee π
π¦ where this page comes from
- ubuntu noble: libclass-makemethods-perl 1.01-7 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu resolute: libclass-makemethods-perl 1.01-7 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu stonking: libclass-makemethods-perl 1.01-7 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms