Egg::Manager::View - View manager for Egg.


Egg-Release documentation  | view source Contained in the Egg-Release distribution.

Index


NAME

Top

Egg::Manager::View - View manager for Egg.

DESCRIPTION

Top

It is a module to offer Egg the view function.

When the view_manager method of Egg is called, the handler class for the view is returned.

CONFIGURATION

Top

The configuration of the model is done to 'VIEW' by the ARRAY form.

  VIEW => [
    [ Mason => {
       ...........
       ....
       } ],
    [ HT => {
       ...........
       ....
       } ],
    ],

METHODS

Top

Because this class is registered in @ISA of the project, the method can be used directly from the object of the project.

  $project->view( ... );

init_view

When starting for the view, it initializes it.

setup_view

The setup for the view is done.

view ([LABEL_STRING])

The object of the specific view specified with LABEL_STRING is returned.

When LABEL_STRING is omitted, the object of the view of default is restored.

  my $mason= $e->view;
     or
  my $mason= $e->view('mason');

The setting of the first element set to the configuration becomes default.

It is Egg::View::Mason in the view. With Egg::View::HT However, Ts belongs.

is_view ([LABEL_STRING])

If the view corresponding to LABEL_STRING can be used, true is returned.

  unless ($e->is_model('mason')) {
     die q{ mason is not active. };
  }

HANDLER METHODS

Top

It is view manager's main body.

Egg::Manager is succeeded to and the main function is used.

The method is called by way of view_manager.

This class is succeeding to Egg::Manager and it doesn't have a peculiar method.

SEE ALSO

Top

Egg::Release, Egg::Manager, Egg::View::Mason, Egg::View::HT,

AUTHOR

Top

Masatoshi Mizuno <lushe&64;cpan.org>

COPYRIGHT AND LICENSE

Top


Egg-Release documentation  | view source Contained in the Egg-Release distribution.