[Grok-dev] Using catalog to search for objects of a certain type

Sebastian Ware sebastian at urbantalk.se
Wed Sep 29 14:17:38 EDT 2010


You can index methods on an adapter that return the name of the interface or any other calculated data. The interface of the adapter is the context of your index. Have the adapter adapter the objects you want indexed.

Mvh Sebastian

Sent from my iPad

On 29 sep 2010, at 19.55, jure <jcerjak at termitnjak.si> wrote:

>  Hi,
> 
> is it possible in Grok to search for objects based on the interface they 
> provide and their location? Something similar to plone's object_provides 
> and path indices:
> 
>      return catalog(object_provides=ISession.__identifier__,
>                        path='/'.join(context.getPhysicalPath()),
>                         ...)
> 
> 
> Cheers,
> 
> jure
> _______________________________________________
> Grok-dev mailing list
> Grok-dev at zope.org
> https://mail.zope.org/mailman/listinfo/grok-dev


More information about the Grok-dev mailing list