body = $body; $this->status = $status; $this->headers = $headers; } public function send(): void { http_response_code($this->status); foreach ($this->headers as $name => $value) { header($name . ': ' . $value); } echo $this->body; } }