Code Coverage
 
Lines
Functions and Methods
Classes and Traits
Total
n/a
0 / 0
n/a
0 / 0
CRAP
n/a
0 / 0
1<?php
2/**
3 * Pop PHP Framework (http://www.popphp.org/)
4 *
5 * @link       https://github.com/popphp/popphp-framework
6 * @author     Nick Sagona, III <dev@nolainteractive.com>
7 * @copyright  Copyright (c) 2009-2024 NOLA Interactive, LLC. (http://www.nolainteractive.com)
8 * @license    http://www.popphp.org/license     New BSD License
9 */
10
11/**
12 * @namespace
13 */
14namespace Pop\Http;
15
16/**
17 * HTTP interface
18 *
19 * @category   Pop
20 * @package    Pop\Http
21 * @author     Nick Sagona, III <dev@nolainteractive.com>
22 * @copyright  Copyright (c) 2009-2024 NOLA Interactive, LLC. (http://www.nolainteractive.com)
23 * @license    http://www.popphp.org/license     New BSD License
24 * @version    5.0.0
25 */
26interface HttpInterface
27{
28
29    /**
30     * Set the request
31     *
32     * @param  AbstractRequest $request
33     * @return HttpInterface
34     */
35    public function setRequest(AbstractRequest $request): HttpInterface;
36
37    /**
38     * Set the response
39     *
40     * @param  AbstractResponse $response
41     * @return HttpInterface
42     */
43    public function setResponse(AbstractResponse $response): HttpInterface;
44
45    /**
46     * Get the request
47     *
48     * @return AbstractRequest
49     */
50    public function getRequest(): AbstractRequest;
51
52    /**
53     * Get the response
54     *
55     * @return AbstractResponse
56     */
57    public function getResponse(): AbstractResponse;
58
59    /**
60     * Has request
61     *
62     * @return bool
63     */
64    public function hasRequest(): bool;
65
66    /**
67     * Get the response
68     *
69     * @return bool
70     */
71    public function hasResponse(): bool;
72
73    /**
74     * Send the request/response
75     */
76    public function send();
77
78    /**
79     * Render the request/response to string
80     */
81    public function render(): string;
82
83    /**
84     * Render the request/response to string
85     */
86    public function __toString(): string;
87
88}