@Override public String readLine() throws IOException {
  if (this.pointer >= this.length - 1) {
    return null;
  }
 else {
    final StringBuilder buf=new StringBuilder();
    int c;
    while ((c=read()) >= 0) {
      if ((c == 10) || (c == 13)) {
        if (((peek() == 10) || (peek() == 13)) && (peek() != c)) {
          read();
        }
        break;
      }
      buf.append((char)c);
    }
    return buf.toString();
  }
}

@ Override public String readLine ( ) throws IOException { if ( this . pointer >= this . length - 1 ) { return null ; } else { final StringBuilder buf = new StringBuilder ( ) ; int c ; while ( ( c = read ( ) ) >= 0 ) { if ( ( c == 10 ) || ( c == 13 ) ) { if ( ( ( peek ( ) == 10 ) || ( peek ( ) == 13 ) ) && ( peek ( ) != c ) ) { read ( ) ; } break ; } buf . append ( ( char ) c ) ; } return buf . toString ( ) ; } }
return next line ( returns null if no line )
