NAME

Yukki::Web - the Yukki web server

VERSION

version 0.991_004

DESCRIPTION

This class handles the work of dispatching incoming requests to the various controllers.

ATTRIBUTES

router

This is the Path::Router that will determine where incoming requests are sent. It is automatically set to a Yukki::Web::Router instance.

plugins

my @plugins        = $app->all_plugins;
my @format_helpers = $app->format_helper_plugins;
my @formatters     = $app->format_plugins;

This attribute stores all the loaded plugins.

METHODS

component

Helper method used by "controller" and "view".

controller

my $controller = $app->controller($name);

Returns an instance of the named Yukki::Web::Controller.

view

my $view = $app->view($name);

Returns an instance of the named Yukki::Web::View.

dispatch

my $response = $app->dispatch($env);

This is a PSGI application in a method call. Given a PSGI environment, maps that to the appropriate controller and fires it. Whether successful or failure, it returns a PSGI response.

session_middleware

enable $app->session_middleware;

Returns the setup for the PSGI session middleware.

munge_label

my $link = $app->munch_label("This is a label");

Turns some label into a link slug using the standard means for doing so.

all_plugins

A convenience accessor that returns plugins as a list.

format_helper_plugins

Returns all the format helper plugins as a list.

formatter_plugins

Returns all the formatter plugins as a list.

AUTHOR

Andrew Sterling Hanenkamp <hanenkamp@cpan.org>

COPYRIGHT AND LICENSE

This software is copyright (c) 2017 by Qubling Software LLC.

This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.