Re: [Zope] Re - Making non-aware ZClass CatalogAware
as a data point, I used this with an existing ZClass that was also a subclass of Object manager. After the upgrade, things like 'objectValues' would no longer work in the ZClass instance (they'd return no objects). I didn't try to figure out why, I just threw away the changes. So yes, make sure you back up your Data.fs before you play this game.
Alexandre Ratti wrote Hi Alexander,
There was a hack some time ago that allowed to change the base classes for a ZClass. I used it once or twice in 2.0.1. I've never used it in 2.1b.
Take a look at this email: <http://lists.zope.org/pipermail/zope-dev/1999-August/001288.html>. It contains explanations and an external method developped by Andreas Kostyrka.
Be careful with it: better back up your database before trying it!
Cheers.
Alexandre
At 20:40 16/11/1999 -0800, you wrote:
From: Alexander Staubo <alex@mop.no> To: "Zope Mailing List (E-mail)" <zope@zope.org> Subject: [Zope] Making non-aware ZClass CatalogAware Date: Tue, 16 Nov 1999 22:44:05 +0100
I have a bunch of ZClasses that aren't descended from the catalog-aware class-wossname. I need to make them catalog-aware. How do I easily do this? Can I export to XML and somehow import them in again?
-- Alexander Staubo http://www.mop.no/~alex/ "Only two things are infinite, the universe and human stupidity, and I'm not sure about the former." --Albert Einstein
_______________________________________________ Zope maillist - Zope@zope.org http://lists.zope.org/mailman/listinfo/zope No cross posts or HTML encoding! (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope-dev )
-- Anthony Baxter <anthony@interlink.com.au> It's never too late to have a happy childhood.
Anthony Baxter wrote:
as a data point, I used this with an existing ZClass that was also a subclass of Object manager. After the upgrade, things like 'objectValues' would no longer work in the ZClass instance (they'd return no objects).
This may have been because you added a SimpleItem derived base class before ObjectManager. SimpleItem defines objectValues and similar methods to return empty sequences. Jim -- Jim Fulton mailto:jim@digicool.com Python Powered! Technical Director (888) 344-4332 http://www.python.org Digital Creations http://www.digicool.com http://www.zope.org Under US Code Title 47, Sec.227(b)(1)(C), Sec.227(a)(2)(B) This email address may not be added to any commercial mail list with out my permission. Violation of my privacy with advertising or SPAM will result in a suit for a MINIMUM of $500 damages/incident, $1500 for repeats.
participants (2)
-
Anthony Baxter -
Jim Fulton