Interface MessageInterface
HTTP messages consist of requests from a client to a server and responses from a server to a client. This interface defines the methods common to each.
Messages are considered immutable; all methods that might change state MUST be implemented such that they retain the internal state of the current message and return an instance that contains the changed state.
Indirect known implementers
Psr\Http\Message\ServerRequestInterface
Namespace: Psr\Http\Message
Link: http://www.ietf.org/rfc/rfc7230.txt
Link: http://www.ietf.org/rfc/rfc7231.txt
Located at MessageInterface.php
Link: http://www.ietf.org/rfc/rfc7230.txt
Link: http://www.ietf.org/rfc/rfc7231.txt
Located at MessageInterface.php
public
string
|
|
public
static
|
#
withProtocolVersion( string $version )
Return an instance with the specified HTTP protocol version. |
public
string[][]
|
|
public
boolean
|
|
public
string[]
|
|
public
string
|
#
getHeaderLine( string $name )
Retrieves a comma-separated string of the values for a single header. |
public
static
|
#
withHeader( string $name, string|string[] $value )
Return an instance with the provided value replacing the specified header. |
public
static
|
#
withAddedHeader( string $name, string|string[] $value )
Return an instance with the specified header appended with the given value. |
public
static
|
|
public
|
|
public
static
|
#
withBody(
Return an instance with the specified message body. |