Mouse::Util(3pm) | User Contributed Perl Documentation | Mouse::Util(3pm) |
Mouse::Util - Utilities for working with Mouse classes
This document describes Mouse version v2.5.6
use Mouse::Util; # turns on strict and warnings
This module provides a set of utility functions. Many of these functions are intended for use in Mouse itself or MouseX modules, but some of them may be useful for use in your own code.
The following functions are exportable.
"find_meta($class_or_obj)"
The same as "Mouse::Util::class_of()".
"does_role($class_or_obj, $role_or_obj)"
"resolve_metaclass_alias($category, $name, %options)"
"apply_all_roles($applicant, @roles)"
"english_listi(@items)"
The following functions are not exportable.
"Mouse::Util::is_class_loaded($classname) -> Bool"
Returns whether $classname is actually loaded or not. It uses a heuristic which involves checking for the existence of $VERSION, @ISA, and any locally-defined method.
"Mouse::Util::load_class($classname) -> ClassName"
This will load a given $classname (or die if it is not loadable). This function can be used in place of tricks like "eval "use $module ()"" or using "require".
"Mouse::Util::class_of($classname_or_object) -> MetaClass"
"Mouse::Util::get_metaclass_by_name($classname) -> MetaClass"
"Mouse::Util::get_all_metaclass_instances() -> (MetaClasses)"
"Mouse::Util::get_all_metaclass_names() -> (ClassNames)"
"get_linear_isa"
"get_code_info"
"not_supported"
"get_code_package"
"get_code_ref"
Moose::Util
Class::MOP
Sub::Identify
mro
MRO::Compat
2018-11-02 | perl v5.28.0 |