I didn't find in werkzeug, so I wrote one myself. Hope it's useful.

from werkzeug.routing import BaseConverter
class RegexConverter(BaseConverter):
    """
    Matches regular expression::

        Rule('/<regex("pattern"):argu_name>')
    """

    def __init__(self, map, *items):
        BaseConverter.__init__(self, map)
        self.regex = items[0]

How to use it?

'/static/<regex(".*$"):filename>'

-- 
I like python!
UliPad <<The Python Editor>>: http://code.google.com/p/ulipad/
UliSpot <<UliPad Snippets>>: http://ulipad.appspot.com
UliWeb <<simple web framework>>: http://uliwebproject.appspot.com
My Blog: (new)http://http://hi.baidu.com/limodou (old)
http://www.donews.net/limodou

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"pocoo-libs" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/pocoo-libs?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to