Copied!
Cloneable Final Instantiable
Methods
public static bodySummary ( Psr\Http\Message\MessageInterface $message , $truncateAt = 120 )
 

Get a short summary of the message body.

Will return null if the response is not printable.

  • return string | null
public static parseMessage ( $message )
 

Parses an HTTP message into an associative array.

The array contains the "start-line" key containing the start line of
the message, "headers" key containing an associative array of header
array values, and a "body" key containing the body of the message.

  • return array
public static parseRequest ( $message )
 

Parses a request message string into a request object.

public static parseRequestUri ( $path , array $headers )
 

Constructs a URI for an HTTP request message.

  • return string
public static parseResponse ( $message )
 

Parses a response message string into a response object.

public static rewindBody ( Psr\Http\Message\MessageInterface $message )
 

Attempts to rewind a message body and throws an exception on failure.

The body of the message will only be rewound if a call to tell()
returns a value other than 0.

  • throws RuntimeException
public static toString ( Psr\Http\Message\MessageInterface $message )
 

Returns the string representation of an HTTP message.

  • return string
Methods
public static bodySummary ( Psr\Http\Message\MessageInterface $message , $truncateAt = 120 )
 

Get a short summary of the message body.

Will return null if the response is not printable.

  • return string | null
public static parseMessage ( $message )
 

Parses an HTTP message into an associative array.

The array contains the "start-line" key containing the start line of
the message, "headers" key containing an associative array of header
array values, and a "body" key containing the body of the message.

  • return array
public static parseRequest ( $message )
 

Parses a request message string into a request object.

public static parseRequestUri ( $path , array $headers )
 

Constructs a URI for an HTTP request message.

  • return string
public static parseResponse ( $message )
 

Parses a response message string into a response object.

public static rewindBody ( Psr\Http\Message\MessageInterface $message )
 

Attempts to rewind a message body and throws an exception on failure.

The body of the message will only be rewound if a call to tell()
returns a value other than 0.

  • throws RuntimeException
public static toString ( Psr\Http\Message\MessageInterface $message )
 

Returns the string representation of an HTTP message.

  • return string
© 2020 Bruce Wells
Search Namespaces \ Classes
Configuration Numbers (0-9.) only