[Zope] Re: cataloging nodes of an XML Document?

Anthony Baxter Anthony Baxter <anthony@ekit-inc.com>
Thu, 24 Feb 2000 16:34:11 +1100


------- =_aaaaaaaaaa0
Content-Type: text/plain; charset="us-ascii"
Content-ID: <14152.951370451.1@burswood.off.ekorp.com>

>>> Anthony Baxter wrote
> Has anyone tried to use ZCatalog to catalog the nodes of an XML Document?
> 
> Trying the simple Find to ZCatalog approach fails...

Ah - the problem here is my patch for making ZCatalog catalog acquired
objects is breaking things. XMLDocument.objectIds() returns values that
you can't access with XMLDocument.foo

Fixed version of my patch attached...  (line numbers might be slightly wonky)

Anthony


------- =_aaaaaaaaaa0
Content-Type: application/octet-stream
Content-ID: <14152.951370451.2@burswood.off.ekorp.com>
Content-Description: zcatalog.diff
Content-Transfer-Encoding: base64

SW5kZXg6IFpDYXRhbG9nLnB5Cj09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09
PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0KUkNTIGZpbGU6IC9jdnMtcmVwb3NpdG9yeS9a
b3BlMi9saWIvcHl0aG9uL1Byb2R1Y3RzL1pDYXRhbG9nL1pDYXRhbG9nLnB5LHYKcmV0cmlldmlu
ZyByZXZpc2lvbiAxLjUwCmRpZmYgLXUgLXIxLjUwIFpDYXRhbG9nLnB5Ci0tLSBaQ2F0YWxvZy5w
eQkyMDAwLzAxLzMxIDE5OjIwOjU3CTEuNTAKKysrIFpDYXRhbG9nLnB5CTIwMDAvMDIvMjQgMDU6
MzI6MjcKQEAgLTU4NywxNCArNTk1LDIxIEBACiAgICAgICAgICAgICAgICAgICAgcm9sZV9tYXRj
aChvYiwgb2JqX3Blcm1pc3Npb24sIG9ial9yb2xlcykKICAgICAgICAgICAgICAgICApCiAgICAg
ICAgICAgICAgICAgKToKKyAgICAgICAgICAgICAgICB0cnk6IG9iX3JlYWwgPSBnZXRhdHRyKG9i
aiwgaWQpCisJCWV4Y2VwdCBBdHRyaWJ1dGVFcnJvcjogb2JfcmVhbCA9IG9iCiAgICAgICAgICAg
ICAgICAgaWYgYXBwbHlfZnVuYzoKLSAgICAgICAgICAgICAgICAgICAgYXBwbHlfZnVuYyhvYiwg
KGFwcGx5X3BhdGgrJy8nK3ApKQorICAgICAgICAgICAgICAgICAgICBpZiBhcHBseV9wYXRoOgor
ICAgICAgICAgICAgICAgICAgICAgICAgYXBwbHlfZnVuYyhvYl9yZWFsLCAoYXBwbHlfcGF0aCsn
LycrcCkpCisgICAgICAgICAgICAgICAgICAgIGVsc2U6CisgICAgICAgICAgICAgICAgICAgICAg
ICBhcHBseV9mdW5jKG9iX3JlYWwsIHApCiAgICAgICAgICAgICAgICAgZWxzZToKLSAgICAgICAg
ICAgICAgICAgICAgYWRkX3Jlc3VsdCgocCwgb2IpKQorICAgICAgICAgICAgICAgICAgICBhZGRf
cmVzdWx0KChwLCBvYl9yZWFsKSkKICAgICAgICAgICAgICAgICAgICAgZGZsYWc9MAogICAgICAg
ICAgICAgICAgICAgICAKICAgICAgICAgICAgIGlmIHNlYXJjaF9zdWIgYW5kIGhhc2F0dHIoYnMs
ICdvYmplY3RJdGVtcycpOgotICAgICAgICAgICAgICAgIHNlbGYuWm9wZUZpbmRBbmRBcHBseShv
Yiwgb2JqX2lkcywgb2JqX21ldGF0eXBlcywKKyAgICAgICAgICAgICAgICB0cnk6IG9iX3JlYWwg
PSBnZXRhdHRyKG9iaiwgaWQpCisgICAgICAgICAgICAgICAgZXhjZXB0IEF0dHJpYnV0ZUVycm9y
OiBvYl9yZWFsID0gb2IKKyAgICAgICAgICAgICAgICBzZWxmLlpvcGVGaW5kQW5kQXBwbHkob2Jf
cmVhbCwgb2JqX2lkcywgb2JqX21ldGF0eXBlcywKICAgICAgICAgICAgICAgICAgICAgICAgICAg
ICAgICAgICAgICAgb2JqX3NlYXJjaHRlcm0sIG9ial9leHByLAogICAgICAgICAgICAgICAgICAg
ICAgICAgICAgICAgICAgICAgICBvYmpfbXRpbWUsIG9ial9tc3BlYywKICAgICAgICAgICAgICAg
ICAgICAgICAgICAgICAgICAgICAgICAgb2JqX3Blcm1pc3Npb24sIG9ial9yb2xlcywK

------- =_aaaaaaaaaa0--