public List<String> parseTextBlocks(String text){
  List<String> blocks=new ArrayList<String>();
  String limitedText=limitText(text);
  if (limitedText != null) {
    int lastBlockIndex=-1;
    Matcher matcher=repeatPattern.matcher(limitedText);
    while (matcher.find()) {
      int currentBlockIndex=matcher.start();
      if (lastBlockIndex > -1) {
        String block=limitedText.substring(lastBlockIndex,currentBlockIndex);
        blocks.add(block);
      }
      lastBlockIndex=currentBlockIndex;
    }
    if (lastBlockIndex > -1) {
      String block=limitedText.substring(lastBlockIndex);
      blocks.add(block);
    }
  }
  return blocks;
}

public List < String > parseTextBlocks ( String text ) { List < String > blocks = new ArrayList < String > ( ) ; String limitedText = limitText ( text ) ; if ( limitedText != null ) { int lastBlockIndex = - 1 ; Matcher matcher = repeatPattern . matcher ( limitedText ) ; while ( matcher . find ( ) ) { int currentBlockIndex = matcher . start ( ) ; if ( lastBlockIndex > - 1 ) { String block = limitedText . substring ( lastBlockIndex , currentBlockIndex ) ; blocks . add ( block ) ; } lastBlockIndex = currentBlockIndex ; } if ( lastBlockIndex > - 1 ) { String block = limitedText . substring ( lastBlockIndex ) ; blocks . add ( block ) ; } } return blocks ; }
parses the text into repeating blocks .
