|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.sun.labs.minion.document.MarkUpAnalyzer
public abstract class MarkUpAnalyzer
An abstract class intended to be the superclass of all mark-up analyzers.
Field Summary | |
---|---|
protected java.io.Reader |
r
A reader that can be used to read the data from the file. |
Constructor Summary | |
---|---|
MarkUpAnalyzer(java.io.Reader r,
int pos,
java.lang.String key)
Makes a markup analyzer that will read from an input stream. |
|
MarkUpAnalyzer(java.lang.String s,
java.lang.String key)
Makes a markup analyzer that will read from a string. |
Method Summary | |
---|---|
abstract void |
analyze(Stage stage)
Analyzes the current document. |
static MarkUpAnalyzer |
getMarkUpAnalyzer(java.io.File f,
java.io.Reader r,
java.lang.String key)
Gets a markup analyzer that's appropriate for the given file. |
static MarkUpAnalyzer |
getMarkUpAnalyzer(java.lang.String mimeType,
java.io.Reader r,
java.lang.String key)
Gets a markup analyzer that is appropriate for the given MIME type. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected java.io.Reader r
Constructor Detail |
---|
public MarkUpAnalyzer(java.io.Reader r, int pos, java.lang.String key)
r
- pos
- The current position in the input stream, so that we can
keep accurate counts of where things are.key
- The key for the document we're analyzing, so that we can
report errors usefully.public MarkUpAnalyzer(java.lang.String s, java.lang.String key)
s
- The string to read data from.key
- The key for the document we're analyzing, so that we can
report errors usefully.Method Detail |
---|
public static MarkUpAnalyzer getMarkUpAnalyzer(java.io.File f, java.io.Reader r, java.lang.String key)
f
- The file that we're going to read from.r
- The reader that we can read data from.public static MarkUpAnalyzer getMarkUpAnalyzer(java.lang.String mimeType, java.io.Reader r, java.lang.String key)
mimeType
- the RFC 2046 mime typer
- a reader with the contents of the datakey
- the document key
public abstract void analyze(Stage stage) throws java.io.IOException
stage
- the head of the pipeline that will process the text of the document
java.io.IOException
- If there is any error reading.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |