public int next() {if (text.getIndex() == text.getEndIndex() || 0 == sentenceStarts.length) {return DONE;} else if (currentSentence < sentenceStarts.length - 1) {text.setIndex(sentenceStarts[++currentSentence]);return current();} else {return last();}}

public override int Next(){if (text.Index == text.EndIndex || 0 == sentenceStarts.Length){return Done;}else if (currentSentence < sentenceStarts.Length - 1){text.SetIndex(sentenceStarts[++currentSentence]);return Current;}else{return Last();}}
