Changes for version 0.16
- BACKWARDS INCOMPATIBLE CHANGE: Pass the match object into rule
- blocks rather than assigning $1, $2, $3. Use ->pos(1), (2), (3),
- etc. instead. This cleans up the code a lot and makes
- Path-Dispatcher more flexible.
- Add support for named captures
- Make all attributes read-only. If you need something to be read-write, I am open to such a change. Just let me know!
- Make _dispatcher_rule private
- Remove trace/readable_attribute/name support. This wants to be implemented in a different, better, more comprehensive way.
- Add documentation for shell tab completion
- Plenty other updated documentation
Documentation
A cookbook for Path::Dispatcher
Modules
flexible and extensible dispatch
a list of matches
the result of a successful rule match
path and some optional metadata
"has a list of rules"
predicate and codeblock
any rule must match
always matches
predicate is any subroutine
redispatch
matches only the empty path
one of a list of strings must match
predicate is a string equality
all rules must match
match path's metadata
predicate is a regular expression
a sequence of rules
predicate is a list of tokens
rules under a predicate
Provides
in lib/Path/Dispatcher/Rule/Chain.pm