extended catalog queries in Zope 3

from blog Secret Weblog, | ↗ original
↗ original
Yesterday I managed to build something in just a few hours in Zope 3 that I wouldn't have been able to build so easily in Zope 2. What I've built is an extended query system for the Zope 3 catalogs.Yesterday I managed to build something in just a few hours in Zope 3 that I wouldn't have been able to build so easily in Zope 2. What I've built is an extended query system for the Zope 3 catalogs. A sample query looks like this:A sample query looks like this: q = zapi.getUtility(interfaces.IExtendedQuery) q = zapi.getUtility(interfaces.IExtendedQuery) t1 = ('catalog', 'fulltext') t1 = ('catalog', 'fulltext') a1 = ('catalog', 'a1') a1 = ('catalog', 'a1') r = q.searchResults(And(Text(t1, 'foo'),...r = q.searchResults(And(Text(t1, 'foo'),...