private String nextToInternal(String excluded){
  int start=pos;
  for (; pos < in.length(); pos++) {
    char c=in.charAt(pos);
    if (c == '\r' || c == '\n' || excluded.indexOf(c) != -1) {
      return in.substring(start,pos);
    }
  }
  return in.substring(start);
}

private String nextToInternal ( String excluded ) { int start = pos ; for ( ; pos < in . length ( ) ; pos ++ ) { char c = in . charAt ( pos ) ; if ( c == '\r' || c == '\n' || excluded . indexOf ( c ) != - 1 ) { return in . substring ( start , pos ) ; } } return in . substring ( start ) ; }
returns the string up to but not including any of the given characters or a newline character . this does not consume the excluded character .
