Hello all, This is perhaps a newbie question (i am a newbie !!!). I am looking for a solution to link an object (an image or a file by exemple) present in a zope folder to an other folder (like the ln command in unix). The idea is to have the possibility to destroy the original object and all the link in the same action. Is it possible with the ZODB ? Thanks for your help Dominique Jouniot
Things doesn't work quite like that. You would have to put the objects in one folder and then relate to them. More like a relational database. regards Max M Dominique Jouniot wrote:
Hello all,
This is perhaps a newbie question (i am a newbie !!!). I am looking for a solution to link an object (an image or a file by exemple) present in a zope folder to an other folder (like the ln command in unix). The idea is to have the possibility to destroy the original object and all the link in the same action. Is it possible with the ZODB ?
Dominique Jouniot wrote:
Hello all,
This is perhaps a newbie question (i am a newbie !!!). I am looking for a solution to link an object (an image or a file by exemple) present in a zope folder to an other folder (like the ln command in unix). The idea is to have the possibility to destroy the original object and all the link in the same action. Is it possible with the ZODB ?
obj=MyObject() folder1._setObject("id1", obj) folder2._setObject("id2", obj) This should work. At least in a python product. But you need to keep track of where you added your object. The garbage collection whon't delete is as long there is one reference to obj. An other way is to use mxmRelation. I am developing a BTree based mxmRelation right now. Might need some more days to get it out. thomas
participants (3)
-
Dominique Jouniot -
Max M -
Thomas Guettler