I am thinking of extending the tree function to provide for the 
serialization of subtrees as they are no longer immediately relevant. 
Rather than simply deleting subtrees, I am thinking about caching them 
via serialization and providing the functionality in the Node class to 
retrieve the subtree on demand.  fo:page-sequences and fo:flows which 
had been fromatted into complete pages would be candidates for caching 
in the fo tree, as would be completed pages in the area tree.

One obvious issue would be the re-caching of subtrees which had been 
retrieved, but that would essentially be the responsibility of the 
process which retrieved it.  Another is the clearing of the cache.  At 
the end of a document, the cache of serialized object files would have 
to be cleared.  Is it true that finalizers are not an adequate mechanism 
for this sort of cleanup?

The point of all this is to provide a mechanism which both manages the 
size of the in-memory tree and covers any future methods for 
back-filling in the re-formatting of pages.

Are there any gotchas in serialization which would make such an idea 
infeasible, or is there a more straightforward way of doing this?

Peter B. West  [EMAIL PROTECTED]  http://powerup.com.au/~pbwest
"Lord, to whom shall we go?"

To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]

Reply via email to