Yukki::Role::App - the role Yukki app-classes implement
version 0.140290
The Yukki and Yukki::Web classes fulfill this role.
my $obj = $self->model($name, \%params);
Given a name and an optional hash of parameters, return an instance of a Yukki::Model.
my $obj = $self->view($name);
Given a name, return a view object.
my $obj = $self->controller($name);
Given a name, return a controller object.
my $file = $self->locate($base_path, @path_parts);
Given a configuration key in $base_path and some @path_parts to append, return a Path::Class::File representing that file under the Yukki installation.
$base_path
@path_parts
my $dir = $self->locate_dir($base_path, @path_parts);
Given a configuration key in $base_path and some @path_parts to append, return a Path::Class::Dir representing that directory under the Yukki installation.
my $access_is_ok = $self->check_access({ user => $user, repository => $repository, needs => $needs, });
The user is optional. It should be an object returned from Yukki::Model::User. The repository is required and should be the name of the repository the user is trying to gain access to. The needs is the access level the user needs. It must be an "AccessLevel" in Yukki::Types.
user
repository
needs
The method returns a true value if access should be granted or false otherwise.
Andrew Sterling Hanenkamp <hanenkamp@cpan.org>
This software is copyright (c) 2014 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.
To install Yukki, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Yukki
CPAN shell
perl -MCPAN -e shell install Yukki
For more information on module installation, please visit the detailed CPAN module installation guide.