code: protected void wrapBuffer()
          throws IOException
      {
          // Handle chunking
          int size=size();
          if (_chunking && size()>0)
          {
              prewrite(__CRLF,0,__CRLF.length);
              while (size>0)
              {
                  int d=size%16;
                  if (d<=9)
                      prewrite('0'+d);
                  else
                      prewrite('a'-10+d);
                  size=size/16;
              }
              postwrite(__CRLF,0,__CRLF.length);
          }
          
          // Complete it if we must.
          if (_complete && !_completed)
          {
              _completed=true;
              if (_chunking)
                  postwrite(__CHUNK_EOF,0,__CHUNK_EOF.length);
          }
      }
docs: /* ------------------------------------------------------------