Methods Summary |
---|
public boolean | equals(java.lang.Object object)Compares the specified object to this {@code ParsePosition} and indicates
if they are equal. In order to be equal, {@code object} must be an
instance of {@code ParsePosition} and it must have the same index and
error index.
if (!(object instanceof ParsePosition)) {
return false;
}
ParsePosition pos = (ParsePosition) object;
return currentPosition == pos.currentPosition
&& errorIndex == pos.errorIndex;
|
public int | getErrorIndex()Returns the index at which the parse could not continue.
return errorIndex;
|
public int | getIndex()Returns the current parse position.
return currentPosition;
|
public int | hashCode()
return currentPosition + errorIndex;
|
public void | setErrorIndex(int index)Sets the index at which the parse could not continue.
errorIndex = index;
|
public void | setIndex(int index)Sets the current parse position.
currentPosition = index;
|
public java.lang.String | toString()Returns the string representation of this parse position.
return getClass().getName() + "[index=" + currentPosition //$NON-NLS-1$
+ ", errorIndex=" + errorIndex + "]"; //$NON-NLS-1$ //$NON-NLS-2$
|