X-Git-Url: http://git.ithinksw.org/philo.git/blobdiff_plain/54d1617957cfa3a8c9ffd714ad6c4bef09e727de..1070d1cba12c37121972545925a5256dd8138b76:/philo/models/base.py diff --git a/philo/models/base.py b/philo/models/base.py index 466b60a..46e9ac5 100644 --- a/philo/models/base.py +++ b/philo/models/base.py @@ -340,7 +340,7 @@ class TreeManager(models.Manager): def get_with_path(self, path, root=None, absolute_result=True, pathsep='/', field='slug'): """ - If ``absolute_result`` is ``True``, returns the object at ``path`` (starting at ``root``) or raises a :exception:`DoesNotExist` exception. Otherwise, returns a tuple containing the deepest object found along ``path`` (or ``root`` if no deeper object is found) and the remainder of the path after that object as a string (or None if there is no remaining path). + If ``absolute_result`` is ``True``, returns the object at ``path`` (starting at ``root``) or raises a :class:`DoesNotExist` exception. Otherwise, returns a tuple containing the deepest object found along ``path`` (or ``root`` if no deeper object is found) and the remainder of the path after that object as a string (or None if there is no remaining path). .. note:: If you are looking for something with an exact path, it is faster to use absolute_result=True, unless the path depth is over ~40, in which case the high cost of the absolute query may make a binary search (i.e. non-absolute) faster.