On Wed, May 6, 2009 at 20:01, Douglas Cerna <douglasce...@yahoo.com> wrote:
> from zope.app.generations.utility import findObjectsProviding
> can help you.
> You use it like this:
> findObjectsProviding(container, InterfaceYoureLookingFor)
> --- On Wed, 5/6/09, Massimiliano della Rovere
> <massimiliano.dellarov...@gmail.com> wrote:
>> From: Massimiliano della Rovere <massimiliano.dellarov...@gmail.com>
>> Subject: [Zope3-Users] Best way to find normal objects.
>> To: "Mailing List Zope3 Users" <firstname.lastname@example.org>
>> Date: Wednesday, May 6, 2009, 3:46 AM
>> In my application I have to populate some SimpleVocabulary
>> with the
>> object.name (or the Ids) of all object providing a certain
>> These are simple content components, not utilities.
>> They are all stored inside a specific Container: all object
>> interface "IX" are inside
>> - a first method to retrieve them is to get the rootFolder
>> of the site
>> and then rootFolder['container_for_x'].keys().
>> - a second method could be something like getUtilitiesFor(
>> IX ), but I
>> can't use this function, because the objects are not
>> utilities. Is
>> there a getObjectsByInterface( interface ) ?
Zope3-users mailing list