Re: [Zope] Avoiding acquisition aka testing for contained objects

2000-11-16 Thread Dieter Maurer
Stefan H. Holek writes: > If I want to know whether a certain object is contained in > the current folder I do this: > > > yes it's here > > not here > > > Id like to know whether this is the best/most efficient way to do it. > Things like hasattr() are subject to aquisition i

Re: [Zope] Avoiding acquisition aka testing for contained objects

2000-11-16 Thread Stefan H. Holek
On Wed, 15 Nov 2000, Johan Carlsson wrote: > > If I want to know whether a certain object is contained in > > the current folder I do this: > > > > > > yes it's here > > > > not here > > > hasattr(self.aq_base, 'index_html') should probably work. > > aq_base returns the unwrapped base

Re: [Zope] Avoiding acquisition aka testing for contained objects

2000-11-15 Thread Johan Carlsson
> If I want to know whether a certain object is contained in > the current folder I do this: > > > yes it's here > > not here > > > Id like to know whether this is the best/most efficient way to do it. > Things like hasattr() are subject to aquisition i.e. they would find > an index_ht

[Zope] Avoiding acquisition aka testing for contained objects

2000-11-15 Thread Stefan H. Holek
If I want to know whether a certain object is contained in the current folder I do this: yes it's here not here Id like to know whether this is the best/most efficient way to do it. Things like hasattr() are subject to aquisition i.e. they would find an index_html method along the acquis