Satoshi Azuma > Nephia-0.85 > Nephia::Plugin::Basic

Download:
Nephia-0.85.tar.gz

Dependencies

Annotate this POD

Website

View/Report Bugs
Source   Latest Release: Nephia-0.87

NAME ^

Nephia::Plugin::Basic - A Nephia plugin that provides basic DSL

DESCRIPTION ^

This plugin provides req and param DSL for Nephia.

DSL ^

req

    app {
        my $req = req; # returns Nephia::Request object
        ...
    };

Returns Nephia::Request object.

param

    app {
        my $id     = param('id'); # returns query-parameter that named 'id'
        my $params = param;       # returns query-parameters as hashref
    };

Returns query-parameter.

redirect

    app {
        redirect '/to/some_path';
    };

Returns response object with Location header.

AUTHOR ^

ytnobody <ytnobody@gmail.com>

SEE ALSO ^

Nephia::Plugin

syntax highlighting: