[Welcome] [TitleIndex] [WordIndex

Quixote's developers have found that it's default path traversal algorithm results in applications that usually have nice URL schemes. However, if you would like to use some other approach, Quixote makes it easy (see TailEater for some details on motivation and for a recipe that was originallly written for Quixote 1). For example:

class RootDirectory(Directory):
    def _q_traverse(self, path):
        return 'Path is %s' % ('/'.join(path))

This does away with _q_exports and all the rest of the usual Directory methods. For example, you could lookup that path in dictionary of paths and return the data found. You also could implement something like Django's URL dispatcher (anyone want to write a recipe?).


2010-09-22 22:14