import { ChannelCategory, DeviceCategory, PropertyCategory } from '../../../modules/devices/devices.constants'; import { SimulatorDeviceEntity } from '../entities/simulator.entity'; import { SimulationContext } from './simulation-context'; export interface SimulatedPropertyValue { channelCategory: ChannelCategory; propertyCategory: PropertyCategory; value: string | number | boolean; } export interface IDeviceSimulator { getSupportedCategory(): DeviceCategory; supportsDevice(device: SimulatorDeviceEntity): boolean; simulate(device: SimulatorDeviceEntity, context: SimulationContext, previousValues?: Map): SimulatedPropertyValue[]; } export declare abstract class BaseDeviceSimulator implements IDeviceSimulator { abstract getSupportedCategory(): DeviceCategory; supportsDevice(device: SimulatorDeviceEntity): boolean; abstract simulate(device: SimulatorDeviceEntity, context: SimulationContext, previousValues?: Map): SimulatedPropertyValue[]; protected smoothTransition(previousValue: number, targetValue: number, maxChange: number): number; protected addNoise(value: number, noiseRange: number, decimals?: number): number; protected clamp(value: number, min: number, max: number): number; protected getPropertyKey(channelCategory: ChannelCategory, propertyCategory: PropertyCategory): string; protected getPreviousValue(previousValues: Map | undefined, channelCategory: ChannelCategory, propertyCategory: PropertyCategory, defaultValue: string | number | boolean): string | number | boolean; protected hasChannel(device: SimulatorDeviceEntity, category: ChannelCategory): boolean; protected hasProperty(device: SimulatorDeviceEntity, channelCategory: ChannelCategory, propertyCategory: PropertyCategory): boolean; }