public boolean checkError(){
  Writer delegate=out;
  if (delegate == null) {
    return ioError;
  }
  flush();
  return ioError || delegate.checkError();
}

public boolean checkError ( ) { Writer delegate = out ; if ( delegate == null ) { return ioError ; } flush ( ) ; return ioError || delegate . checkError ( ) ; }
flushes this writer and returns the value of the error flag .
