|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.biojava.bio.program.gff.GFFFilterer
public class GFFFilterer
An object that filters a stream of GFF, forwarding some GFFRecords to a listening GFFDocumentHandler, and dropping others.
The choice to forward or drop is made by a GFFRecordFilter.
Unless otherwise stated, all methods forward to the listening handler without altering the arguments in any way.
Constructor Summary | |
---|---|
GFFFilterer(GFFDocumentHandler handler,
GFFRecordFilter filter)
Create a new GFFFilterer that will forward to handler everything that filter accepts. |
Method Summary | |
---|---|
void |
commentLine(java.lang.String comment)
A comment line has been encountered. |
void |
endDocument()
Indicates that the current GFF document has now ended. |
void |
recordLine(GFFRecord record)
Only forward the GFFRecords that match a filter. |
void |
startDocument(java.lang.String locator)
Indicates that a new GFF document has been started. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public GFFFilterer(GFFDocumentHandler handler, GFFRecordFilter filter)
handler
- the listening GFFDocumentHandlerfilter
- the GFFRecordFilter that decides
what is forwarded to handlerMethod Detail |
---|
public void startDocument(java.lang.String locator)
GFFDocumentHandler
startDocument
in interface GFFDocumentHandler
locator
- A URI for the stream being parsed.public void endDocument()
GFFDocumentHandler
This gives you the chance to flush results, or do calculations if you wish.
endDocument
in interface GFFDocumentHandler
public void commentLine(java.lang.String comment)
GFFDocumentHandler
comment has already had the leading '#
'
removed, and may have had leading-and-trailing whitespace trimmed.
commentLine
in interface GFFDocumentHandler
comment
- the comment Stringpublic void recordLine(GFFRecord record)
recordLine
in interface GFFDocumentHandler
record
- the GFFRecord containing all the info
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |