|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Object | +--org.biojava.bio.program.tagvalue.TagValueWrapper
Helper class to wrap one TagValueListener inside another one.
Implementations will tend to intercept the tags or values as they stream through and modify them in some manner before forwarding them to the delegate listener. Using classes derived from TagValueWrapper, it is possible to build up complex chains of handlers that process and collate information as it streams through.
| Constructor Summary | |
TagValueWrapper()
|
|
TagValueWrapper(TagValueListener delegate)
Build a TagValueWrapper that will forward everything to a delegate. |
|
| Method Summary | |
void |
endRecord()
The current record has ended. |
void |
endTag()
End the current tag. |
TagValueListener |
getDelegate()
|
void |
setDelegate(TagValueListener delegate)
|
void |
startRecord()
A new record is about to start. |
void |
startTag(java.lang.Object tag)
Start a new tag. |
void |
value(TagValueContext ctxt,
java.lang.Object value)
A value has been seen. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public TagValueWrapper(TagValueListener delegate)
delegate - the TagValueWrapper to forward events topublic TagValueWrapper()
| Method Detail |
public TagValueListener getDelegate()
public void setDelegate(TagValueListener delegate)
public void startRecord()
throws ParserException
TagValueListener
startRecord in interface TagValueListenerParserException - if the record can not be started
public void endRecord()
throws ParserException
TagValueListener
endRecord in interface TagValueListenerParserException - if the record can not be ended
public void startTag(java.lang.Object tag)
throws ParserException
TagValueListener
startTag in interface TagValueListenertag - the Object representing the new tag
ParserException - if the tag could not be started
public void endTag()
throws ParserException
TagValueListener
endTag in interface TagValueListenerParserException - if the tag could not be ended
public void value(TagValueContext ctxt,
java.lang.Object value)
throws ParserException
TagValueListener
value in interface TagValueListenerctxt - a TagValueContext that could be used to push a sub-documentvalue - the value Object observed
ParserException - if the value could not be processed
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||