code: private void moveTo(int position) {
      while (position >= currentPosition) {
        try {
          currentPosition = ignoreSpans.nextStartPosition();
          if (currentPosition != Spans.NO_MORE_POSITIONS
              && currentPosition >= minimumPosition) {
            if (!baseEndPositionList.containsKey(currentPosition)) {
              baseEndPositionList.put(currentPosition, new HashSet<Integer>());
              maxBaseEndPosition.put(currentPosition, currentPosition);
            } else {
              maxBaseEndPosition.put(currentPosition,
                  Math.max(maxBaseEndPosition.get(currentPosition),
                      ignoreSpans.endPosition()));
            }
            if (!baseStartPositionList.containsKey(ignoreSpans.endPosition())) {
              baseStartPositionList.put(ignoreSpans.endPosition(),
                  new HashSet<Integer>());
              minBaseStartPosition.put(ignoreSpans.endPosition(),
                  ignoreSpans.endPosition());
            } else {
              minBaseStartPosition.put(ignoreSpans.endPosition(),
                  Math.min(minBaseStartPosition.get(ignoreSpans.endPosition()),
                      currentPosition));
            }
            baseStartPositionList.get(ignoreSpans.endPosition())
                .add(currentPosition);
            baseEndPositionList.get(currentPosition)
                .add(ignoreSpans.endPosition());
          }
        } catch (IOException e) {
          log.debug(e);
          currentPosition = Spans.NO_MORE_POSITIONS;
          break;
        }
      }
    }
docs: Move to.
  
  @param position the position