code: public int read(byte b[]) throws IOException
      {
          int len = b.length;
          if (_chunkSize<=0 && getChunkSize()<=0)
              return -1;
          if (len > _chunkSize)
              len=_chunkSize;
          len=_in.read(b,0,len);
          if (len<0)
          {
              _chunkSize=-1;
              throw new IOException(__UNEXPECTED_EOF);
          }
          _chunkSize=_chunkSize-len;
          return len;
      }
docs: /* ------------------------------------------------------------