public function __construct(IUri $uri, $method = IRequest::METHOD_GET, $target = '', array $headers = [], $body = '', $version = IMessage::HTTP_VERSION_10) { parent::__construct($version, $headers, $body); $this->uri = $uri; $this->method = $method; $this->target = $target ?: $this->formTarget($uri); }
public function __construct($code = IResponse::STATUS_OK, array $headers = [], $body = '', $reason = '', $version = IMessage::HTTP_VERSION_10) { parent::__construct($version, $headers, $body); $this->code = $code; $this->reason = $reason; }