[xml] (python) entity loader issue



I'm in a situation where I'm doing some processing on XSLT documents
when they are loaded and I'm having a lot of trouble doing this
efficiently.

What I have right now is a python entity loader which:

- reads in the associated document
- parses it in memory
- processes the XSLT
- caches the dom for later


Because I'm loading the document and parsing it myself I tried (for a
while) to have the entity loader pass back the document itself.

But that didn't work.

So now I have the entity loader return an open python file handle.

Clearly that is going to mean that libxml2 duplicates my effort by
parsing the document again.


Anyway round this?


Nic Ferrier



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]