Methods exposed by the unmarshalling coordinator object
to the generated code.
This interface will be implemented by the coordinator, which
converts whatever events (e.g., SAX) into unmarshalling events.
Errors detected by the AbstractUnmarshallingEventHandlerImpl-derived classes should
be either thrown as
UnrepotedException or reported through
the handleEvent method of this interface.
author: Kohsuke KAWAGUCHI
Method Summary
void
addPatcher(Runnable job) Adds a job that will be executed at the last of the unmarshalling.
popAttributes() Discards the previously stored attribute set.
void
popContentHandler() Pops a content handler from the stack and registers
it as the current content handler.
void
pushAttributes(Attributes atts, boolean collectText) Stores a new attribute set.
This method should be called by the generated code
when it "eats" an enterElement event.
Parameters: collectText - false if the context doesn't need to fire text eventsfor texts inside this element.
void
pushContentHandler(UnmarshallingEventHandler handler, int memento) Pushes the current content handler into the stack
and registers the newly specified content handler so
that it can receive SAX events.
Adds a job that will be executed at the last of the unmarshalling.
This method is used to support ID/IDREF feature, but it can be used
for other purposes as well.
Parameters: job - The run method of this object is called.
Adds the object which is currently being unmarshalled
to the ID table.
Returns the value passed as the parameter.This is a hack, but this makes it easier for IDtransducer to do its job.
Returns a list of prefixes newly declared on this element.
This method has to be called after the
UnmarshallingContext.pushAttributes method is called.
A possible zero-length array of prefixes. The default prefixis represented by the empty string.
Gets a tracer object.
Tracer can be used to trace the unmarshalling behavior.
Note that to debug the unmarshalling process,
you have to configure XJC so that it will emit trace codes
in the unmarshaller.
Reports an error to the user, and asks if s/he wants
to recover. If the canRecover flag is false, regardless
of the client instruction, an exception will be thrown.
Only if the flag is true and the user wants to recover from an error,
the method returns normally.
The thrown exception will be catched by the unmarshaller.
Stores a new attribute set.
This method should be called by the generated code
when it "eats" an enterElement event.
Parameters: collectText - false if the context doesn't need to fire text eventsfor texts inside this element. True otherwise.
Pushes the current content handler into the stack
and registers the newly specified content handler so
that it can receive SAX events.
Parameters: memento - When this newly specified handler will be removed from the stack,the leaveChild event will be fired to the parent handlerwith this memento.