NAME
Mouse::Role - define a role in Mouse
KEYWORDS
meta -> Mouse::Meta::Role
Returns this role's metaclass instance.
before (method|methods) => Code
Sets up a "before" method modifier. See "before" in Moose or "before" in Class::Method::Modifiers.
after (method|methods) => Code
Sets up an "after" method modifier. See "after" in Moose or "after" in Class::Method::Modifiers.
around (method|methods) => Code
Sets up an "around" method modifier. See "around" in Moose or "around" in Class::Method::Modifiers.
- super
-
Sets up the "super" keyword. See "super" in Moose.
- override ($name, &sub)
-
Sets up an "override" method modifier. See "Role/override" in Moose.
- inner
-
This is not supported and emits an error. See "Role" in Moose.
- augment ($name, &sub)
-
This is not supported and emits an error. See "Role" in Moose.
has (name|names) => parameters
Sets up an attribute (or if passed an arrayref of names, multiple attributes) to this role. See "has" in Mouse.
confess error -> BOOM
"confess" in Carp for your convenience.
blessed value -> ClassName | undef
"blessed" in Scalar::Util for your convenience.
MISC
import
Importing Mouse::Role will give you sugar.
unimport
Please unimport Mouse (no Mouse::Role
) so that if someone calls one of the keywords (such as "has") it will break loudly instead breaking subtly.