code: function() {
    var self = this;
  
    var mime;
    if (typeof this.output === 'string') {
      mime = 'text/html';
    }
    else if (this.output instanceof Buffer) {
      mime = 'application/octet-stream';
    }
    else if (this.output instanceof Readable) {
      mime = 'application/octet-stream';
    }
    else {
      mime = 'application/json';
      this.output = JSON.stringify(this.output, null, 2);
    }
    if (typeof this.mime === 'string') {
      mime = this.mime;
    }
  
    if (mime.substring(0, 5) === 'text/' && mime.indexOf('charset') < 0) {
      mime += '; charset=utf-8';
    }
  
    this.setHeader('Content-Type', mime);
  
    // Include anti clickjacking header for HTML responses.
    if (this._options.clickjacking && mime.substring(0, 9) === 'text/html') {
      this.setHeader('X-Frame-Options', this._options.clickjacking);
    }
  
    // Disable MIME-sniffing. This must be set for all content types.
    if (this._options.noMimeSniffing) {
      this.setHeader('X-Content-Type-Options', 'nosniff');
    }
    Object.keys(this._outputHeaders).forEach(function(name) {
      // Convert case ("content-type" to "Content-Type").
      var casedName = name.replace(/(^.|\-.)/g, function(part) {
        return part.toUpperCase();
      });
      self.res.setHeader(casedName, self._outputHeaders[name]);
    });
  
    this._length = this.output.length;
    this.res.statusCode = this.status;
    if (this.output instanceof Readable) {
      var res = this.res;
      this.output.on('data', function(data) {
        res.write(data);
      });
      this.output.on('end', function() {
        res.end();
      });
    }
    else {
      this.res.end(this.output);
    }
  }
docs: Send response.