code: public ParsePosition toParsePosition() {
          ParsePosition pp = new ParsePosition(textIndex);
          pp.setErrorIndex(textErrorIndex);
          return pp;
      }
docs: Converts the indexes to a parse position.
  
  @return the parse position, never null