\Iqrf\Repository\Entities\Metadata SensorRange

Sensor range metadata entity

Summary

Methods
Properties
Constants
__construct
fromApiResponse
jsonSerialize
from
to
No public constants found
No protected methods found
No protected properties found
No protected constants found
No private methods found
No private properties found
No private constants found

Properties

$from

$from : ?float

Type

float|null

$to

$to : ?float

Type

float|null

Methods

__construct()

__construct(float|null  $from = null, float|null  $to = null) : mixed

Constructs SensorRange metadata object.

Parameters

float|null $from

Minimum value measurable by the sensor.

float|null $to

Maximum value measurable by the sensor.

Returns

mixed —

fromApiResponse()

fromApiResponse(array{from?: float, to?: float}  $response) : \Iqrf\Repository\Entities\Metadata\SensorRange

Parses the provided response data into a SensorRange object

Parameters

array{from?: float, to?: float} $response

API response body

Returns

\Iqrf\Repository\Entities\Metadata\SensorRange —

The parsed SensorRange object

jsonSerialize()

jsonSerialize() : array{from?: float, to?: float}

Serializes SensorRange entity into JSON

Returns

array{from?: float, to?: float} —

JSON-serialized SensorRange entity