Plugin(3pm)

πŸ“¦ version 2.1.1, in arch rolling

🌸 Lire::Config::Plugin β€” the value object for plugin config πŸŽ€

So bestie, this page is from LogReport's Lire Documentation, and it's the manual for Plugin(3pm) β€” a Perl module. It's a config object that holds the name of whichever plugin got selected, plus that plugin's options. That's the whole vibe. πŸ’…


✨ SYNOPSIS ✨

use Lire::Config::Plugin;

Literally that's it, that's the whole setup. 🫢


πŸ’– DESCRIPTION πŸ’–

Okay so picture this: this configuration object keeps track of two things β€” the name of a selected plugin, and its options. That's it. That's the assignment and it ate. ✨


πŸ¦‹ get_plugin()

Returns the plugin that's currently selected. Like, right now. The one you picked. πŸ‘‘

πŸŽ€ set_plugin( $plugin )

Changes which plugin is selected. Here's the important bit, ngl: if the selected plugin gets changed, a new property set will be created from the properties that plugin defines. So it's not just swapping a name, it's rebuilding the whole little property situation. πŸ”₯

🌈 get_properties_spec()

Returns the TypeSpec used to specify the plugin's properties. Lowkey important caveat: this method will return an empty RecordSpec when the plugin didn't define any properties. And if you'd rather just check first, you can use the has_properties() method to see whether the Plugin actually defined configuration properties at all. iykyk πŸ’…

⭐ has_properties()

Returns a boolean value telling you whether the current plugin is configurable. Yes/no, true/false, that kind of moment. πŸ™ˆ

πŸ“ get_properties()

Returns the Lire::Config::Dictionary object that holds the plugin configuration. It's giving "the actual container of the goods." πŸŽ€

🧚 as_value()

Returns a hash reference with two keys: 'plugin', which contains the selected plugin, and 'properties', which is a hash reference containing the plugin's properties. Two keys, no cap. ✨

πŸ’œ get( $name )

Delegates to the Dictionary which contains the plugin's properties. Not me just passing the message along 😭

🌸 set( $name, $value )

Delegates to the Dictionary which contains the plugin's properties. Same energy, but with a value. 🫢

πŸ”₯ is_set( $name )

Delegates to the Dictionary which contains the plugin's properties. Three for three, iconic. πŸ‘‘


Quick vibe check: get, set and is_set all just delegate to the same Dictionary that holds the plugin's properties β€” so if you're confused about behaviour, the Dictionary is where the real main character energy lives. πŸ’€

🌟 the cute sign-off 🌟

This page is from Lire 2.1.1, dated 2025-09-28, and it's the Plugin(3pm) manual page from LogReport's Lire Documentation. Slay, go configure some plugins bestie πŸ’–βœ¨πŸŽ€

πŸ“¦ where this page comes from