GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages


Manual Reference Pages  -  MOOSEX::APP::WRITINGPLUGINS (3)

.ds Aq ’

NAME

MooseX::App::WritingPlugins - Writing plugins for MooseX::App

CONTENTS

SYNOPSIS



 package MooseX::App::Plugin::MyPlugin;

 use Moose::Role;

 sub plugin_metaroles {
     my ($self,$class) = @_;
     return {
         class   => [MooseX::App::Plugin::MyPlugin::Meta::Class],
     }
 }

 around initialize_command_class => sub {
    ...
 };



DESCRIPTION

Plugins are implemented as Moose roles and must reside in the MooseX::App::Plugin::* namespace. Metaclasses can be altered via the ’plugin_metaroles’ callback method. Furthermore Moose method modifiers (around, after, before) can be used to alter the behaviour of MooseX::App or its meta classes.

CALLBACKS

    plugin_metaroles

Optional callback method that should return a hash reference specifying which metaroles will be applied to the class metaclass and its contained metaclasses and helper classes.

Each key should in turn point to an array reference of role names.

It accepts the following keys:
o class
o attribute
o method
o wrapped_method
o instance
o constructor
o destructor
o error

METACLASSES

Most of MooseX-App behaviour is implemented in metaclass roles. When writing plugins you will most likely need to alter/augument the behaviour of these roles. Implementation details can be found in the respective packages.
o MooseX::App::Meta::Role::Class::Base is applied to the base metaclass
o MooseX::App::Meta::Role::Class::Command is applied to the command metaclass
o MooseX::App::Meta::Role::Attribute::Option is applied to all attributes in the base and command meta classes
Search for    or go to Top of page |  Section 3 |  Main Index


perl v5.20.3 MOOSEX::APP::WRITINGPLUGINS (3) 2015-01-10

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with manServer 1.07.