public static class SourceLocator.Simple extends java.lang.Object implements SourceLocator
SourceLocator.Simple| Modifier and Type | Field and Description |
|---|---|
protected java.lang.String |
filename |
protected long |
position |
| Constructor and Description |
|---|
Simple() |
| Modifier and Type | Method and Description |
|---|---|
int |
getColumnNumber()
Return current column number.
|
int |
getEndColumn()
Column (one-origin) of end of range; unknown/unspecified is -1.
|
int |
getEndLine()
Line number (one-origin) of end of range; unknown/unspecified is -1.
|
java.lang.String |
getFileName()
Normally same as getSystemId.
|
int |
getLineNumber()
Return current line number.
|
java.lang.String |
getPublicId() |
int |
getStartColumn()
Column (one-origin) of start of range; unknown/unspecified is -1.
|
int |
getStartLine()
Line number (one-origin) of start of range; unknown/unspecified is -1.
|
java.lang.String |
getSystemId() |
boolean |
isRepl() |
boolean |
isStableSourceLocation()
True if position is unlikely to change.
|
void |
setFile(java.lang.String filename) |
void |
setLine(int lineno) |
void |
setLine(int lineno,
int colno) |
void |
setLine(java.lang.String filename,
int line,
int column) |
void |
setLocation(SourceLocator location) |
public java.lang.String getFileName()
SourceLocatorpublic boolean isRepl()
public java.lang.String getPublicId()
getPublicId in interface javax.xml.transform.SourceLocatorgetPublicId in interface org.xml.sax.Locatorpublic java.lang.String getSystemId()
getSystemId in interface javax.xml.transform.SourceLocatorgetSystemId in interface org.xml.sax.Locatorpublic int getLineNumber()
SourceLocatorgetStartLine().
The "first" line is line 1; unknown is -1.getLineNumber in interface javax.xml.transform.SourceLocatorgetLineNumber in interface org.xml.sax.Locatorpublic int getColumnNumber()
SourceLocatorgetStartColumn().
The "first" column is column 1; unknown is -1.getColumnNumber in interface javax.xml.transform.SourceLocatorgetColumnNumber in interface org.xml.sax.Locatorpublic int getStartLine()
SourceLocatorpublic int getStartColumn()
SourceLocatorpublic int getEndLine()
SourceLocatorpublic int getEndColumn()
SourceLocatorpublic boolean isStableSourceLocation()
SourceLocatorpublic void setFile(java.lang.String filename)
public void setLine(java.lang.String filename,
int line,
int column)
public void setLine(int lineno,
int colno)
public void setLine(int lineno)
public void setLocation(SourceLocator location)