PHP Class Bitpay\Client\Request

Inheritance: implements Bitpay\Client\RequestInterface
Afficher le fichier Open project: bitpay/php-client Class Usage Examples

Protected Properties

Свойство Type Description
$body string
$headers array
$host string This should be something such as test.bitpay.com or just bitpay.com
$method string See the RequestInterface for all the valid methods
$path string The path is added to the end of the host
$port integer Default is 443 but should be changed by whatever is passed in through the Adapter.
$uri string $schema://$hostname/$path

Méthodes publiques

Méthode Description
__construct ( )
__toString ( ) : string Converts this request into a standard HTTP/1.1 message to be sent over the wire
getBody ( )
getHeaderFields ( )
getHeaders ( )
getHeadersAsString ( ) : string
getHost ( )
getMethod ( )
getPath ( )
getPort ( )
getSchema ( )
getUri ( )
getUriWithPort ( )
isMethod ( $method )
setBody ( string $body ) The the body of the request
setHeader ( string $header, string $value ) Set a http header for the request
setHost ( string $host ) Sets the host for the request
setMethod ( string $method ) Set the method of the request, for known methods see the RequestInterface
setPath ( $path )
setPort ( $port ) This is called in the Adapter

Method Details

__construct() public méthode

public __construct ( )

__toString() public méthode

Converts this request into a standard HTTP/1.1 message to be sent over the wire
public __toString ( ) : string
Résultat string

getBody() public méthode

public getBody ( )

getHeaderFields() public méthode

public getHeaderFields ( )

getHeaders() public méthode

public getHeaders ( )

getHeadersAsString() public méthode

public getHeadersAsString ( ) : string
Résultat string

getHost() public méthode

public getHost ( )

getMethod() public méthode

public getMethod ( )

getPath() public méthode

public getPath ( )

getPort() public méthode

public getPort ( )

getSchema() public méthode

public getSchema ( )

getUri() public méthode

public getUri ( )

getUriWithPort() public méthode

public getUriWithPort ( )

isMethod() public méthode

public isMethod ( $method )

setBody() public méthode

The the body of the request
public setBody ( string $body )
$body string

setHeader() public méthode

Set a http header for the request
public setHeader ( string $header, string $value )
$header string
$value string

setHost() public méthode

Sets the host for the request
public setHost ( string $host )
$host string

setMethod() public méthode

Set the method of the request, for known methods see the RequestInterface
public setMethod ( string $method )
$method string

setPath() public méthode

public setPath ( $path )

setPort() public méthode

This is called in the Adapter
public setPort ( $port )

Property Details

$body protected_oe property

protected string $body
Résultat string

$headers protected_oe property

protected array $headers
Résultat array

$host protected_oe property

This should be something such as test.bitpay.com or just bitpay.com
protected string $host
Résultat string

$method protected_oe property

See the RequestInterface for all the valid methods
protected string $method
Résultat string

$path protected_oe property

The path is added to the end of the host
protected string $path
Résultat string

$port protected_oe property

Default is 443 but should be changed by whatever is passed in through the Adapter.
protected int $port
Résultat integer

$uri protected_oe property

$schema://$hostname/$path
protected string $uri
Résultat string