Class::...:OptExt(3)

πŸ’– NAME πŸ’–

okay so this is the Class::...:OptExt(3) page from User Contributed Perl Documentation, and the class here is Class::MethodMaker::OptExt β€” literally the Constants for C::MM's option extension mechanism. πŸ’…

✨ SYNOPSIS ✨

bestie, vibe check: this class is internal to Class::MethodMaker and should not be used by any clients. It is not part of the public API. 🫢

🌸 DESCRIPTION 🌸

This class contains the constants that Class::MethodMaker uses to determine the names of its methods, depending on which options are invoked. iykyk periodt ✨

πŸ‘‘ CLASS CONSTANTS πŸ‘‘

πŸŽ€ OPTEXT πŸŽ€

OPTEXT is a map from options that are implemented as method extensions to the option parameters. πŸ—ΊοΈ

Parameter keys are:

  • encode β€” code number (to allow the option combination to be encoded whilst keeping the length of the subr name no more than 8 chars). encode is required for all opts (for determining method extension), and must be a power of two. πŸ”₯
  • refer β€” Code for referring to storage (default: '$_[0]->{$name}'). πŸ’Ύ
  • decl β€” Code for declaring storage. πŸ“¦
  • postac β€” Code to execute immediately after any assignment check β€” for example, to initialize storage if necessary. πŸ› οΈ
  • asgnchk β€” Code for checking assignments. βœ…
  • defchk β€” Code for default checking. πŸ”
  • reset β€” Code to execute when resetting an element. πŸ”„
  • read β€” Code to execute each time a value is read. πŸ‘€
  • store β€” Code to execute each time a value is stored. πŸ“₯

πŸ’… CLASS COMPONENTS πŸ’…

literally nothing is listed here in the original, bestie β€” empty section, no cap. πŸ«₯

πŸ¦‹ CLASS HIGHER-LEVEL FUNCTIONS πŸ¦‹

🌟 encode 🌟

Take a set of options, and return a two-letter code β€” that's the extension to add to the method to incorporate the extensions β€” plus a list (arrayref) of the extensions represented. πŸͺ„

🌈 SYNOPSIS 🌈

             my ($ext, $opt) =
               Class::MethodMaker::OptExt->encode([qw( static type foobar )]);

πŸ’œ ARGUMENTS πŸ’œ

  • options β€” The options to encode, as an arrayref of option names. 🧾

πŸ“ RETURNS πŸ“

  • ext β€” A code (string) to append to a methodname to represent the options used. 🏷️
  • opts β€” The options represented by the ext. This is generally a subset of those provided in options, because not all general options are handled by an encoded methodname. 🎯

🧚 CLASS HIGHER-LEVEL PROCEDURES 🧚

nothing here in the original β€” empty section energy 🫧

🌸 INSTANCE CONSTRUCTION 🌸

nothing here in the original β€” empty section energy 🫧

πŸŽ€ INSTANCE COMPONENTS πŸŽ€

nothing here in the original β€” empty section energy 🫧

πŸ‘‘ INSTANCE HIGHER-LEVEL FUNCTIONS πŸ‘‘

nothing here in the original β€” empty section energy 🫧

πŸ’… INSTANCE HIGHER-LEVEL PROCEDURES πŸ’…

nothing here in the original β€” empty section energy 🫧

🌈 EXAMPLES 🌈

no examples are listed in the original β€” tragic, honestly 😭

πŸ’€ BUGS πŸ’€

no bugs are listed in this section in the original β€” suspicious but we move πŸ’€

πŸ› REPORTING BUGS πŸ›

Email the development mailing list "class-mmaker-devel@lists.sourceforge.net". πŸ“§

πŸ‘‘ AUTHOR πŸ‘‘

Martyn J. Pearce. πŸ‘‘

Copyright (c) 2003 Martyn J. Pearce. This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself. πŸ“œ

🌈 SEE ALSO 🌈

the original SEE ALSO section has no references β€” it's giving empty, bestie 🌸


mwah πŸ’… this page is brought to you by source/version perl v5.42.0, dated 2025-07-25, and titled Class::...:OptExt(3) β€” bye bestie, go slay some Perl 🫢

πŸ“¦ where this page comes from