class documentation

class Submount(RuleFactory):

View In Hierarchy

Like Subdomain but prefixes the URL rule with a given string:

url_map = Map([
    Rule('/', endpoint='index'),
    Submount('/blog', [
        Rule('/', endpoint='blog/index'),
        Rule('/entry/<entry_slug>', endpoint='blog/show')
    ])
])

Now the rule 'blog/show' matches /blog/entry/<entry_slug>.

Method __init__ Undocumented
Method get​_rules Subclasses of RuleFactory have to override this method and return an iterable of rules.
Instance Variable path Undocumented
Instance Variable rules Undocumented
def __init__(self, path, rules):

Undocumented

Parameters
path:strUndocumented
rules:t.Iterable[RuleFactory]Undocumented
def get_rules(self, map):
Subclasses of RuleFactory have to override this method and return an iterable of rules.
Parameters
map:MapUndocumented
Returns
t.Iterator[Rule]Undocumented
path =

Undocumented

rules =

Undocumented