Package org.simpleframework.xml.stream
Interface Position
- All Known Implementing Classes:
InputPosition
public interface Position
The
Position
object is used to acquire the position
of the read cursor within the XML file. This allows exceptions to
be thrown with the line number so that the XML can be debugged.-
Method Summary
-
Method Details
-
getLine
int getLine()This is the actual line number within the read XML document. The line number allows any problems within the source XML document to be debugged if it does not match the schema. This will return -1 if the line number cannot be determined.- Returns:
- this returns the line number of an XML event
-
toString
String toString()This provides a textual description of the position the read cursor is at within the XML document. This allows the position to be embedded within the exception thrown.
-