Zope catalog index for paths
Project description
Introduction
This is an index that supports depth limiting, and the ability to build a structure usable for navtrees and sitemaps. The actual navtree implementations are not (and should not) be in this Product, this is the index implementation only.
Assumptions
EPI makes an assumption about the catalog and index being in the same container as all the content. This makes a lot of sense in a Plone setting, but might not work as expected in other scenarios.
A query like /plonesite/folder, start_level=0 is transformed internally to /folder, start_level=1. This avoids touching the rather large plonesite set which contains reference to all content in your site.
Features
Can construct a site map with a single catalog query
Can construct a navigation tree with a single catalog query
Usage
- catalog(path='some/path')
search for all objects below some/path (recursive, equivalent to depth = -1)
- catalog(path={'query' : 'some/path', 'depth' : 0})
search for the object with the given path.
- catalog(path={'query' : 'some/path', 'depth' : 2 )
search for all objects below some/path but only down to a depth of 2
- catalog(path={'query' : 'some/path', 'navtree' : 1 )
search for all objects below some/path for rendering a navigation tree. This includes all objects below some/path up to a depth of 1 and all parent objects.
- catalog(path={'query' : 'some/path', 'navtree' : 1, 'depth': 0 })
search for all objects below some/path for rendering a breadcrumb trail. This includes only the parent objects themselves.
- catalog(path={'query' : 'some/path', 'navtree':1, 'navtree_start':1})
search for all objects below some/path for rendering a partial navigation tree. This includes all objects below the path but stops 1 level above the root. The given path is included, even if it is at a lower level in the portal than the start parameter would allow.
- catalog(path={'query' : 'some/path', 'navtree':1, 'depth':0, 'navtree_start':1})
search for all objects below some/path for rendering a partial breadcrumb trail. This includes all parents below the path but stops 1 level above the root. The given path is included, even if it is at a lower level in the portal than the start parameter would allow.
Credits
Zope Corporation for the initial PathIndex code
Helge Tesdal from Jarn for the ExtendedPathIndex implementation
Alec Mitchell for the navtree and listing optimizations
License
This software is released under the ZPL license.
Changelog
2.4.1 - September 28, 2008
Fix typo in setup.py which broke installation of the egg [ree]
2.4 - September 11, 2006
Relaxed a check for path only allowing strings so far. Now we except all basestrings. This closes http://dev.plone.org/plone/ticket/5617. [hannosch]
Converted log infrastructure to use Python’s logging module instead zLOG. [hannosch]
2.3 - December 18, 2005
Added some extra debug information when an improper path is cataloged. [sidnei]
2.2 - October 7, 2005
Add seperate index structures on the parent path and the full path of all objects. This significantly improves scaling for navtrees, breadcrumbs, and listings. [alecm]
Assume that EPI is used inside same container as content and use relative search instead of absolute - basically transforming / plonesite search to / search with startlevel set to 1 instead of 0. [tesdal]
2.1 - May 20, 2005
Implement ‘indexed_attrs’ support for ExtendedPathIndex.
Prevent navigation tree queries from stopping prematurely if the queried-for path does not actually exist in the index, but its parents do.
1.0
Path index capable of generating a navigation tree structure from cataloged data.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Hashes for Products.ExtendedPathIndex-2.4.1.zip
Algorithm | Hash digest | |
---|---|---|
SHA256 | 98be4fc81d2f50e17d9aa40b33b717e20b059326ec1b8bdb8efaa51055dcbcbb |
|
MD5 | 6994421bc87e58f7cfaa28702468e93c |
|
BLAKE2b-256 | d14bb588c88c9e10e19129e04989b4b64860dd9b873005bd07ca590b3f7ca3b6 |