perldoc > Class::MOP::Method

📖 NAME

Class::MOP::Method - Method Meta Object

🚀 Quick Reference

Use CaseCommandDescription
Create a method meta-objectClass::MOP::Method->wrap($code, %options)Wraps a coderef or method instance into a method meta-object.
Clone a method$metamethod->clone(%params)Shallow clones the method object, sharing the subroutine reference.
Get method body$metamethod->bodyReturns the method's subroutine reference.
Get method name$metamethod->nameReturns the method's short name.
Get package name$metamethod->package_nameReturns the package where the method was defined.
Get fully qualified name$metamethod->fully_qualified_nameReturns "Package::Name::method".
Get associated metaclass$metamethod->associated_metaclassReturns the Class::MOP::Class object if set.
Get original method (clone)$metamethod->original_methodReturns the method object from which this was cloned.
Get original name$metamethod->original_nameFirst defined name in clone chain.
Get original package name$metamethod->original_package_nameFirst defined package in clone chain.
Get original fully qualified name$metamethod->original_fully_qualified_nameFirst defined fully qualified name.
Check if stub$metamethod->is_stubReturns true if method is a stub (e.g., sub foo;).
Attach to class$metamethod->attach_to_class($metaclass)Sets the associated metaclass.
Detach from class$metamethod->detach_from_classRemoves associated metaclass.
Execute method$metamethod->execute(...)Invokes the method with given arguments.
Get meta classClass::MOP::Method->metaReturns the metaclass instance for this class.

🔖 VERSION

version 2.2200

📝 DESCRIPTION

The Method Protocol is very small, since methods in Perl 5 are just subroutines in a specific package. We provide a very basic introspection interface.

🔧 METHODS

👥 AUTHORS

⚖️ COPYRIGHT AND LICENSE

This software is copyright (c) 2006 by Infinity Interactive, Inc.

This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.

Class::MOP::Method
📖 NAME 🚀 Quick Reference 🔖 VERSION 📝 DESCRIPTION 🔧 METHODS 👥 AUTHORS ⚖️ COPYRIGHT AND LICENSE

Generated by phpman v4.9.26-1-g511901d · Markdown · JSON · MCP Author: Che Dong Under GNU General Public License
2026-08-07 18:22 @2600:1f28:365:80b0:18ab:df6:7e48:ac07
CrawledBy CCBot/2.0 (https://commoncrawl.org/faq/)
Valid XHTML 1.0 Transitional!Valid CSS!
Enhanced by LLM: deepseek-v4-flash / taotoken.net / www.chedong.com - original format

^_top_^