|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
public interface ParserNotice
A notice (e.g., a warning or error) from a parser.
Since different parsers have different levels of precision when it comes
to identifying errors in code, this class supports marking parser notices
on either a per-line basis or arbitrary regions of a document. For any
ParserNotice, getLine() is guaranteed to return the
(primary) line containing the notice, but getOffset() and
getLength() are allowed to return -1 if that
particular notice isn't mapped to a specific region of code. Applications
can check whether an instance of this class only has line-level information
with the
DefaultParserNotice| Nested Class Summary | |
|---|---|
static class |
ParserNotice.Level
Denotes the severity of a parser notice. |
| Method Summary | |
|---|---|
boolean |
containsPosition(int pos)
Returns whether this parser notice contains the specified location in the document. |
java.awt.Color |
getColor()
Returns the color to use when painting this notice. |
boolean |
getKnowsOffsetAndLength()
Returns whether this parser notice has offset and length information (as opposed to just what line number to mark). |
int |
getLength()
Returns the length of the code the message is concerned with. |
ParserNotice.Level |
getLevel()
Returns the level of this notice. |
int |
getLine()
Returns the line number the notice is about. |
java.lang.String |
getMessage()
Returns the message from the parser. |
int |
getOffset()
Returns the offset of the code the message is concerned with. |
Parser |
getParser()
Returns the parser that created this message. |
boolean |
getShowInEditor()
Whether a squiggle underline should be drawn in the editor for this notice. |
java.lang.String |
getToolTipText()
Returns the tool tip text to display for this notice. |
| Methods inherited from interface java.lang.Comparable |
|---|
compareTo |
| Method Detail |
|---|
boolean containsPosition(int pos)
pos - The position in the document.
false if getOffset() returns
-1.java.awt.Color getColor()
int getLength()
-1 if unknown.getOffset(),
getLine()ParserNotice.Level getLevel()
ParserNotice.Level enumeration.int getLine()
boolean getKnowsOffsetAndLength()
getLine(),
getOffset(),
getLength()java.lang.String getMessage()
int getOffset()
-1 if unknown.getLength(),
getLine()Parser getParser()
boolean getShowInEditor()
java.lang.String getToolTipText()
getMessage().
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||