Yancy::Util - Utilities for Yancy
version 0.020
use Yancy::Util qw( backend ); my $be = load_backend( 'test://localhost', $collections );
This module contains utility functions for Yancy.
my $backend = load_backend( $backend_url, $collections ); my $backend = load_backend( { $backend_name => $arg }, $collections );
Get a Yancy backend from the given backend URL, or from a hash reference with a backend name and optional argument. The $collections hash is the configured collections for this backend.
$collections
A backend URL should begin with a name followed by a colon. The first letter of the name will be capitalized, and used to build a class name in the Yancy::Backend namespace.
Yancy::Backend
The $backend_name should be the name of a module in the Yancy::Backend namespace. The $arg is handled by the backend module. Read your backend module's documentation for details.
$backend_name
$arg
See "Database Backend" in Yancy for information about backend URLs and Yancy::Backend for more information about backend objects.
Yancy
Doug Bell <preaction@cpan.org>
This software is copyright (c) 2018 by Doug Bell.
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 Yancy, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Yancy
CPAN shell
perl -MCPAN -e shell install Yancy
For more information on module installation, please visit the detailed CPAN module installation guide.