summaryrefslogtreecommitdiff
path: root/docs/tutorials
diff options
context:
space:
mode:
authorChris McDonough <chrism@agendaless.com>2009-12-19 18:40:19 +0000
committerChris McDonough <chrism@agendaless.com>2009-12-19 18:40:19 +0000
commit6225a24982dfaeffbc53f85d214159c08a0dbfc2 (patch)
treef6939169df6a212c1a95972e55007b285930c8e1 /docs/tutorials
parent3809abb4c55ef98541158e4f58593c6c6011034f (diff)
downloadpyramid-6225a24982dfaeffbc53f85d214159c08a0dbfc2.tar.gz
pyramid-6225a24982dfaeffbc53f85d214159c08a0dbfc2.tar.bz2
pyramid-6225a24982dfaeffbc53f85d214159c08a0dbfc2.zip
- Add a ``custom_predicates`` argument to the ``Configurator``
``add_view`` method, the ``bfg_view`` decorator and the attribute list of the ZCML ``view`` directive. If ``custom_predicates`` is specified, it must be a sequence of predicate callables (a predicate callable accepts two arguments: ``context`` and ``request`` and returns ``True`` or ``False``). The associated view callable will only be invoked if all custom predicates return ``True``. Use one or more custom predicates when no existing predefined predicate is useful. Predefined and custom predicates can be mixed freely. - Add a ``custom_predicates`` argument to the ``Configurator`` ``add_route`` and the attribute list of the ZCML ``route`` directive. If ``custom_predicates`` is specified, it must be a sequence of predicate callables (a predicate callable accepts two arguments: ``context`` and ``request`` and returns ``True`` or ``False``). The associated route will match will only be invoked if all custom predicates return ``True``, else route matching continues. Use one or more custom predicates when no existing predefined predicate is useful. Predefined and custom predicates can be mixed freely.
Diffstat (limited to 'docs/tutorials')
0 files changed, 0 insertions, 0 deletions