OpenQuizz
Une application de gestion des contenus pédagogiques
Submount Class Reference
Inheritance diagram for Submount:
Collaboration diagram for Submount:

Public Member Functions

def __init__ (self, path, rules)
 
def get_rules (self, map)
 

Data Fields

 path
 
 rules
 

Detailed Description

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>``.

Constructor & Destructor Documentation

◆ __init__()

def __init__ (   self,
  path,
  rules 
)

Member Function Documentation

◆ get_rules()

def get_rules (   self,
  map 
)
Subclasses of `RuleFactory` have to override this method and return
an iterable of rules.

Reimplemented from RuleFactory.

Field Documentation

◆ path

path

◆ rules

rules

The documentation for this class was generated from the following file: