Menu

## Rate
in package

Rate.php : 17

##### Tags

author

  BitPay Integrations integrations@bitpay.com

license

  http://www.opensource.org/licenses/mit-license.php MIT

see
  https://bitpay.readme.io/reference/rates

  REST API Rates

### Table of Contents

#### Properties

$code : string|null
$name : string|null
$rate : float|null

#### Methods

__construct() : mixed
getCode() : string|null
  Gets ISO 4217 3-character currency code
getName() : string|null
  Gets detailed currency name
getRate() : float|null
  Gets rate for the requested baseCurrency /currency pair
setCode() : void
  Sets ISO 4217 3-character currency code
setName() : void
  Sets detailed currency name
setRate() : void
  Sets rate for the requested baseCurrency /currency pair
toArray() : array<string|int, mixed>
  Gets Rate as array

### Properties

#### $code

Rate.php : 20
`protected string|null $code = null`

#### $name

Rate.php : 19
`protected string|null $name = null`

#### $rate

Rate.php : 21
`protected float|null $rate = null`

### Methods

#### __construct()

Rate.php : 23
`public __construct() : mixed`

#### getCode()

Rate.php : 52

Gets ISO 4217 3-character currency code

`public getCode() : string|null`

##### Return values

string|null —

the code

#### getName()

Rate.php : 32

Gets detailed currency name

`public getName() : string|null`

##### Return values

string|null —

the name

#### getRate()

Rate.php : 72

Gets rate for the requested baseCurrency /currency pair

`public getRate() : float|null`

##### Return values

float|null —

the rate

#### setCode()

Rate.php : 62

Sets ISO 4217 3-character currency code

`public setCode(string $code) : void`

##### Parameters

$code : string

  the code

#### setName()

Rate.php : 42

Sets detailed currency name

`public setName(string $name) : void`

##### Parameters

$name : string

  the name

#### setRate()

Rate.php : 82

Sets rate for the requested baseCurrency /currency pair

`public setRate(float $rate) : void`

##### Parameters

$rate : float

  the rate

#### toArray()

Rate.php : 92

Gets Rate as array

`public toArray() : array<string|int, mixed>`

##### Return values

array<string|int, mixed> —

Rate as array

## Search results