1Maypole::Config(3)    User Contributed Perl Documentation   Maypole::Config(3)
2
3
4

NAME

6       Maypole::Config - Maypole Configuration Class
7

DESCRIPTION

9       This class stores all configuration data for your Maypole application.
10

METHODS

12       View related
13
14       application_name
15
16       This should be a string containing your application's name.
17
18       Optional. Is used in the factory templates.
19
20       rows_per_page
21
22       This is the number of rows your application should display per page.
23
24       Optional.
25
26       tables
27
28       Contains a list of all tables, if supported by model.
29
30       template_extension
31
32       Optional template file extension.
33
34       template_root
35
36       This is where your application can find its templates.
37
38       uri_base
39
40       This is the URI base that should be prepended to your application when
41       Maypole makes URLs.
42
43       view
44
45       The name of the view class for your Maypole Application. Defaults to
46       "Maypole::View::TT".
47
48       view_options
49
50       A hash of configuration options for the view class. Consult the docu‐
51       mentation for your chosen view class for information on available con‐
52       figuration options.
53
54       Model-Related
55
56       classes
57
58       This config variable contains a list of your view classes. This is set
59       up by the model class, and should not be changed in the view or the
60       config.
61
62       display_tables
63
64       This is a list of the tables that are public to your Maypole applica‐
65       tion. Defaults to all the tables in the database.
66
67       dsn
68
69       The DSN to your database. Follows standard DBD syntax.
70
71       loader
72
73       This is the loader object (n.b. an instance, not a class name). It's
74       set up by the CDBI model to an instance of "Class::DBI::Loader" if it's
75       not initialized before calling setup().
76
77       model
78
79       The name of the model class for your Maypole Application. Defaults to
80       "Maypole::Model::CDBI".
81
82       ok_tables
83
84       This is a hash of the public tables. It is populated automatically by
85       Maypole from the list in display_tables and should not be changed.
86
87       pass
88
89       Password for database user.
90
91       opts
92
93       Other options to the DBI connect call.
94
95       user
96
97       Username to log into the database with.
98
99       Adding additional configuration data
100
101       If your modules need to store additional configuration data for their
102       own use or to make available to templates, add a line like this to your
103       module:
104
105          Maypole::Config->mk_accessors(qw(variable or variables));
106
107       Care is needed to avoid conflicting variable names.
108

SEE ALSO

110       Maypole
111

AUTHOR

113       Sebastian Riedel, "sri@oook.de"
114

AUTHOR EMERITUS

116       Simon Cozens, "simon@cpan.org"
117

LICENSE

119       You may distribute this code under the same terms as Perl itself.
120
121
122
123perl v5.8.8                       2005-11-23                Maypole::Config(3)
Impressum