/**
  * Read characters into a portion of an array.
  *
  * @exception IOException If an I/O error occurs
  */
 public int read(char cbuf[], int off, int len) throws IOException {
   ensureOpen();
   if ((off < 0)
       || (off > cbuf.length)
       || (len < 0)
       || ((off + len) > cbuf.length)
       || ((off + len) < 0)) {
     throw new IndexOutOfBoundsException();
   } else if (len == 0) {
     return 0;
   }
   return in.read(cbuf, off, len);
 }
 /**
  * Read a single character.
  *
  * @exception IOException If an I/O error occurs
  */
 public int read() throws IOException {
   ensureOpen();
   return in.read();
 }