But how would I be able to wrap the content handler without modifying the AbstractSession class? Is there some API I can use to set the content handler, in which case I wouldn't need to alter any of the Jackrabbit code.
On Feb 8, 2008 6:49 PM, Marcel Reutegger <[EMAIL PROTECTED]> wrote: > Hi Sridhar, > > Sridhar Raman wrote: > > In the class AbstractSession, the method importXML has this line: > > ContentHandler handler = > > getImportContentHandler(parentAbsPath, uuidBehavior); > > I am supposed to wrap this ContentHandler object right? > > correct. but you don't have to change any of the jackrabbit code. simply > wrap > the content handler that is returned. > > > Currently it's returning ImportHandler object. I need to write a > similar > > handler, where I take care of the 1000 node count in the endElement > method. > > Am I on the right track? > > yes, something similar to: > > https://svn.apache.org/repos/asf/jackrabbit/trunk/jackrabbit-jcr-commons/src/main/java/org/apache/jackrabbit/commons/xml/DefaultContentHandler.java > > then keep track on nodes that are added through start/endElement(). > > regards > marcel >
