1CGI::Application::StrucUtsuerredC:o:nTtorCoiGlbIsu::t::eASdptpaPlreitrcelart(Di3oo)cnu:m:eSnttrautcitounred::Tools::Starter(3)
2
3
4

NAME

6       CGI::Application::Structured::Tools::Starter - template based module
7       starter for CGI::Application::Structured apps.
8

SYNOPSIS

10           use Module::Starter qw(
11               Module::Starter::Simple
12               Module::Starter::Plugin::Template
13               CGI::Application::Structured::Tools::Starter
14           );
15
16           Module::Starter->create_distro(%args);
17

ABSTRACT

19       The prefered method for using this module is via the "cas-starter.pl"
20       in scripts script.
21

VERSION

23       Version 0.006
24

DESCRIPTION

26       This is a plugin for Module::Starter that builds a skeleton
27       CGI::Application::Structured module with all the extra files needed to
28       package it for CPAN. It also generates
29         - an CGI::Application::Structured controller base class for your
30       modules
31         - a customized CGI::Application::Dispatch subclass
32         - a preconfigured development config file
33         - a server.pl that runs out of the box
34         - helper scripts to generate Controller modules subclasses
35         - a helper script to generate DBIx::Class schema and result classes.
36
37       This module is inspired Module::Starter::Plugin::CGIApp by Jaldhar H.
38       Vyas .
39

METHODS

41   new ( %args )
42       This method calls the "new" supermethod from
43       Module::Starter::Plugin::Template and then initializes the template
44       store and renderer. (See "templates" and "renderer" below.)
45
46   create_distro ( %args )
47       This method works as advertised in Module::Starter.
48
49   create_t( @modules )
50       This method creates a bunch of *.t files.  @modules is a list of all
51       modules in the distribution.
52
53   render( $template, \%options )
54       This method is subclassed from Module::Starter::Plugin::Template.
55
56       It is given an HTML::Template and options and returns the resulting
57       document.
58
59       Data in the "Module::Starter" object which represents a reference to an
60       array @foo is transformed into an array of hashes with one key called
61       $foo_item in order to make it usable in an HTML::Template "TMPL_LOOP".
62       For example:
63
64           $data = ['a'. 'b', 'c'];
65
66       would become:
67
68           $data = [
69               { data_item => 'a' },
70               { data_item => 'b' },
71               { data_item => 'c' },
72           ];
73
74       so that in the template you could say:
75
76           <tmpl_loop data>
77               <tmpl_var data_item>
78           </tmpl_loop>
79
80   renderer ()
81       This method is subclassed from Module::Starter::Plugin::Template but
82       doesn't do anything as the actual template is created by "render" in
83       this implementation.
84
85   templates ()
86       This method is subclassed from Module::Starter::Plugin::Template.
87
88       It reads in the template files and populates the object's templates
89       attribute. The module template directory is found by checking the
90       "MODULE_TEMPLATE_DIR" environment variable and then the config option
91       "template_dir".
92
93   create_MANIFEST_SKIP()
94       This method creates a "MANIFEST.SKIP" file in the distribution's
95       directory so that unneeded files can be skipped from inclusion in the
96       distribution.
97
98   create_perlcriticrc ()
99       This method creates a "perlcriticrc" in the distribution's test
100       directory so that the behavior of "perl-critic.t" can be modified.
101
102   create_server_pl ()
103       This method creates "server.pl" in the distribution's root directory.
104
105   create_server_pl ()
106       This method creates "config-test.pl" in the distribution's root/config
107       directory.
108
109   create_create_pl ()
110       This method creates "create_controller.pl" in the distribution's
111       app/script directory.
112
113   create_tmpl ()
114       This method takes all the template files ending in .tmpl (representing
115       HTML::Template's and installs them into a directory under the distro
116       tree.  For instance if the distro was called "Foo-Bar", the templates
117       would be installed in "Foo-Bar/templates".
118
119       Note the files will just be copied over not rendered.
120
121   create_submodule ()
122       Implements a default "Home" subclass of the main module.  This module
123       will be auto configured as the default module in the Dispatch subclass.
124
125   create_submodule ()
126       Implements a default controller baseclass (main module).
127
128   create_dbic_pl ()
129       This method creates "create_dbic_schema.pl" in the distribution's
130       root/script/ directory.
131
132   create_dispatch ()
133       Implements a CGI::Application::Dispatch subclass for this app in the
134       lib directory under the main modules directory.
135

BUGS

137       Please report any bugs or feature requests to through the web interface
138       at <http://rt.cpan.org>. I will be notified, and then you'll
139       automatically be notified of progress on your bug as I make changes.
140

AUTHOR

142       Gordon Van Amburg, <vanamburg at cpan.org>
143

ACKNOWLEDGEMENT

145       This module borrows heavily from <Module::Starter::Plugin::CGIApp> by
146       Jaldhar H. Vyas, <jaldhar at braincells.com>
147
149       This program is free software; you can redistribute it and/or modify it
150       under the same terms as Perl itself.
151

SEE ALSO

153       CGI::Application::Structured-starter, CGI::Application::Structured,
154       Titanium, CGI::Application, Module::Starter::Plugin::CGIApp
155
156
157
158perl v5.12.0                   CGI2:0:0A9p-p1l0i-c1a5tion::Structured::Tools::Starter(3)
Impressum