CatalystX::Declare::Keyword::View - Declare Catalyst Views


NAME

CatalystX::Declare::Keyword::View - Declare Catalyst Views


SYNOPSIS

    use CatalystX::Declare;
    view MyApp::Web::View::Example
        extends Catalyst::View::TT 
        with    MyApp::Web::ViewRole::Caching {
        after process (Object $ctx) {
            $ctx->log->debug('done processing at ' . time)
                if $ctx->debug;
        }
            }


DESCRIPTION

This handler is a direct extension of the CatalystX::Declare::Keyword::Component manpage and provides a view keyword to declare a catalyst view. Currently, the only things this declaration does is setting up a Moose class like the MooseX::Declare manpage does, provide CLASS to its scope and default the superclass to the Catalyst::View manpage.

See class in the MooseX::Declare manpage for more information on this kind of keyword. Since views do not take actions, no special handling of roles is required, other than with controller roles. So if you want to write roles for views, simply use the role in the MooseX::Declare manpage syntax.


SUPERCLASSES

the CatalystX::Declare::Keyword::Component manpage


METHODS

These methods are implementation details. Unless you are extending or developing the CatalystX::Declare manpage, you should not be concerned with them.

default_superclasses

    List[Str] Object->default_superclasses ()

Defaults to the Catalyst::View manpage.


SEE ALSO

the CatalystX::Declare manpage
the CatalystX::Declare::Keyword::Component manpage
class in the MooseX::Declare manpage


AUTHOR

See AUTHOR in the CatalystX::Declare manpage for author information.


LICENSE

This program is free software; you can redistribute it and/or modify it under the same terms as perl itself.

 CatalystX::Declare::Keyword::View - Declare Catalyst Views