Lines n/a 0 / 0
Functions and Methods n/a 0 / 0
Classes and Traits n/a 0 / 0
Name Lines Functions and Methods CRAP Classes and Traits
1<?php
2
3declare(strict_types=1);
4
5namespace Stewart\Contracts\Exposure;
6
7use DateTimeInterface;
8use Stewart\Contracts\Exception\ExposureException;
9
10/** @phpstan-import-type ExposedAttributes from ExposedEntity */
11interface ExposedSensor extends ExposedEntity
12{
13    public function getConfig(): SensorConfig;
14
15    /** @throws ExposureException */
16    public function updateConfig(SensorConfig $config): void;
17
18    public function getValue(): int|float|string|null;
19
20    /**
21     * @param ExposedAttributes|null $attributes
22     * @throws ExposureException
23     */
24    public function setValue(int|float|string|DateTimeInterface|null $value, ?array $attributes = null): void;
25}