1Catalyst::Dispatcher(3)User Contributed Perl DocumentatioCnatalyst::Dispatcher(3)
2
3
4

NAME

6       Catalyst::Dispatcher - The Catalyst Dispatcher
7

SYNOPSIS

9       See Catalyst.
10

DESCRIPTION

12       This is the class that maps public urls to actions in your Catalyst
13       application based on the attributes you set.
14

METHODS

16       new
17
18       Construct a new dispatcher.
19
20       $self->preload_dispatch_types
21
22       An arrayref of pre-loaded dispatchtype classes
23
24       Entries are considered to be available as "Catalyst::Dis‐
25       patchType::CLASS" To use a custom class outside the regular "Catalyst"
26       namespace, prefix it with a "+", like so:
27
28           +My::Dispatch::Type
29
30       $self->postload_dispatch_types
31
32       An arrayref of post-loaded dispatchtype classes
33
34       Entries are considered to be available as "Catalyst::Dis‐
35       patchType::CLASS" To use a custom class outside the regular "Catalyst"
36       namespace, prefix it with a "+", like so:
37
38           +My::Dispatch::Type
39
40       $self->detach( $c, $command [, \@arguments ] )
41
42       Documented in Catalyst
43
44       $self->dispatch($c)
45
46       Delegate the dispatch to the action that matched the url, or return a
47       message about unknown resource
48
49       $self->forward( $c, $command [, \@arguments ] )
50
51       Documented in Catalyst
52
53       $self->prepare_action($c)
54
55       Find an dispatch type that matches $c->req->path, and set args from it.
56
57       $self->get_action( $action, $namespace )
58
59       returns a named action from a given namespace.
60
61       $self->get_action_by_path( $path );
62
63       Returns the named action by its full path.
64
65       $self->get_actions( $c, $action, $namespace )
66
67       $self->get_containers( $namespace )
68
69       Return all the action containers for a given namespace, inclusive
70
71       $self->uri_for_action($action, \@captures)
72
73       Takes a Catalyst::Action object and action parameters and returns a URI
74       part such that if $c->req->path were this URI part, this action would
75       be dispatched to with $c->req->captures set to the supplied arrayref.
76
77       If the action object is not available for external dispatch or the dis‐
78       patcher cannot determine an appropriate URI, this method will return
79       undef.
80
81       $self->register( $c, $action )
82
83       Make sure all required dispatch types for this action are loaded, then
84       pass the action to our dispatch types so they can register it if
85       required.  Also, set up the tree with the action containers.
86
87       $self->setup_actions( $class, $context )
88

AUTHOR

90       Sebastian Riedel, "sri@cpan.org" Matt S Trout, "mst@shadowcatsys‐
91       tems.co.uk"
92
94       This program is free software, you can redistribute it and/or modify it
95       under the same terms as Perl itself.
96
97
98
99perl v5.8.8                       2007-09-20           Catalyst::Dispatcher(3)
Impressum