@fastybird/smart-panel-backend 1.1.0-alpha.63 → 1.1.0-alpha.65
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/app.module.d.ts +3 -1
- package/dist/app.module.js +5 -1
- package/dist/app.module.js.map +1 -1
- package/dist/cli.js +1 -0
- package/dist/cli.js.map +1 -1
- package/dist/common/database/sqlite-data-source.d.ts +37 -0
- package/dist/common/database/sqlite-data-source.js +2131 -0
- package/dist/common/database/sqlite-data-source.js.map +1 -0
- package/dist/dataSource.d.ts +3 -1
- package/dist/dataSource.js +3 -3
- package/dist/dataSource.js.map +1 -1
- package/dist/main.js +1 -0
- package/dist/main.js.map +1 -1
- package/dist/migrations/1000000000002-AddTokenLastUsedAt.js +1 -0
- package/dist/migrations/1000000000002-AddTokenLastUsedAt.js.map +1 -1
- package/dist/migrations/1000000000027-AddVirtualProducerBindings.d.ts +7 -0
- package/dist/migrations/1000000000027-AddVirtualProducerBindings.js +87 -0
- package/dist/migrations/1000000000027-AddVirtualProducerBindings.js.map +1 -0
- package/dist/migrations/1000000000028-AddShellySampleSources.d.ts +6 -0
- package/dist/migrations/1000000000028-AddShellySampleSources.js +29 -0
- package/dist/migrations/1000000000028-AddShellySampleSources.js.map +1 -0
- package/dist/migrations/1000000000029-AddVirtualNumericTransforms.d.ts +6 -0
- package/dist/migrations/1000000000029-AddVirtualNumericTransforms.js +31 -0
- package/dist/migrations/1000000000029-AddVirtualNumericTransforms.js.map +1 -0
- package/dist/migrations/1000000000030-AddZigbeeSampleSources.d.ts +6 -0
- package/dist/migrations/1000000000030-AddZigbeeSampleSources.js +33 -0
- package/dist/migrations/1000000000030-AddZigbeeSampleSources.js.map +1 -0
- package/dist/migrations/1000000000031-AddVirtualThermostatClaims.d.ts +6 -0
- package/dist/migrations/1000000000031-AddVirtualThermostatClaims.js +62 -0
- package/dist/migrations/1000000000031-AddVirtualThermostatClaims.js.map +1 -0
- package/dist/migrations/1000000000032-AddVirtualThermostatRuntime.d.ts +6 -0
- package/dist/migrations/1000000000032-AddVirtualThermostatRuntime.js +39 -0
- package/dist/migrations/1000000000032-AddVirtualThermostatRuntime.js.map +1 -0
- package/dist/migrations/1000000000033-AddThermostatInstallationProfiles.d.ts +6 -0
- package/dist/migrations/1000000000033-AddThermostatInstallationProfiles.js +28 -0
- package/dist/migrations/1000000000033-AddThermostatInstallationProfiles.js.map +1 -0
- package/dist/migrations/1000000000034-AddVirtualThermostatRecoveries.d.ts +6 -0
- package/dist/migrations/1000000000034-AddVirtualThermostatRecoveries.js +26 -0
- package/dist/migrations/1000000000034-AddVirtualThermostatRecoveries.js.map +1 -0
- package/dist/migrations/1000000000035-IndexVirtualThermostatCommands.d.ts +6 -0
- package/dist/migrations/1000000000035-IndexVirtualThermostatCommands.js +35 -0
- package/dist/migrations/1000000000035-IndexVirtualThermostatCommands.js.map +1 -0
- package/dist/migrations/1000000000036-AddVirtualAggregatePolicies.d.ts +6 -0
- package/dist/migrations/1000000000036-AddVirtualAggregatePolicies.js +18 -0
- package/dist/migrations/1000000000036-AddVirtualAggregatePolicies.js.map +1 -0
- package/dist/migrations/1000000000037-AddVirtualAggregateProfiles.d.ts +6 -0
- package/dist/migrations/1000000000037-AddVirtualAggregateProfiles.js +16 -0
- package/dist/migrations/1000000000037-AddVirtualAggregateProfiles.js.map +1 -0
- package/dist/migrations/1000000000038-AddShellyCoverOrdering.d.ts +6 -0
- package/dist/migrations/1000000000038-AddShellyCoverOrdering.js +19 -0
- package/dist/migrations/1000000000038-AddShellyCoverOrdering.js.map +1 -0
- package/dist/migrations/1000000000039-AddVirtualThermostatComfort.d.ts +6 -0
- package/dist/migrations/1000000000039-AddVirtualThermostatComfort.js +16 -0
- package/dist/migrations/1000000000039-AddVirtualThermostatComfort.js.map +1 -0
- package/dist/migrations/1000000000040-AddThermostatBranchGroups.d.ts +6 -0
- package/dist/migrations/1000000000040-AddThermostatBranchGroups.js +32 -0
- package/dist/migrations/1000000000040-AddThermostatBranchGroups.js.map +1 -0
- package/dist/migrations/1000000000041-AddThermostatMemberProtection.d.ts +6 -0
- package/dist/migrations/1000000000041-AddThermostatMemberProtection.js +39 -0
- package/dist/migrations/1000000000041-AddThermostatMemberProtection.js.map +1 -0
- package/dist/migrations/1000000000042-AddShellyCoverRecoveries.d.ts +6 -0
- package/dist/migrations/1000000000042-AddShellyCoverRecoveries.js +19 -0
- package/dist/migrations/1000000000042-AddShellyCoverRecoveries.js.map +1 -0
- package/dist/migrations/1000000000044-AddVirtualDewPoint.d.ts +6 -0
- package/dist/migrations/1000000000044-AddVirtualDewPoint.js +36 -0
- package/dist/migrations/1000000000044-AddVirtualDewPoint.js.map +1 -0
- package/dist/migrations/1000000000045-AddThermostatCoolingDependencies.d.ts +6 -0
- package/dist/migrations/1000000000045-AddThermostatCoolingDependencies.js +32 -0
- package/dist/migrations/1000000000045-AddThermostatCoolingDependencies.js.map +1 -0
- package/dist/migrations/1000000000046-AddSpaceActivityModes.d.ts +7 -0
- package/dist/migrations/1000000000046-AddSpaceActivityModes.js +54 -0
- package/dist/migrations/1000000000046-AddSpaceActivityModes.js.map +1 -0
- package/dist/migrations/1000000000047-AddClimateAutomationOwnership.d.ts +6 -0
- package/dist/migrations/1000000000047-AddClimateAutomationOwnership.js +60 -0
- package/dist/migrations/1000000000047-AddClimateAutomationOwnership.js.map +1 -0
- package/dist/migrations/1000000000048-AddThermostatCreationCatalogBirths.d.ts +6 -0
- package/dist/migrations/1000000000048-AddThermostatCreationCatalogBirths.js +208 -0
- package/dist/migrations/1000000000048-AddThermostatCreationCatalogBirths.js.map +1 -0
- package/dist/migrations/1000000000049-FenceClimateAutomationLifecycle.d.ts +6 -0
- package/dist/migrations/1000000000049-FenceClimateAutomationLifecycle.js +40 -0
- package/dist/migrations/1000000000049-FenceClimateAutomationLifecycle.js.map +1 -0
- package/dist/migrations/1000000000050-AddSpaceModeSchedules.d.ts +6 -0
- package/dist/migrations/1000000000050-AddSpaceModeSchedules.js +36 -0
- package/dist/migrations/1000000000050-AddSpaceModeSchedules.js.map +1 -0
- package/dist/migrations/1000000000051-AddSpaceOccupancy.d.ts +6 -0
- package/dist/migrations/1000000000051-AddSpaceOccupancy.js +34 -0
- package/dist/migrations/1000000000051-AddSpaceOccupancy.js.map +1 -0
- package/dist/migrations/1000000000052-AddNativeThermostats.d.ts +6 -0
- package/dist/migrations/1000000000052-AddNativeThermostats.js +39 -0
- package/dist/migrations/1000000000052-AddNativeThermostats.js.map +1 -0
- package/dist/migrations/1000000000053-AddThermostatOverrideClocks.d.ts +6 -0
- package/dist/migrations/1000000000053-AddThermostatOverrideClocks.js +35 -0
- package/dist/migrations/1000000000053-AddThermostatOverrideClocks.js.map +1 -0
- package/dist/modules/buddy/buddy.utils.d.ts +1 -1
- package/dist/modules/buddy/buddy.utils.js +10 -11
- package/dist/modules/buddy/buddy.utils.js.map +1 -1
- package/dist/modules/buddy/services/buddy-context.service.js +2 -1
- package/dist/modules/buddy/services/buddy-context.service.js.map +1 -1
- package/dist/modules/buddy/services/home-context-tool-provider.service.d.ts +1 -1
- package/dist/modules/devices/contracts/climate-automation.contract.d.ts +111 -0
- package/dist/modules/devices/contracts/climate-automation.contract.js +3 -0
- package/dist/modules/devices/contracts/climate-automation.contract.js.map +1 -0
- package/dist/modules/devices/controllers/channels.properties.controller.d.ts +1 -1
- package/dist/modules/devices/controllers/channels.properties.controller.js +11 -4
- package/dist/modules/devices/controllers/channels.properties.controller.js.map +1 -1
- package/dist/modules/devices/controllers/devices.channels.properties.controller.d.ts +1 -1
- package/dist/modules/devices/controllers/devices.channels.properties.controller.js +11 -4
- package/dist/modules/devices/controllers/devices.channels.properties.controller.js.map +1 -1
- package/dist/modules/devices/controllers/property-command.controller.d.ts +9 -0
- package/dist/modules/devices/controllers/property-command.controller.js +88 -0
- package/dist/modules/devices/controllers/property-command.controller.js.map +1 -0
- package/dist/modules/devices/devices.constants.d.ts +4 -0
- package/dist/modules/devices/devices.constants.js +4 -0
- package/dist/modules/devices/devices.constants.js.map +1 -1
- package/dist/modules/devices/devices.module.js +22 -0
- package/dist/modules/devices/devices.module.js.map +1 -1
- package/dist/modules/devices/devices.openapi.d.ts +3 -1
- package/dist/modules/devices/devices.openapi.js +39 -0
- package/dist/modules/devices/devices.openapi.js.map +1 -1
- package/dist/modules/devices/dto/property-command.dto.js +20 -6
- package/dist/modules/devices/dto/property-command.dto.js.map +1 -1
- package/dist/modules/devices/dto/update-device.dto.d.ts +1 -1
- package/dist/modules/devices/dto/update-device.dto.js +4 -3
- package/dist/modules/devices/dto/update-device.dto.js.map +1 -1
- package/dist/modules/devices/entities/climate-automation.entity.d.ts +56 -0
- package/dist/modules/devices/entities/climate-automation.entity.js +231 -0
- package/dist/modules/devices/entities/climate-automation.entity.js.map +1 -0
- package/dist/modules/devices/entities/devices.entity.d.ts +4 -0
- package/dist/modules/devices/entities/devices.entity.js +27 -3
- package/dist/modules/devices/entities/devices.entity.js.map +1 -1
- package/dist/modules/devices/interceptors/property-command-entry.interceptor.d.ts +10 -0
- package/dist/modules/devices/interceptors/property-command-entry.interceptor.js +50 -0
- package/dist/modules/devices/interceptors/property-command-entry.interceptor.js.map +1 -0
- package/dist/modules/devices/models/composite-command.model.d.ts +16 -0
- package/dist/modules/devices/models/composite-command.model.js +99 -0
- package/dist/modules/devices/models/composite-command.model.js.map +1 -0
- package/dist/modules/devices/models/property-command-response.model.d.ts +18 -0
- package/dist/modules/devices/models/property-command-response.model.js +90 -0
- package/dist/modules/devices/models/property-command-response.model.js.map +1 -0
- package/dist/modules/devices/models/property-read-policy.model.d.ts +4 -0
- package/dist/modules/devices/models/property-read-policy.model.js +57 -0
- package/dist/modules/devices/models/property-read-policy.model.js.map +1 -0
- package/dist/modules/devices/models/property-sample.model.d.ts +50 -0
- package/dist/modules/devices/models/property-sample.model.js +3 -0
- package/dist/modules/devices/models/property-sample.model.js.map +1 -0
- package/dist/modules/devices/models/property-value-state.model.d.ts +11 -0
- package/dist/modules/devices/models/property-value-state.model.js +55 -1
- package/dist/modules/devices/models/property-value-state.model.js.map +1 -1
- package/dist/modules/devices/platforms/device.platform.d.ts +43 -0
- package/dist/modules/devices/platforms/native-climate.contract.d.ts +50 -0
- package/dist/modules/devices/platforms/native-climate.contract.js +3 -0
- package/dist/modules/devices/platforms/native-climate.contract.js.map +1 -0
- package/dist/modules/devices/services/channels-type-mapper.service.d.ts +3 -0
- package/dist/modules/devices/services/channels-type-mapper.service.js +21 -1
- package/dist/modules/devices/services/channels-type-mapper.service.js.map +1 -1
- package/dist/modules/devices/services/channels.properties-type-mapper.service.d.ts +7 -2
- package/dist/modules/devices/services/channels.properties-type-mapper.service.js +21 -1
- package/dist/modules/devices/services/channels.properties-type-mapper.service.js.map +1 -1
- package/dist/modules/devices/services/channels.properties.service.d.ts +11 -2
- package/dist/modules/devices/services/channels.properties.service.js +219 -64
- package/dist/modules/devices/services/channels.properties.service.js.map +1 -1
- package/dist/modules/devices/services/channels.service.d.ts +12 -5
- package/dist/modules/devices/services/channels.service.js +148 -55
- package/dist/modules/devices/services/channels.service.js.map +1 -1
- package/dist/modules/devices/services/climate-automation-ledger-lifecycle.d.ts +47 -0
- package/dist/modules/devices/services/climate-automation-ledger-lifecycle.js +242 -0
- package/dist/modules/devices/services/climate-automation-ledger-lifecycle.js.map +1 -0
- package/dist/modules/devices/services/climate-automation-ledger.service.d.ts +68 -0
- package/dist/modules/devices/services/climate-automation-ledger.service.js +1061 -0
- package/dist/modules/devices/services/climate-automation-ledger.service.js.map +1 -0
- package/dist/modules/devices/services/climate-automation-ledger.utils.d.ts +8 -0
- package/dist/modules/devices/services/climate-automation-ledger.utils.js +54 -0
- package/dist/modules/devices/services/climate-automation-ledger.utils.js.map +1 -0
- package/dist/modules/devices/services/climate-automation.registry.service.d.ts +15 -0
- package/dist/modules/devices/services/climate-automation.registry.service.js +71 -0
- package/dist/modules/devices/services/climate-automation.registry.service.js.map +1 -0
- package/dist/modules/devices/services/composite-property-command.registry.service.d.ts +48 -0
- package/dist/modules/devices/services/composite-property-command.registry.service.js +65 -0
- package/dist/modules/devices/services/composite-property-command.registry.service.js.map +1 -0
- package/dist/modules/devices/services/controller-publication-context.d.ts +27 -0
- package/dist/modules/devices/services/controller-publication-context.js +148 -0
- package/dist/modules/devices/services/controller-publication-context.js.map +1 -0
- package/dist/modules/devices/services/cover-action-proof.d.ts +7 -0
- package/dist/modules/devices/services/cover-action-proof.js +142 -0
- package/dist/modules/devices/services/cover-action-proof.js.map +1 -0
- package/dist/modules/devices/services/creation-capture.d.ts +19 -0
- package/dist/modules/devices/services/creation-capture.js +85 -0
- package/dist/modules/devices/services/creation-capture.js.map +1 -0
- package/dist/modules/devices/services/device-command-graph.service.js +1 -1
- package/dist/modules/devices/services/device-command-graph.service.js.map +1 -1
- package/dist/modules/devices/services/device-connection-state.service.d.ts +1 -0
- package/dist/modules/devices/services/device-connection-state.service.js +64 -18
- package/dist/modules/devices/services/device-connection-state.service.js.map +1 -1
- package/dist/modules/devices/services/device-connectivity.service.js +96 -51
- package/dist/modules/devices/services/device-connectivity.service.js.map +1 -1
- package/dist/modules/devices/services/device-contribution.registry.service.d.ts +50 -0
- package/dist/modules/devices/services/device-contribution.registry.service.js +45 -0
- package/dist/modules/devices/services/device-contribution.registry.service.js.map +1 -0
- package/dist/modules/devices/services/device-creation-context.d.ts +57 -0
- package/dist/modules/devices/services/device-creation-context.js +315 -0
- package/dist/modules/devices/services/device-creation-context.js.map +1 -0
- package/dist/modules/devices/services/device-structure-lock.service.d.ts +5 -0
- package/dist/modules/devices/services/device-structure-lock.service.js +64 -12
- package/dist/modules/devices/services/device-structure-lock.service.js.map +1 -1
- package/dist/modules/devices/services/device-validation.service.d.ts +0 -1
- package/dist/modules/devices/services/device-validation.service.js +3 -14
- package/dist/modules/devices/services/device-validation.service.js.map +1 -1
- package/dist/modules/devices/services/device-zones.service.d.ts +3 -1
- package/dist/modules/devices/services/device-zones.service.js +30 -6
- package/dist/modules/devices/services/device-zones.service.js.map +1 -1
- package/dist/modules/devices/services/devices-type-mapper.service.d.ts +3 -0
- package/dist/modules/devices/services/devices-type-mapper.service.js +21 -1
- package/dist/modules/devices/services/devices-type-mapper.service.js.map +1 -1
- package/dist/modules/devices/services/devices.service.d.ts +8 -2
- package/dist/modules/devices/services/devices.service.js +194 -49
- package/dist/modules/devices/services/devices.service.js.map +1 -1
- package/dist/modules/devices/services/platform.registry.service.d.ts +11 -1
- package/dist/modules/devices/services/platform.registry.service.js +42 -5
- package/dist/modules/devices/services/platform.registry.service.js.map +1 -1
- package/dist/modules/devices/services/property-command-admission.registry.service.d.ts +28 -0
- package/dist/modules/devices/services/property-command-admission.registry.service.js +70 -0
- package/dist/modules/devices/services/property-command-admission.registry.service.js.map +1 -0
- package/dist/modules/devices/services/property-command-dispatch.service.d.ts +28 -2
- package/dist/modules/devices/services/property-command-dispatch.service.js +704 -10
- package/dist/modules/devices/services/property-command-dispatch.service.js.map +1 -1
- package/dist/modules/devices/services/property-command-entry-snapshot.d.ts +25 -0
- package/dist/modules/devices/services/property-command-entry-snapshot.js +87 -0
- package/dist/modules/devices/services/property-command-entry-snapshot.js.map +1 -0
- package/dist/modules/devices/services/property-command-window.service.d.ts +22 -0
- package/dist/modules/devices/services/property-command-window.service.js +81 -0
- package/dist/modules/devices/services/property-command-window.service.js.map +1 -1
- package/dist/modules/devices/services/property-command.service.d.ts +24 -3
- package/dist/modules/devices/services/property-command.service.js +180 -18
- package/dist/modules/devices/services/property-command.service.js.map +1 -1
- package/dist/modules/devices/services/property-metadata.service.js +1 -1
- package/dist/modules/devices/services/property-metadata.service.js.map +1 -1
- package/dist/modules/devices/services/property-producer.registry.service.d.ts +98 -0
- package/dist/modules/devices/services/property-producer.registry.service.js +636 -0
- package/dist/modules/devices/services/property-producer.registry.service.js.map +1 -0
- package/dist/modules/devices/services/property-value-source.registry.service.d.ts +18 -0
- package/dist/modules/devices/services/property-value-source.registry.service.js +291 -2
- package/dist/modules/devices/services/property-value-source.registry.service.js.map +1 -1
- package/dist/modules/devices/services/property-value.service.d.ts +40 -3
- package/dist/modules/devices/services/property-value.service.js +744 -193
- package/dist/modules/devices/services/property-value.service.js.map +1 -1
- package/dist/modules/devices/subscribers/channel-property-entity.subscriber.d.ts +5 -0
- package/dist/modules/devices/subscribers/channel-property-entity.subscriber.js +25 -0
- package/dist/modules/devices/subscribers/channel-property-entity.subscriber.js.map +1 -1
- package/dist/modules/devices/utils/property-metadata.utils.d.ts +1 -0
- package/dist/modules/devices/utils/property-metadata.utils.js +10 -0
- package/dist/modules/devices/utils/property-metadata.utils.js.map +1 -1
- package/dist/modules/devices/utils/property-permissions.utils.d.ts +2 -0
- package/dist/modules/devices/utils/property-permissions.utils.js +10 -0
- package/dist/modules/devices/utils/property-permissions.utils.js.map +1 -0
- package/dist/modules/extensions/services/discovered-backend.module.d.ts +6 -0
- package/dist/modules/extensions/services/discovered-backend.module.js +32 -0
- package/dist/modules/extensions/services/discovered-backend.module.js.map +1 -0
- package/dist/modules/extensions/services/extensions-discovery.js +15 -0
- package/dist/modules/extensions/services/extensions-discovery.js.map +1 -1
- package/dist/modules/extensions/services/extensions.service.d.ts +4 -0
- package/dist/modules/extensions/services/extensions.service.js +13 -0
- package/dist/modules/extensions/services/extensions.service.js.map +1 -1
- package/dist/modules/extensions/services/managed-extension-service.interface.d.ts +1 -0
- package/dist/modules/extensions/services/managed-service-manager.service.d.ts +15 -0
- package/dist/modules/extensions/services/managed-service-manager.service.js +242 -72
- package/dist/modules/extensions/services/managed-service-manager.service.js.map +1 -1
- package/dist/modules/home-context/schemas/home-search-input.schemas.d.ts +1 -1
- package/dist/modules/intents/models/intent.model.d.ts +2 -0
- package/dist/modules/intents/models/intent.model.js +14 -0
- package/dist/modules/intents/models/intent.model.js.map +1 -1
- package/dist/modules/intents/services/intents.service.d.ts +2 -1
- package/dist/modules/intents/services/intents.service.js +18 -2
- package/dist/modules/intents/services/intents.service.js.map +1 -1
- package/dist/modules/scenes/listeners/websocket-exchange.listener.js +4 -0
- package/dist/modules/scenes/listeners/websocket-exchange.listener.js.map +1 -1
- package/dist/modules/scenes/models/scenes.model.d.ts +2 -0
- package/dist/modules/scenes/models/scenes.model.js +10 -0
- package/dist/modules/scenes/models/scenes.model.js.map +1 -1
- package/dist/modules/scenes/services/scene-executor.service.d.ts +6 -1
- package/dist/modules/scenes/services/scene-executor.service.js +33 -22
- package/dist/modules/scenes/services/scene-executor.service.js.map +1 -1
- package/dist/modules/security/providers/alarm-security.provider.d.ts +3 -1
- package/dist/modules/security/providers/alarm-security.provider.js +83 -8
- package/dist/modules/security/providers/alarm-security.provider.js.map +1 -1
- package/dist/modules/spaces/services/space-lifecycle-registry.service.d.ts +19 -0
- package/dist/modules/spaces/services/space-lifecycle-registry.service.js +121 -0
- package/dist/modules/spaces/services/space-lifecycle-registry.service.js.map +1 -0
- package/dist/modules/spaces/services/spaces.service.d.ts +5 -1
- package/dist/modules/spaces/services/spaces.service.js +34 -6
- package/dist/modules/spaces/services/spaces.service.js.map +1 -1
- package/dist/modules/spaces/spaces.constants.d.ts +3 -1
- package/dist/modules/spaces/spaces.constants.js +2 -0
- package/dist/modules/spaces/spaces.constants.js.map +1 -1
- package/dist/modules/spaces/spaces.module.js +13 -1
- package/dist/modules/spaces/spaces.module.js.map +1 -1
- package/dist/modules/storage/services/storage.service.d.ts +8 -0
- package/dist/modules/storage/services/storage.service.js +225 -0
- package/dist/modules/storage/services/storage.service.js.map +1 -1
- package/dist/modules/swagger/decorators/api-documentation.decorator.d.ts +1 -0
- package/dist/modules/swagger/decorators/api-documentation.decorator.js +9 -1
- package/dist/modules/swagger/decorators/api-documentation.decorator.js.map +1 -1
- package/dist/modules/swagger/services/swagger-document.service.d.ts +1 -0
- package/dist/modules/swagger/services/swagger-document.service.js +71 -1
- package/dist/modules/swagger/services/swagger-document.service.js.map +1 -1
- package/dist/modules/system/scripts/privileged/helper.py +3 -1
- package/dist/modules/system/services/backup.service.js +3 -5
- package/dist/modules/system/services/backup.service.js.map +1 -1
- package/dist/modules/system/services/update-executor.service.js +4 -6
- package/dist/modules/system/services/update-executor.service.js.map +1 -1
- package/dist/modules/system/services/update.service.js +1 -1
- package/dist/modules/system/services/update.service.js.map +1 -1
- package/dist/modules/system/system.constants.d.ts +2 -0
- package/dist/modules/system/system.constants.js +3 -1
- package/dist/modules/system/system.constants.js.map +1 -1
- package/dist/modules/system/utils/timezone.utils.d.ts +2 -0
- package/dist/modules/system/utils/timezone.utils.js +9 -0
- package/dist/modules/system/utils/timezone.utils.js.map +1 -0
- package/dist/modules/websocket/gateway/websocket.gateway.js +1 -0
- package/dist/modules/websocket/gateway/websocket.gateway.js.map +1 -1
- package/dist/plugins/devices-home-assistant/devices-home-assistant.plugin.js +2 -0
- package/dist/plugins/devices-home-assistant/devices-home-assistant.plugin.js.map +1 -1
- package/dist/plugins/devices-home-assistant/dto/update-channel-property.dto.d.ts +3 -3
- package/dist/plugins/devices-home-assistant/dto/update-channel-property.dto.js +3 -3
- package/dist/plugins/devices-home-assistant/dto/update-channel-property.dto.js.map +1 -1
- package/dist/plugins/devices-home-assistant/platforms/home-assistant.device.platform.d.ts +11 -1
- package/dist/plugins/devices-home-assistant/platforms/home-assistant.device.platform.js +82 -2
- package/dist/plugins/devices-home-assistant/platforms/home-assistant.device.platform.js.map +1 -1
- package/dist/plugins/devices-home-assistant/services/home-assistant-native-climate.service.d.ts +22 -0
- package/dist/plugins/devices-home-assistant/services/home-assistant-native-climate.service.js +409 -0
- package/dist/plugins/devices-home-assistant/services/home-assistant-native-climate.service.js.map +1 -0
- package/dist/plugins/devices-home-assistant/services/home-assistant.ws.service.d.ts +14 -0
- package/dist/plugins/devices-home-assistant/services/home-assistant.ws.service.js +93 -3
- package/dist/plugins/devices-home-assistant/services/home-assistant.ws.service.js.map +1 -1
- package/dist/plugins/devices-homekit/devices-homekit.plugin.js +28 -2
- package/dist/plugins/devices-homekit/devices-homekit.plugin.js.map +1 -1
- package/dist/plugins/devices-homekit/listeners/homekit-event.listener.d.ts +26 -3
- package/dist/plugins/devices-homekit/listeners/homekit-event.listener.js +183 -5
- package/dist/plugins/devices-homekit/listeners/homekit-event.listener.js.map +1 -1
- package/dist/plugins/devices-homekit/mappers/base.mapper.d.ts +2 -1
- package/dist/plugins/devices-homekit/mappers/base.mapper.js +38 -10
- package/dist/plugins/devices-homekit/mappers/base.mapper.js.map +1 -1
- package/dist/plugins/devices-homekit/mappers/battery.mapper.js +4 -3
- package/dist/plugins/devices-homekit/mappers/battery.mapper.js.map +1 -1
- package/dist/plugins/devices-homekit/mappers/button.mapper.js +21 -2
- package/dist/plugins/devices-homekit/mappers/button.mapper.js.map +1 -1
- package/dist/plugins/devices-homekit/mappers/characteristic-get.d.ts +3 -0
- package/dist/plugins/devices-homekit/mappers/characteristic-get.js +10 -0
- package/dist/plugins/devices-homekit/mappers/characteristic-get.js.map +1 -0
- package/dist/plugins/devices-homekit/mappers/characteristic-write.d.ts +1 -1
- package/dist/plugins/devices-homekit/mappers/characteristic-write.js +2 -1
- package/dist/plugins/devices-homekit/mappers/characteristic-write.js.map +1 -1
- package/dist/plugins/devices-homekit/mappers/fan.mapper.d.ts +12 -0
- package/dist/plugins/devices-homekit/mappers/fan.mapper.js +126 -0
- package/dist/plugins/devices-homekit/mappers/fan.mapper.js.map +1 -0
- package/dist/plugins/devices-homekit/mappers/homekit-mapper.interface.d.ts +8 -0
- package/dist/plugins/devices-homekit/mappers/outlet.mapper.js +4 -0
- package/dist/plugins/devices-homekit/mappers/outlet.mapper.js.map +1 -1
- package/dist/plugins/devices-homekit/mappers/property-read.d.ts +7 -0
- package/dist/plugins/devices-homekit/mappers/property-read.js +64 -0
- package/dist/plugins/devices-homekit/mappers/property-read.js.map +1 -0
- package/dist/plugins/devices-homekit/mappers/semantic-conversion.d.ts +2 -0
- package/dist/plugins/devices-homekit/mappers/semantic-conversion.js +15 -0
- package/dist/plugins/devices-homekit/mappers/semantic-conversion.js.map +1 -0
- package/dist/plugins/devices-homekit/mappers/sensor.mapper.d.ts +3 -0
- package/dist/plugins/devices-homekit/mappers/sensor.mapper.js +63 -11
- package/dist/plugins/devices-homekit/mappers/sensor.mapper.js.map +1 -1
- package/dist/plugins/devices-homekit/mappers/service-fault.d.ts +4 -0
- package/dist/plugins/devices-homekit/mappers/service-fault.js +33 -0
- package/dist/plugins/devices-homekit/mappers/service-fault.js.map +1 -0
- package/dist/plugins/devices-homekit/mappers/thermostat-coordinator.d.ts +4 -0
- package/dist/plugins/devices-homekit/mappers/thermostat-coordinator.js +128 -19
- package/dist/plugins/devices-homekit/mappers/thermostat-coordinator.js.map +1 -1
- package/dist/plugins/devices-homekit/mappers/thermostat.mapper.js +5 -3
- package/dist/plugins/devices-homekit/mappers/thermostat.mapper.js.map +1 -1
- package/dist/plugins/devices-homekit/mappers/unavailable-characteristic.d.ts +3 -0
- package/dist/plugins/devices-homekit/mappers/unavailable-characteristic.js +18 -0
- package/dist/plugins/devices-homekit/mappers/unavailable-characteristic.js.map +1 -0
- package/dist/plugins/devices-homekit/mappers/window-covering.mapper.js +19 -3
- package/dist/plugins/devices-homekit/mappers/window-covering.mapper.js.map +1 -1
- package/dist/plugins/devices-homekit/services/homekit-bridge.service.d.ts +4 -0
- package/dist/plugins/devices-homekit/services/homekit-bridge.service.js +58 -29
- package/dist/plugins/devices-homekit/services/homekit-bridge.service.js.map +1 -1
- package/dist/plugins/devices-homekit/services/homekit-command.dispatcher.d.ts +2 -0
- package/dist/plugins/devices-homekit/services/homekit-command.dispatcher.js +3 -0
- package/dist/plugins/devices-homekit/services/homekit-command.dispatcher.js.map +1 -1
- package/dist/plugins/devices-homekit/services/homekit-mapper-registry.service.d.ts +30 -2
- package/dist/plugins/devices-homekit/services/homekit-mapper-registry.service.js +126 -2
- package/dist/plugins/devices-homekit/services/homekit-mapper-registry.service.js.map +1 -1
- package/dist/plugins/devices-homekit/services/homekit-mapping-maintenance.d.ts +8 -0
- package/dist/plugins/devices-homekit/services/homekit-mapping-maintenance.js +17 -0
- package/dist/plugins/devices-homekit/services/homekit-mapping-maintenance.js.map +1 -0
- package/dist/plugins/devices-homekit/services/homekit-property-state.service.d.ts +19 -0
- package/dist/plugins/devices-homekit/services/homekit-property-state.service.js +69 -0
- package/dist/plugins/devices-homekit/services/homekit-property-state.service.js.map +1 -0
- package/dist/plugins/devices-shelly-ng/contracts/cover-action.contract.d.ts +13 -0
- package/dist/plugins/devices-shelly-ng/contracts/cover-action.contract.js +60 -0
- package/dist/plugins/devices-shelly-ng/contracts/cover-action.contract.js.map +1 -0
- package/dist/plugins/devices-shelly-ng/contracts/cover-recovery.contract.d.ts +13 -0
- package/dist/plugins/devices-shelly-ng/contracts/cover-recovery.contract.js +3 -0
- package/dist/plugins/devices-shelly-ng/contracts/cover-recovery.contract.js.map +1 -0
- package/dist/plugins/devices-shelly-ng/contracts/guard-script-source.d.ts +1 -0
- package/dist/plugins/devices-shelly-ng/contracts/guard-script-source.js +5 -0
- package/dist/plugins/devices-shelly-ng/contracts/guard-script-source.js.map +1 -0
- package/dist/plugins/devices-shelly-ng/contracts/guard-script.contract.d.ts +21 -0
- package/dist/plugins/devices-shelly-ng/contracts/guard-script.contract.js +47 -0
- package/dist/plugins/devices-shelly-ng/contracts/guard-script.contract.js.map +1 -0
- package/dist/plugins/devices-shelly-ng/contracts/member-guard-script-source.d.ts +2 -0
- package/dist/plugins/devices-shelly-ng/contracts/member-guard-script-source.js +27 -0
- package/dist/plugins/devices-shelly-ng/contracts/member-guard-script-source.js.map +1 -0
- package/dist/plugins/devices-shelly-ng/contracts/native-temperature.contract.d.ts +36 -0
- package/dist/plugins/devices-shelly-ng/contracts/native-temperature.contract.js +200 -0
- package/dist/plugins/devices-shelly-ng/contracts/native-temperature.contract.js.map +1 -0
- package/dist/plugins/devices-shelly-ng/contracts/protective-switch.contract.d.ts +44 -0
- package/dist/plugins/devices-shelly-ng/contracts/protective-switch.contract.js +29 -0
- package/dist/plugins/devices-shelly-ng/contracts/protective-switch.contract.js.map +1 -0
- package/dist/plugins/devices-shelly-ng/controllers/shelly-cover-recovery.controller.d.ts +11 -0
- package/dist/plugins/devices-shelly-ng/controllers/shelly-cover-recovery.controller.js +98 -0
- package/dist/plugins/devices-shelly-ng/controllers/shelly-cover-recovery.controller.js.map +1 -0
- package/dist/plugins/devices-shelly-ng/delegates/delegates-manager.service.d.ts +51 -1
- package/dist/plugins/devices-shelly-ng/delegates/delegates-manager.service.js +688 -2
- package/dist/plugins/devices-shelly-ng/delegates/delegates-manager.service.js.map +1 -1
- package/dist/plugins/devices-shelly-ng/delegates/shelly-device.delegate.d.ts +46 -1
- package/dist/plugins/devices-shelly-ng/delegates/shelly-device.delegate.js +315 -4
- package/dist/plugins/devices-shelly-ng/delegates/shelly-device.delegate.js.map +1 -1
- package/dist/plugins/devices-shelly-ng/devices-shelly-ng.openapi.d.ts +3 -1
- package/dist/plugins/devices-shelly-ng/devices-shelly-ng.openapi.js +8 -0
- package/dist/plugins/devices-shelly-ng/devices-shelly-ng.openapi.js.map +1 -1
- package/dist/plugins/devices-shelly-ng/devices-shelly-ng.plugin.js +16 -1
- package/dist/plugins/devices-shelly-ng/devices-shelly-ng.plugin.js.map +1 -1
- package/dist/plugins/devices-shelly-ng/dto/cover-recovery.dto.d.ts +11 -0
- package/dist/plugins/devices-shelly-ng/dto/cover-recovery.dto.js +77 -0
- package/dist/plugins/devices-shelly-ng/dto/cover-recovery.dto.js.map +1 -0
- package/dist/plugins/devices-shelly-ng/entities/shelly-cover-ordering.entity.d.ts +5 -0
- package/dist/plugins/devices-shelly-ng/entities/shelly-cover-ordering.entity.js +32 -0
- package/dist/plugins/devices-shelly-ng/entities/shelly-cover-ordering.entity.js.map +1 -0
- package/dist/plugins/devices-shelly-ng/entities/shelly-cover-recovery.entity.d.ts +17 -0
- package/dist/plugins/devices-shelly-ng/entities/shelly-cover-recovery.entity.js +80 -0
- package/dist/plugins/devices-shelly-ng/entities/shelly-cover-recovery.entity.js.map +1 -0
- package/dist/plugins/devices-shelly-ng/entities/shelly-sample-source.entity.d.ts +16 -0
- package/dist/plugins/devices-shelly-ng/entities/shelly-sample-source.entity.js +70 -0
- package/dist/plugins/devices-shelly-ng/entities/shelly-sample-source.entity.js.map +1 -0
- package/dist/plugins/devices-shelly-ng/mappings/definitions/covers.yaml +30 -24
- package/dist/plugins/devices-shelly-ng/models/cover-recovery.model.d.ts +21 -0
- package/dist/plugins/devices-shelly-ng/models/cover-recovery.model.js +114 -0
- package/dist/plugins/devices-shelly-ng/models/cover-recovery.model.js.map +1 -0
- package/dist/plugins/devices-shelly-ng/platforms/shelly-ng.device.platform.d.ts +27 -1
- package/dist/plugins/devices-shelly-ng/platforms/shelly-ng.device.platform.js +146 -0
- package/dist/plugins/devices-shelly-ng/platforms/shelly-ng.device.platform.js.map +1 -1
- package/dist/plugins/devices-shelly-ng/services/authenticated-shelly-script-http.d.ts +16 -0
- package/dist/plugins/devices-shelly-ng/services/authenticated-shelly-script-http.js +154 -0
- package/dist/plugins/devices-shelly-ng/services/authenticated-shelly-script-http.js.map +1 -0
- package/dist/plugins/devices-shelly-ng/services/device-manager.service.d.ts +4 -1
- package/dist/plugins/devices-shelly-ng/services/device-manager.service.js +113 -4
- package/dist/plugins/devices-shelly-ng/services/device-manager.service.js.map +1 -1
- package/dist/plugins/devices-shelly-ng/services/guarded-shelly-http.d.ts +2 -0
- package/dist/plugins/devices-shelly-ng/services/guarded-shelly-http.js +78 -0
- package/dist/plugins/devices-shelly-ng/services/guarded-shelly-http.js.map +1 -0
- package/dist/plugins/devices-shelly-ng/services/guarded-shelly-rpc.d.ts +9 -0
- package/dist/plugins/devices-shelly-ng/services/guarded-shelly-rpc.js +56 -0
- package/dist/plugins/devices-shelly-ng/services/guarded-shelly-rpc.js.map +1 -0
- package/dist/plugins/devices-shelly-ng/services/remote-dew-point-artifact.d.ts +45 -0
- package/dist/plugins/devices-shelly-ng/services/remote-dew-point-artifact.js +278 -0
- package/dist/plugins/devices-shelly-ng/services/remote-dew-point-artifact.js.map +1 -0
- package/dist/plugins/devices-shelly-ng/services/remote-dew-point-lease.contract.d.ts +49 -0
- package/dist/plugins/devices-shelly-ng/services/remote-dew-point-lease.contract.js +32 -0
- package/dist/plugins/devices-shelly-ng/services/remote-dew-point-lease.contract.js.map +1 -0
- package/dist/plugins/devices-shelly-ng/services/remote-dew-point-qualification.d.ts +53 -0
- package/dist/plugins/devices-shelly-ng/services/remote-dew-point-qualification.js +91 -0
- package/dist/plugins/devices-shelly-ng/services/remote-dew-point-qualification.js.map +1 -0
- package/dist/plugins/devices-shelly-ng/services/remote-dew-point-session.d.ts +35 -0
- package/dist/plugins/devices-shelly-ng/services/remote-dew-point-session.js +244 -0
- package/dist/plugins/devices-shelly-ng/services/remote-dew-point-session.js.map +1 -0
- package/dist/plugins/devices-shelly-ng/services/shelly-cover-ordering.service.d.ts +9 -0
- package/dist/plugins/devices-shelly-ng/services/shelly-cover-ordering.service.js +50 -0
- package/dist/plugins/devices-shelly-ng/services/shelly-cover-ordering.service.js.map +1 -0
- package/dist/plugins/devices-shelly-ng/services/shelly-cover-recovery-lane.service.d.ts +29 -0
- package/dist/plugins/devices-shelly-ng/services/shelly-cover-recovery-lane.service.js +166 -0
- package/dist/plugins/devices-shelly-ng/services/shelly-cover-recovery-lane.service.js.map +1 -0
- package/dist/plugins/devices-shelly-ng/services/shelly-cover-recovery.service.d.ts +21 -0
- package/dist/plugins/devices-shelly-ng/services/shelly-cover-recovery.service.js +207 -0
- package/dist/plugins/devices-shelly-ng/services/shelly-cover-recovery.service.js.map +1 -0
- package/dist/plugins/devices-shelly-ng/services/shelly-cover-session.d.ts +25 -0
- package/dist/plugins/devices-shelly-ng/services/shelly-cover-session.js +132 -0
- package/dist/plugins/devices-shelly-ng/services/shelly-cover-session.js.map +1 -0
- package/dist/plugins/devices-shelly-ng/services/shelly-cover-telemetry.d.ts +9 -0
- package/dist/plugins/devices-shelly-ng/services/shelly-cover-telemetry.js +63 -0
- package/dist/plugins/devices-shelly-ng/services/shelly-cover-telemetry.js.map +1 -0
- package/dist/plugins/devices-shelly-ng/services/shelly-guard-rpc-session.d.ts +33 -0
- package/dist/plugins/devices-shelly-ng/services/shelly-guard-rpc-session.js +191 -0
- package/dist/plugins/devices-shelly-ng/services/shelly-guard-rpc-session.js.map +1 -0
- package/dist/plugins/devices-shelly-ng/services/shelly-ng.service.d.ts +3 -0
- package/dist/plugins/devices-shelly-ng/services/shelly-ng.service.js +32 -4
- package/dist/plugins/devices-shelly-ng/services/shelly-ng.service.js.map +1 -1
- package/dist/plugins/devices-shelly-ng/services/shelly-sample-sources.service.d.ts +34 -0
- package/dist/plugins/devices-shelly-ng/services/shelly-sample-sources.service.js +194 -0
- package/dist/plugins/devices-shelly-ng/services/shelly-sample-sources.service.js.map +1 -0
- package/dist/plugins/devices-shelly-ng/services/shelly-ws-server.service.js +5 -2
- package/dist/plugins/devices-shelly-ng/services/shelly-ws-server.service.js.map +1 -1
- package/dist/plugins/devices-shelly-v1/platforms/shelly-v1.device.platform.d.ts +4 -0
- package/dist/plugins/devices-shelly-v1/platforms/shelly-v1.device.platform.js +3 -0
- package/dist/plugins/devices-shelly-v1/platforms/shelly-v1.device.platform.js.map +1 -1
- package/dist/plugins/devices-virtual/contracts/thermostat-actuation.contract.d.ts +114 -0
- package/dist/plugins/devices-virtual/contracts/thermostat-actuation.contract.js +12 -0
- package/dist/plugins/devices-virtual/contracts/thermostat-actuation.contract.js.map +1 -0
- package/dist/plugins/devices-virtual/contracts/thermostat-command.contract.d.ts +4 -0
- package/dist/plugins/devices-virtual/contracts/thermostat-command.contract.js +3 -0
- package/dist/plugins/devices-virtual/contracts/thermostat-command.contract.js.map +1 -0
- package/dist/plugins/devices-virtual/controllers/native-thermostat.controller.d.ts +15 -0
- package/dist/plugins/devices-virtual/controllers/native-thermostat.controller.js +178 -0
- package/dist/plugins/devices-virtual/controllers/native-thermostat.controller.js.map +1 -0
- package/dist/plugins/devices-virtual/controllers/thermostat-authoring-context.controller.d.ts +11 -0
- package/dist/plugins/devices-virtual/controllers/thermostat-authoring-context.controller.js +92 -0
- package/dist/plugins/devices-virtual/controllers/thermostat-authoring-context.controller.js.map +1 -0
- package/dist/plugins/devices-virtual/controllers/thermostat-installation.controller.d.ts +16 -0
- package/dist/plugins/devices-virtual/controllers/thermostat-installation.controller.js +179 -0
- package/dist/plugins/devices-virtual/controllers/thermostat-installation.controller.js.map +1 -0
- package/dist/plugins/devices-virtual/controllers/virtual-dew-point-config.controller.d.ts +11 -0
- package/dist/plugins/devices-virtual/controllers/virtual-dew-point-config.controller.js +100 -0
- package/dist/plugins/devices-virtual/controllers/virtual-dew-point-config.controller.js.map +1 -0
- package/dist/plugins/devices-virtual/controllers/virtual-measurement-authoring.controller.d.ts +19 -0
- package/dist/plugins/devices-virtual/controllers/virtual-measurement-authoring.controller.js +168 -0
- package/dist/plugins/devices-virtual/controllers/virtual-measurement-authoring.controller.js.map +1 -0
- package/dist/plugins/devices-virtual/controllers/virtual-producer-config.controller.d.ts +28 -0
- package/dist/plugins/devices-virtual/controllers/virtual-producer-config.controller.js +278 -0
- package/dist/plugins/devices-virtual/controllers/virtual-producer-config.controller.js.map +1 -0
- package/dist/plugins/devices-virtual/controllers/virtual-thermostat-authoring.controller.d.ts +12 -0
- package/dist/plugins/devices-virtual/controllers/virtual-thermostat-authoring.controller.js +111 -0
- package/dist/plugins/devices-virtual/controllers/virtual-thermostat-authoring.controller.js.map +1 -0
- package/dist/plugins/devices-virtual/controllers/virtual-thermostat-comfort.controller.d.ts +14 -0
- package/dist/plugins/devices-virtual/controllers/virtual-thermostat-comfort.controller.js +160 -0
- package/dist/plugins/devices-virtual/controllers/virtual-thermostat-comfort.controller.js.map +1 -0
- package/dist/plugins/devices-virtual/controllers/virtual-thermostat-config.controller.d.ts +18 -0
- package/dist/plugins/devices-virtual/controllers/virtual-thermostat-config.controller.js +196 -0
- package/dist/plugins/devices-virtual/controllers/virtual-thermostat-config.controller.js.map +1 -0
- package/dist/plugins/devices-virtual/controllers/virtual-transform-config.controller.d.ts +14 -0
- package/dist/plugins/devices-virtual/controllers/virtual-transform-config.controller.js +128 -0
- package/dist/plugins/devices-virtual/controllers/virtual-transform-config.controller.js.map +1 -0
- package/dist/plugins/devices-virtual/devices-virtual.constants.d.ts +1 -0
- package/dist/plugins/devices-virtual/devices-virtual.constants.js +2 -1
- package/dist/plugins/devices-virtual/devices-virtual.constants.js.map +1 -1
- package/dist/plugins/devices-virtual/devices-virtual.openapi.d.ts +24 -2
- package/dist/plugins/devices-virtual/devices-virtual.openapi.js +95 -0
- package/dist/plugins/devices-virtual/devices-virtual.openapi.js.map +1 -1
- package/dist/plugins/devices-virtual/devices-virtual.plugin.d.ts +7 -1
- package/dist/plugins/devices-virtual/devices-virtual.plugin.js +167 -10
- package/dist/plugins/devices-virtual/devices-virtual.plugin.js.map +1 -1
- package/dist/plugins/devices-virtual/dto/create-device.dto.d.ts +2 -0
- package/dist/plugins/devices-virtual/dto/create-device.dto.js +20 -0
- package/dist/plugins/devices-virtual/dto/create-device.dto.js.map +1 -1
- package/dist/plugins/devices-virtual/dto/dew-point-config.dto.d.ts +14 -0
- package/dist/plugins/devices-virtual/dto/dew-point-config.dto.js +119 -0
- package/dist/plugins/devices-virtual/dto/dew-point-config.dto.js.map +1 -0
- package/dist/plugins/devices-virtual/dto/group-catalog.dto.d.ts +8 -0
- package/dist/plugins/devices-virtual/dto/group-catalog.dto.js +62 -0
- package/dist/plugins/devices-virtual/dto/group-catalog.dto.js.map +1 -0
- package/dist/plugins/devices-virtual/dto/light-group-draft.dto.d.ts +19 -0
- package/dist/plugins/devices-virtual/dto/light-group-draft.dto.js +108 -0
- package/dist/plugins/devices-virtual/dto/light-group-draft.dto.js.map +1 -0
- package/dist/plugins/devices-virtual/dto/measurement-authoring.dto.d.ts +25 -0
- package/dist/plugins/devices-virtual/dto/measurement-authoring.dto.js +157 -0
- package/dist/plugins/devices-virtual/dto/measurement-authoring.dto.js.map +1 -0
- package/dist/plugins/devices-virtual/dto/native-thermostat.dto.d.ts +21 -0
- package/dist/plugins/devices-virtual/dto/native-thermostat.dto.js +122 -0
- package/dist/plugins/devices-virtual/dto/native-thermostat.dto.js.map +1 -0
- package/dist/plugins/devices-virtual/dto/producer-config.dto.d.ts +35 -0
- package/dist/plugins/devices-virtual/dto/producer-config.dto.js +290 -0
- package/dist/plugins/devices-virtual/dto/producer-config.dto.js.map +1 -0
- package/dist/plugins/devices-virtual/dto/thermostat-authoring.dto.d.ts +6 -0
- package/dist/plugins/devices-virtual/dto/thermostat-authoring.dto.js +46 -0
- package/dist/plugins/devices-virtual/dto/thermostat-authoring.dto.js.map +1 -0
- package/dist/plugins/devices-virtual/dto/thermostat-comfort.dto.d.ts +39 -0
- package/dist/plugins/devices-virtual/dto/thermostat-comfort.dto.js +244 -0
- package/dist/plugins/devices-virtual/dto/thermostat-comfort.dto.js.map +1 -0
- package/dist/plugins/devices-virtual/dto/thermostat-config.dto.d.ts +94 -0
- package/dist/plugins/devices-virtual/dto/thermostat-config.dto.js +718 -0
- package/dist/plugins/devices-virtual/dto/thermostat-config.dto.js.map +1 -0
- package/dist/plugins/devices-virtual/dto/thermostat-installation.dto.d.ts +71 -0
- package/dist/plugins/devices-virtual/dto/thermostat-installation.dto.js +410 -0
- package/dist/plugins/devices-virtual/dto/thermostat-installation.dto.js.map +1 -0
- package/dist/plugins/devices-virtual/dto/transform-config.dto.d.ts +71 -0
- package/dist/plugins/devices-virtual/dto/transform-config.dto.js +430 -0
- package/dist/plugins/devices-virtual/dto/transform-config.dto.js.map +1 -0
- package/dist/plugins/devices-virtual/dto/update-device.dto.d.ts +2 -0
- package/dist/plugins/devices-virtual/dto/update-device.dto.js +20 -0
- package/dist/plugins/devices-virtual/dto/update-device.dto.js.map +1 -1
- package/dist/plugins/devices-virtual/entities/devices-virtual.entity.d.ts +13 -1
- package/dist/plugins/devices-virtual/entities/devices-virtual.entity.js +56 -6
- package/dist/plugins/devices-virtual/entities/devices-virtual.entity.js.map +1 -1
- package/dist/plugins/devices-virtual/entities/native-thermostat.entity.d.ts +23 -0
- package/dist/plugins/devices-virtual/entities/native-thermostat.entity.js +103 -0
- package/dist/plugins/devices-virtual/entities/native-thermostat.entity.js.map +1 -0
- package/dist/plugins/devices-virtual/entities/thermostat-cooling-dependency.entity.d.ts +19 -0
- package/dist/plugins/devices-virtual/entities/thermostat-cooling-dependency.entity.js +87 -0
- package/dist/plugins/devices-virtual/entities/thermostat-cooling-dependency.entity.js.map +1 -0
- package/dist/plugins/devices-virtual/entities/thermostat-installation.entity.d.ts +36 -0
- package/dist/plugins/devices-virtual/entities/thermostat-installation.entity.js +125 -0
- package/dist/plugins/devices-virtual/entities/thermostat-installation.entity.js.map +1 -0
- package/dist/plugins/devices-virtual/entities/thermostat-member-protection.entity.d.ts +15 -0
- package/dist/plugins/devices-virtual/entities/thermostat-member-protection.entity.js +70 -0
- package/dist/plugins/devices-virtual/entities/thermostat-member-protection.entity.js.map +1 -0
- package/dist/plugins/devices-virtual/entities/thermostat-override-clock.entity.d.ts +7 -0
- package/dist/plugins/devices-virtual/entities/thermostat-override-clock.entity.js +39 -0
- package/dist/plugins/devices-virtual/entities/thermostat-override-clock.entity.js.map +1 -0
- package/dist/plugins/devices-virtual/entities/virtual-dew-point.entity.d.ts +28 -0
- package/dist/plugins/devices-virtual/entities/virtual-dew-point.entity.js +104 -0
- package/dist/plugins/devices-virtual/entities/virtual-dew-point.entity.js.map +1 -0
- package/dist/plugins/devices-virtual/entities/virtual-producer.entity.d.ts +89 -0
- package/dist/plugins/devices-virtual/entities/virtual-producer.entity.js +281 -0
- package/dist/plugins/devices-virtual/entities/virtual-producer.entity.js.map +1 -0
- package/dist/plugins/devices-virtual/entities/virtual-thermostat-runtime.entity.d.ts +45 -0
- package/dist/plugins/devices-virtual/entities/virtual-thermostat-runtime.entity.js +184 -0
- package/dist/plugins/devices-virtual/entities/virtual-thermostat-runtime.entity.js.map +1 -0
- package/dist/plugins/devices-virtual/entities/virtual-thermostat.entity.d.ts +86 -0
- package/dist/plugins/devices-virtual/entities/virtual-thermostat.entity.js +337 -0
- package/dist/plugins/devices-virtual/entities/virtual-thermostat.entity.js.map +1 -0
- package/dist/plugins/devices-virtual/entities/virtual-transform.entity.d.ts +23 -0
- package/dist/plugins/devices-virtual/entities/virtual-transform.entity.js +101 -0
- package/dist/plugins/devices-virtual/entities/virtual-transform.entity.js.map +1 -0
- package/dist/plugins/devices-virtual/listeners/virtual-device-information.listener.d.ts +5 -0
- package/dist/plugins/devices-virtual/listeners/virtual-device-information.listener.js +65 -22
- package/dist/plugins/devices-virtual/listeners/virtual-device-information.listener.js.map +1 -1
- package/dist/plugins/devices-virtual/listeners/virtual-index-maintenance.listener.d.ts +8 -1
- package/dist/plugins/devices-virtual/listeners/virtual-index-maintenance.listener.js +123 -32
- package/dist/plugins/devices-virtual/listeners/virtual-index-maintenance.listener.js.map +1 -1
- package/dist/plugins/devices-virtual/listeners/virtual-projection.listener.d.ts +3 -0
- package/dist/plugins/devices-virtual/listeners/virtual-projection.listener.js +41 -3
- package/dist/plugins/devices-virtual/listeners/virtual-projection.listener.js.map +1 -1
- package/dist/plugins/devices-virtual/listeners/virtual-status.listener.js +28 -15
- package/dist/plugins/devices-virtual/listeners/virtual-status.listener.js.map +1 -1
- package/dist/plugins/devices-virtual/models/dew-point-response.model.d.ts +38 -0
- package/dist/plugins/devices-virtual/models/dew-point-response.model.js +193 -0
- package/dist/plugins/devices-virtual/models/dew-point-response.model.js.map +1 -0
- package/dist/plugins/devices-virtual/models/group-catalog.model.d.ts +26 -0
- package/dist/plugins/devices-virtual/models/group-catalog.model.js +117 -0
- package/dist/plugins/devices-virtual/models/group-catalog.model.js.map +1 -0
- package/dist/plugins/devices-virtual/models/light-group-draft.model.d.ts +28 -0
- package/dist/plugins/devices-virtual/models/light-group-draft.model.js +122 -0
- package/dist/plugins/devices-virtual/models/light-group-draft.model.js.map +1 -0
- package/dist/plugins/devices-virtual/models/measurement-authoring-response.model.d.ts +26 -0
- package/dist/plugins/devices-virtual/models/measurement-authoring-response.model.js +125 -0
- package/dist/plugins/devices-virtual/models/measurement-authoring-response.model.js.map +1 -0
- package/dist/plugins/devices-virtual/models/native-thermostat-response.model.d.ts +84 -0
- package/dist/plugins/devices-virtual/models/native-thermostat-response.model.js +406 -0
- package/dist/plugins/devices-virtual/models/native-thermostat-response.model.js.map +1 -0
- package/dist/plugins/devices-virtual/models/numeric-operator.model.d.ts +23 -0
- package/dist/plugins/devices-virtual/models/numeric-operator.model.js +120 -0
- package/dist/plugins/devices-virtual/models/numeric-operator.model.js.map +1 -0
- package/dist/plugins/devices-virtual/models/producer-response.model.d.ts +138 -0
- package/dist/plugins/devices-virtual/models/producer-response.model.js +764 -0
- package/dist/plugins/devices-virtual/models/producer-response.model.js.map +1 -0
- package/dist/plugins/devices-virtual/models/thermostat-authoring-context.model.d.ts +22 -0
- package/dist/plugins/devices-virtual/models/thermostat-authoring-context.model.js +134 -0
- package/dist/plugins/devices-virtual/models/thermostat-authoring-context.model.js.map +1 -0
- package/dist/plugins/devices-virtual/models/thermostat-authoring-response.model.d.ts +18 -0
- package/dist/plugins/devices-virtual/models/thermostat-authoring-response.model.js +87 -0
- package/dist/plugins/devices-virtual/models/thermostat-authoring-response.model.js.map +1 -0
- package/dist/plugins/devices-virtual/models/thermostat-comfort-response.model.d.ts +60 -0
- package/dist/plugins/devices-virtual/models/thermostat-comfort-response.model.js +341 -0
- package/dist/plugins/devices-virtual/models/thermostat-comfort-response.model.js.map +1 -0
- package/dist/plugins/devices-virtual/models/thermostat-installation-response.model.d.ts +84 -0
- package/dist/plugins/devices-virtual/models/thermostat-installation-response.model.js +440 -0
- package/dist/plugins/devices-virtual/models/thermostat-installation-response.model.js.map +1 -0
- package/dist/plugins/devices-virtual/models/thermostat-response.model.d.ts +218 -0
- package/dist/plugins/devices-virtual/models/thermostat-response.model.js +1157 -0
- package/dist/plugins/devices-virtual/models/thermostat-response.model.js.map +1 -0
- package/dist/plugins/devices-virtual/models/transform-response.model.d.ts +73 -0
- package/dist/plugins/devices-virtual/models/transform-response.model.js +386 -0
- package/dist/plugins/devices-virtual/models/transform-response.model.js.map +1 -0
- package/dist/plugins/devices-virtual/platforms/virtual-device.platform.d.ts +5 -1
- package/dist/plugins/devices-virtual/platforms/virtual-device.platform.js +22 -3
- package/dist/plugins/devices-virtual/platforms/virtual-device.platform.js.map +1 -1
- package/dist/plugins/devices-virtual/services/native-thermostat.service.d.ts +72 -0
- package/dist/plugins/devices-virtual/services/native-thermostat.service.js +932 -0
- package/dist/plugins/devices-virtual/services/native-thermostat.service.js.map +1 -0
- package/dist/plugins/devices-virtual/services/thermostat-authoring-context.service.d.ts +14 -0
- package/dist/plugins/devices-virtual/services/thermostat-authoring-context.service.js +147 -0
- package/dist/plugins/devices-virtual/services/thermostat-authoring-context.service.js.map +1 -0
- package/dist/plugins/devices-virtual/services/thermostat-comfort-selection.d.ts +199 -0
- package/dist/plugins/devices-virtual/services/thermostat-comfort-selection.js +1064 -0
- package/dist/plugins/devices-virtual/services/thermostat-comfort-selection.js.map +1 -0
- package/dist/plugins/devices-virtual/services/thermostat-controller-mutation.d.ts +75 -0
- package/dist/plugins/devices-virtual/services/thermostat-controller-mutation.js +445 -0
- package/dist/plugins/devices-virtual/services/thermostat-controller-mutation.js.map +1 -0
- package/dist/plugins/devices-virtual/services/thermostat-cooling-dependency.service.d.ts +53 -0
- package/dist/plugins/devices-virtual/services/thermostat-cooling-dependency.service.js +267 -0
- package/dist/plugins/devices-virtual/services/thermostat-cooling-dependency.service.js.map +1 -0
- package/dist/plugins/devices-virtual/services/thermostat-creation-catalog.d.ts +56 -0
- package/dist/plugins/devices-virtual/services/thermostat-creation-catalog.js +438 -0
- package/dist/plugins/devices-virtual/services/thermostat-creation-catalog.js.map +1 -0
- package/dist/plugins/devices-virtual/services/thermostat-creation-response.d.ts +37 -0
- package/dist/plugins/devices-virtual/services/thermostat-creation-response.js +430 -0
- package/dist/plugins/devices-virtual/services/thermostat-creation-response.js.map +1 -0
- package/dist/plugins/devices-virtual/services/thermostat-installation-artifact.d.ts +13 -0
- package/dist/plugins/devices-virtual/services/thermostat-installation-artifact.js +263 -0
- package/dist/plugins/devices-virtual/services/thermostat-installation-artifact.js.map +1 -0
- package/dist/plugins/devices-virtual/services/thermostat-installation-bindings.service.d.ts +10 -0
- package/dist/plugins/devices-virtual/services/thermostat-installation-bindings.service.js +238 -0
- package/dist/plugins/devices-virtual/services/thermostat-installation-bindings.service.js.map +1 -0
- package/dist/plugins/devices-virtual/services/thermostat-installation-loader.service.d.ts +41 -0
- package/dist/plugins/devices-virtual/services/thermostat-installation-loader.service.js +350 -0
- package/dist/plugins/devices-virtual/services/thermostat-installation-loader.service.js.map +1 -0
- package/dist/plugins/devices-virtual/services/thermostat-installation.service.d.ts +40 -0
- package/dist/plugins/devices-virtual/services/thermostat-installation.service.js +263 -0
- package/dist/plugins/devices-virtual/services/thermostat-installation.service.js.map +1 -0
- package/dist/plugins/devices-virtual/services/thermostat-installation.types.d.ts +72 -0
- package/dist/plugins/devices-virtual/services/thermostat-installation.types.js +13 -0
- package/dist/plugins/devices-virtual/services/thermostat-installation.types.js.map +1 -0
- package/dist/plugins/devices-virtual/services/thermostat-member-protection.service.d.ts +45 -0
- package/dist/plugins/devices-virtual/services/thermostat-member-protection.service.js +235 -0
- package/dist/plugins/devices-virtual/services/thermostat-member-protection.service.js.map +1 -0
- package/dist/plugins/devices-virtual/services/thermostat-override-clock.sql.d.ts +1 -0
- package/dist/plugins/devices-virtual/services/thermostat-override-clock.sql.js +16 -0
- package/dist/plugins/devices-virtual/services/thermostat-override-clock.sql.js.map +1 -0
- package/dist/plugins/devices-virtual/services/thermostat-protection-source.utils.d.ts +27 -0
- package/dist/plugins/devices-virtual/services/thermostat-protection-source.utils.js +132 -0
- package/dist/plugins/devices-virtual/services/thermostat-protection-source.utils.js.map +1 -0
- package/dist/plugins/devices-virtual/services/thermostat-remote-cooling-adapter.d.ts +88 -0
- package/dist/plugins/devices-virtual/services/thermostat-remote-cooling-adapter.js +200 -0
- package/dist/plugins/devices-virtual/services/thermostat-remote-cooling-adapter.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-aggregate-evaluator.d.ts +35 -0
- package/dist/plugins/devices-virtual/services/virtual-aggregate-evaluator.js +200 -0
- package/dist/plugins/devices-virtual/services/virtual-aggregate-evaluator.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-aggregate-policy.utils.d.ts +5 -0
- package/dist/plugins/devices-virtual/services/virtual-aggregate-policy.utils.js +18 -0
- package/dist/plugins/devices-virtual/services/virtual-aggregate-policy.utils.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-aggregate-runtime.service.d.ts +48 -0
- package/dist/plugins/devices-virtual/services/virtual-aggregate-runtime.service.js +425 -0
- package/dist/plugins/devices-virtual/services/virtual-aggregate-runtime.service.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-cooling-policy.utils.d.ts +13 -0
- package/dist/plugins/devices-virtual/services/virtual-cooling-policy.utils.js +38 -0
- package/dist/plugins/devices-virtual/services/virtual-cooling-policy.utils.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-cover-contract.utils.d.ts +7 -0
- package/dist/plugins/devices-virtual/services/virtual-cover-contract.utils.js +41 -0
- package/dist/plugins/devices-virtual/services/virtual-cover-contract.utils.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-cover-readiness.utils.d.ts +16 -0
- package/dist/plugins/devices-virtual/services/virtual-cover-readiness.utils.js +42 -0
- package/dist/plugins/devices-virtual/services/virtual-cover-readiness.utils.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-dependency-graph.service.d.ts +118 -0
- package/dist/plugins/devices-virtual/services/virtual-dependency-graph.service.js +667 -0
- package/dist/plugins/devices-virtual/services/virtual-dependency-graph.service.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-devices.service.d.ts +8 -4
- package/dist/plugins/devices-virtual/services/virtual-devices.service.js +105 -22
- package/dist/plugins/devices-virtual/services/virtual-devices.service.js.map +1 -1
- package/dist/plugins/devices-virtual/services/virtual-dew-point-config.service.d.ts +28 -0
- package/dist/plugins/devices-virtual/services/virtual-dew-point-config.service.js +193 -0
- package/dist/plugins/devices-virtual/services/virtual-dew-point-config.service.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-dew-point-contract.utils.d.ts +5 -0
- package/dist/plugins/devices-virtual/services/virtual-dew-point-contract.utils.js +69 -0
- package/dist/plugins/devices-virtual/services/virtual-dew-point-contract.utils.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-dew-point-runtime.service.d.ts +65 -0
- package/dist/plugins/devices-virtual/services/virtual-dew-point-runtime.service.js +524 -0
- package/dist/plugins/devices-virtual/services/virtual-dew-point-runtime.service.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-dew-point.utils.d.ts +9 -0
- package/dist/plugins/devices-virtual/services/virtual-dew-point.utils.js +25 -0
- package/dist/plugins/devices-virtual/services/virtual-dew-point.utils.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-group-catalog.service.d.ts +10 -0
- package/dist/plugins/devices-virtual/services/virtual-group-catalog.service.js +117 -0
- package/dist/plugins/devices-virtual/services/virtual-group-catalog.service.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-group-contract.utils.d.ts +4 -0
- package/dist/plugins/devices-virtual/services/virtual-group-contract.utils.js +35 -0
- package/dist/plugins/devices-virtual/services/virtual-group-contract.utils.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-group-field.utils.d.ts +10 -0
- package/dist/plugins/devices-virtual/services/virtual-group-field.utils.js +35 -0
- package/dist/plugins/devices-virtual/services/virtual-group-field.utils.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-group-profile.d.ts +19 -0
- package/dist/plugins/devices-virtual/services/virtual-group-profile.js +137 -0
- package/dist/plugins/devices-virtual/services/virtual-group-profile.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-light-group-authoring.service.d.ts +43 -0
- package/dist/plugins/devices-virtual/services/virtual-light-group-authoring.service.js +217 -0
- package/dist/plugins/devices-virtual/services/virtual-light-group-authoring.service.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-light-group-command.service.d.ts +28 -0
- package/dist/plugins/devices-virtual/services/virtual-light-group-command.service.js +262 -0
- package/dist/plugins/devices-virtual/services/virtual-light-group-command.service.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-light-group-contribution.service.d.ts +19 -0
- package/dist/plugins/devices-virtual/services/virtual-light-group-contribution.service.js +91 -0
- package/dist/plugins/devices-virtual/services/virtual-light-group-contribution.service.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-light-group-state.service.d.ts +37 -0
- package/dist/plugins/devices-virtual/services/virtual-light-group-state.service.js +346 -0
- package/dist/plugins/devices-virtual/services/virtual-light-group-state.service.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-light-group.utils.d.ts +46 -0
- package/dist/plugins/devices-virtual/services/virtual-light-group.utils.js +204 -0
- package/dist/plugins/devices-virtual/services/virtual-light-group.utils.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-measurement-authoring.service.d.ts +37 -0
- package/dist/plugins/devices-virtual/services/virtual-measurement-authoring.service.js +270 -0
- package/dist/plugins/devices-virtual/services/virtual-measurement-authoring.service.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-measurement-contribution.service.d.ts +21 -0
- package/dist/plugins/devices-virtual/services/virtual-measurement-contribution.service.js +166 -0
- package/dist/plugins/devices-virtual/services/virtual-measurement-contribution.service.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-measurement-metadata.utils.d.ts +3 -0
- package/dist/plugins/devices-virtual/services/virtual-measurement-metadata.utils.js +25 -0
- package/dist/plugins/devices-virtual/services/virtual-measurement-metadata.utils.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-numeric-operator-host.service.d.ts +24 -0
- package/dist/plugins/devices-virtual/services/virtual-numeric-operator-host.service.js +145 -0
- package/dist/plugins/devices-virtual/services/virtual-numeric-operator-host.service.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-numeric-operator.registry.d.ts +18 -0
- package/dist/plugins/devices-virtual/services/virtual-numeric-operator.registry.js +86 -0
- package/dist/plugins/devices-virtual/services/virtual-numeric-operator.registry.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-numeric-profile.utils.d.ts +29 -0
- package/dist/plugins/devices-virtual/services/virtual-numeric-profile.utils.js +136 -0
- package/dist/plugins/devices-virtual/services/virtual-numeric-profile.utils.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-numeric-transform.utils.d.ts +59 -0
- package/dist/plugins/devices-virtual/services/virtual-numeric-transform.utils.js +165 -0
- package/dist/plugins/devices-virtual/services/virtual-numeric-transform.utils.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-producer-config.service.d.ts +64 -0
- package/dist/plugins/devices-virtual/services/virtual-producer-config.service.js +694 -0
- package/dist/plugins/devices-virtual/services/virtual-producer-config.service.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-producer-state.service.d.ts +60 -0
- package/dist/plugins/devices-virtual/services/virtual-producer-state.service.js +484 -0
- package/dist/plugins/devices-virtual/services/virtual-producer-state.service.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-property-index.service.d.ts +11 -2
- package/dist/plugins/devices-virtual/services/virtual-property-index.service.js +166 -13
- package/dist/plugins/devices-virtual/services/virtual-property-index.service.js.map +1 -1
- package/dist/plugins/devices-virtual/services/virtual-source-eligibility.utils.d.ts +3 -0
- package/dist/plugins/devices-virtual/services/virtual-source-eligibility.utils.js +10 -0
- package/dist/plugins/devices-virtual/services/virtual-source-eligibility.utils.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-thermostat-authoring.service.d.ts +27 -0
- package/dist/plugins/devices-virtual/services/virtual-thermostat-authoring.service.js +385 -0
- package/dist/plugins/devices-virtual/services/virtual-thermostat-authoring.service.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-thermostat-automation.service.d.ts +90 -0
- package/dist/plugins/devices-virtual/services/virtual-thermostat-automation.service.js +1189 -0
- package/dist/plugins/devices-virtual/services/virtual-thermostat-automation.service.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-thermostat-branch.utils.d.ts +5 -0
- package/dist/plugins/devices-virtual/services/virtual-thermostat-branch.utils.js +29 -0
- package/dist/plugins/devices-virtual/services/virtual-thermostat-branch.utils.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-thermostat-claims.service.d.ts +80 -0
- package/dist/plugins/devices-virtual/services/virtual-thermostat-claims.service.js +489 -0
- package/dist/plugins/devices-virtual/services/virtual-thermostat-claims.service.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-thermostat-comfort.service.d.ts +80 -0
- package/dist/plugins/devices-virtual/services/virtual-thermostat-comfort.service.js +580 -0
- package/dist/plugins/devices-virtual/services/virtual-thermostat-comfort.service.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-thermostat-comfort.utils.d.ts +58 -0
- package/dist/plugins/devices-virtual/services/virtual-thermostat-comfort.utils.js +106 -0
- package/dist/plugins/devices-virtual/services/virtual-thermostat-comfort.utils.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-thermostat-config.service.d.ts +909 -0
- package/dist/plugins/devices-virtual/services/virtual-thermostat-config.service.js +1171 -0
- package/dist/plugins/devices-virtual/services/virtual-thermostat-config.service.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-thermostat-contract.utils.d.ts +5 -0
- package/dist/plugins/devices-virtual/services/virtual-thermostat-contract.utils.js +51 -0
- package/dist/plugins/devices-virtual/services/virtual-thermostat-contract.utils.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-thermostat-inputs.service.d.ts +46 -0
- package/dist/plugins/devices-virtual/services/virtual-thermostat-inputs.service.js +166 -0
- package/dist/plugins/devices-virtual/services/virtual-thermostat-inputs.service.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-thermostat-ownership.sql.d.ts +4 -0
- package/dist/plugins/devices-virtual/services/virtual-thermostat-ownership.sql.js +59 -0
- package/dist/plugins/devices-virtual/services/virtual-thermostat-ownership.sql.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-thermostat-policy.utils.d.ts +45 -0
- package/dist/plugins/devices-virtual/services/virtual-thermostat-policy.utils.js +149 -0
- package/dist/plugins/devices-virtual/services/virtual-thermostat-policy.utils.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-thermostat-runtime-ownership.d.ts +56 -0
- package/dist/plugins/devices-virtual/services/virtual-thermostat-runtime-ownership.js +680 -0
- package/dist/plugins/devices-virtual/services/virtual-thermostat-runtime-ownership.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-thermostat-runtime.service.d.ts +133 -0
- package/dist/plugins/devices-virtual/services/virtual-thermostat-runtime.service.js +1617 -0
- package/dist/plugins/devices-virtual/services/virtual-thermostat-runtime.service.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-thermostat-transport.service.d.ts +39 -0
- package/dist/plugins/devices-virtual/services/virtual-thermostat-transport.service.js +561 -0
- package/dist/plugins/devices-virtual/services/virtual-thermostat-transport.service.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-transform-config.service.d.ts +41 -0
- package/dist/plugins/devices-virtual/services/virtual-transform-config.service.js +209 -0
- package/dist/plugins/devices-virtual/services/virtual-transform-config.service.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-transform-contract.utils.d.ts +8 -0
- package/dist/plugins/devices-virtual/services/virtual-transform-contract.utils.js +103 -0
- package/dist/plugins/devices-virtual/services/virtual-transform-contract.utils.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-transform-preview.utils.d.ts +3 -0
- package/dist/plugins/devices-virtual/services/virtual-transform-preview.utils.js +18 -0
- package/dist/plugins/devices-virtual/services/virtual-transform-preview.utils.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-transform-resolver.d.ts +15 -0
- package/dist/plugins/devices-virtual/services/virtual-transform-resolver.js +102 -0
- package/dist/plugins/devices-virtual/services/virtual-transform-resolver.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-transform-runtime.service.d.ts +54 -0
- package/dist/plugins/devices-virtual/services/virtual-transform-runtime.service.js +470 -0
- package/dist/plugins/devices-virtual/services/virtual-transform-runtime.service.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-typed-group.utils.d.ts +6 -0
- package/dist/plugins/devices-virtual/services/virtual-typed-group.utils.js +100 -0
- package/dist/plugins/devices-virtual/services/virtual-typed-group.utils.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-value-source.service.d.ts +7 -0
- package/dist/plugins/devices-virtual/services/virtual-value-source.service.js +36 -2
- package/dist/plugins/devices-virtual/services/virtual-value-source.service.js.map +1 -1
- package/dist/plugins/devices-virtual/services/virtual-window-contact.utils.d.ts +17 -0
- package/dist/plugins/devices-virtual/services/virtual-window-contact.utils.js +52 -0
- package/dist/plugins/devices-virtual/services/virtual-window-contact.utils.js.map +1 -0
- package/dist/plugins/devices-virtual/services/virtual-window-trend.utils.d.ts +44 -0
- package/dist/plugins/devices-virtual/services/virtual-window-trend.utils.js +171 -0
- package/dist/plugins/devices-virtual/services/virtual-window-trend.utils.js.map +1 -0
- package/dist/plugins/devices-virtual/subscribers/virtual-thermostat-ownership.subscriber.d.ts +30 -0
- package/dist/plugins/devices-virtual/subscribers/virtual-thermostat-ownership.subscriber.js +195 -0
- package/dist/plugins/devices-virtual/subscribers/virtual-thermostat-ownership.subscriber.js.map +1 -0
- package/dist/plugins/devices-virtual/subscribers/virtual-transform-metadata.subscriber.d.ts +9 -0
- package/dist/plugins/devices-virtual/subscribers/virtual-transform-metadata.subscriber.js +58 -0
- package/dist/plugins/devices-virtual/subscribers/virtual-transform-metadata.subscriber.js.map +1 -0
- package/dist/plugins/devices-virtual/validators/category-allowed-constraint.validator.d.ts +1 -1
- package/dist/plugins/devices-virtual/validators/category-allowed-constraint.validator.js +6 -1
- package/dist/plugins/devices-virtual/validators/category-allowed-constraint.validator.js.map +1 -1
- package/dist/plugins/devices-wled/interfaces/wled.interface.d.ts +7 -0
- package/dist/plugins/devices-wled/interfaces/wled.interface.js.map +1 -1
- package/dist/plugins/devices-wled/platforms/wled.device.platform.d.ts +4 -2
- package/dist/plugins/devices-wled/platforms/wled.device.platform.js +56 -9
- package/dist/plugins/devices-wled/platforms/wled.device.platform.js.map +1 -1
- package/dist/plugins/devices-wled/services/device-mapper.service.d.ts +3 -2
- package/dist/plugins/devices-wled/services/device-mapper.service.js +48 -1
- package/dist/plugins/devices-wled/services/device-mapper.service.js.map +1 -1
- package/dist/plugins/devices-wled/services/wled-client-adapter.service.d.ts +6 -1
- package/dist/plugins/devices-wled/services/wled-client-adapter.service.js +101 -13
- package/dist/plugins/devices-wled/services/wled-client-adapter.service.js.map +1 -1
- package/dist/plugins/devices-wled/services/wled.service.js +5 -2
- package/dist/plugins/devices-wled/services/wled.service.js.map +1 -1
- package/dist/plugins/devices-zigbee2mqtt/contracts/sample-source.contract.d.ts +38 -0
- package/dist/plugins/devices-zigbee2mqtt/contracts/sample-source.contract.js +95 -0
- package/dist/plugins/devices-zigbee2mqtt/contracts/sample-source.contract.js.map +1 -0
- package/dist/plugins/devices-zigbee2mqtt/devices-zigbee2mqtt.plugin.js +11 -1
- package/dist/plugins/devices-zigbee2mqtt/devices-zigbee2mqtt.plugin.js.map +1 -1
- package/dist/plugins/devices-zigbee2mqtt/entities/zigbee-sample-source.entity.d.ts +18 -0
- package/dist/plugins/devices-zigbee2mqtt/entities/zigbee-sample-source.entity.js +79 -0
- package/dist/plugins/devices-zigbee2mqtt/entities/zigbee-sample-source.entity.js.map +1 -0
- package/dist/plugins/devices-zigbee2mqtt/interfaces/zigbee2mqtt.interface.d.ts +11 -0
- package/dist/plugins/devices-zigbee2mqtt/platforms/zigbee2mqtt.device.platform.d.ts +11 -2
- package/dist/plugins/devices-zigbee2mqtt/platforms/zigbee2mqtt.device.platform.js +100 -11
- package/dist/plugins/devices-zigbee2mqtt/platforms/zigbee2mqtt.device.platform.js.map +1 -1
- package/dist/plugins/devices-zigbee2mqtt/services/base-client-adapter.d.ts +31 -13
- package/dist/plugins/devices-zigbee2mqtt/services/base-client-adapter.js +166 -5
- package/dist/plugins/devices-zigbee2mqtt/services/base-client-adapter.js.map +1 -1
- package/dist/plugins/devices-zigbee2mqtt/services/device-adoption.service.d.ts +1 -0
- package/dist/plugins/devices-zigbee2mqtt/services/device-adoption.service.js +44 -3
- package/dist/plugins/devices-zigbee2mqtt/services/device-adoption.service.js.map +1 -1
- package/dist/plugins/devices-zigbee2mqtt/services/device-mapper.service.d.ts +20 -3
- package/dist/plugins/devices-zigbee2mqtt/services/device-mapper.service.js +156 -34
- package/dist/plugins/devices-zigbee2mqtt/services/device-mapper.service.js.map +1 -1
- package/dist/plugins/devices-zigbee2mqtt/services/mqtt-client-adapter.service.d.ts +1 -1
- package/dist/plugins/devices-zigbee2mqtt/services/mqtt-client-adapter.service.js +14 -1
- package/dist/plugins/devices-zigbee2mqtt/services/mqtt-client-adapter.service.js.map +1 -1
- package/dist/plugins/devices-zigbee2mqtt/services/native-climate-adapter.service.d.ts +15 -0
- package/dist/plugins/devices-zigbee2mqtt/services/native-climate-adapter.service.js +249 -0
- package/dist/plugins/devices-zigbee2mqtt/services/native-climate-adapter.service.js.map +1 -0
- package/dist/plugins/devices-zigbee2mqtt/services/websocket-sample-evidence.d.ts +2 -0
- package/dist/plugins/devices-zigbee2mqtt/services/websocket-sample-evidence.js +15 -0
- package/dist/plugins/devices-zigbee2mqtt/services/websocket-sample-evidence.js.map +1 -0
- package/dist/plugins/devices-zigbee2mqtt/services/ws-client-adapter.service.d.ts +7 -1
- package/dist/plugins/devices-zigbee2mqtt/services/ws-client-adapter.service.js +45 -2
- package/dist/plugins/devices-zigbee2mqtt/services/ws-client-adapter.service.js.map +1 -1
- package/dist/plugins/devices-zigbee2mqtt/services/zigbee-sample-sources.service.d.ts +49 -0
- package/dist/plugins/devices-zigbee2mqtt/services/zigbee-sample-sources.service.js +264 -0
- package/dist/plugins/devices-zigbee2mqtt/services/zigbee-sample-sources.service.js.map +1 -0
- package/dist/plugins/devices-zigbee2mqtt/services/zigbee2mqtt.service.js +2 -0
- package/dist/plugins/devices-zigbee2mqtt/services/zigbee2mqtt.service.js.map +1 -1
- package/dist/plugins/scenes-local/platforms/local-scene.platform.d.ts +6 -3
- package/dist/plugins/scenes-local/platforms/local-scene.platform.js +101 -15
- package/dist/plugins/scenes-local/platforms/local-scene.platform.js.map +1 -1
- package/dist/plugins/spaces-home-control/activity/activity-actor.d.ts +2 -0
- package/dist/plugins/spaces-home-control/activity/activity-actor.js +14 -0
- package/dist/plugins/spaces-home-control/activity/activity-actor.js.map +1 -0
- package/dist/plugins/spaces-home-control/activity/activity-result.utils.d.ts +6 -0
- package/dist/plugins/spaces-home-control/activity/activity-result.utils.js +26 -0
- package/dist/plugins/spaces-home-control/activity/activity-result.utils.js.map +1 -0
- package/dist/plugins/spaces-home-control/activity/space-activity.constants.d.ts +32 -0
- package/dist/plugins/spaces-home-control/activity/space-activity.constants.js +40 -0
- package/dist/plugins/spaces-home-control/activity/space-activity.constants.js.map +1 -0
- package/dist/plugins/spaces-home-control/activity/space-activity.defaults.d.ts +3 -0
- package/dist/plugins/spaces-home-control/activity/space-activity.defaults.js +25 -0
- package/dist/plugins/spaces-home-control/activity/space-activity.defaults.js.map +1 -0
- package/dist/plugins/spaces-home-control/activity/validate-activity-configuration.d.ts +2 -0
- package/dist/plugins/spaces-home-control/activity/validate-activity-configuration.js +37 -0
- package/dist/plugins/spaces-home-control/activity/validate-activity-configuration.js.map +1 -0
- package/dist/plugins/spaces-home-control/controllers/space-mode-schedules.controller.d.ts +12 -0
- package/dist/plugins/spaces-home-control/controllers/space-mode-schedules.controller.js +97 -0
- package/dist/plugins/spaces-home-control/controllers/space-mode-schedules.controller.js.map +1 -0
- package/dist/plugins/spaces-home-control/controllers/space-modes.controller.d.ts +19 -0
- package/dist/plugins/spaces-home-control/controllers/space-modes.controller.js +220 -0
- package/dist/plugins/spaces-home-control/controllers/space-modes.controller.js.map +1 -0
- package/dist/plugins/spaces-home-control/controllers/space-occupancy.controller.d.ts +18 -0
- package/dist/plugins/spaces-home-control/controllers/space-occupancy.controller.js +147 -0
- package/dist/plugins/spaces-home-control/controllers/space-occupancy.controller.js.map +1 -0
- package/dist/plugins/spaces-home-control/controllers/spaces-domain.controller.js +4 -0
- package/dist/plugins/spaces-home-control/controllers/spaces-domain.controller.js.map +1 -1
- package/dist/plugins/spaces-home-control/dto/activity-mode.dto.d.ts +22 -0
- package/dist/plugins/spaces-home-control/dto/activity-mode.dto.js +119 -0
- package/dist/plugins/spaces-home-control/dto/activity-mode.dto.js.map +1 -0
- package/dist/plugins/spaces-home-control/dto/space-mode-schedule.dto.d.ts +18 -0
- package/dist/plugins/spaces-home-control/dto/space-mode-schedule.dto.js +127 -0
- package/dist/plugins/spaces-home-control/dto/space-mode-schedule.dto.js.map +1 -0
- package/dist/plugins/spaces-home-control/dto/space-occupancy.dto.d.ts +13 -0
- package/dist/plugins/spaces-home-control/dto/space-occupancy.dto.js +99 -0
- package/dist/plugins/spaces-home-control/dto/space-occupancy.dto.js.map +1 -0
- package/dist/plugins/spaces-home-control/entities/space-activity-config.entity.d.ts +12 -0
- package/dist/plugins/spaces-home-control/entities/space-activity-config.entity.js +72 -0
- package/dist/plugins/spaces-home-control/entities/space-activity-config.entity.js.map +1 -0
- package/dist/plugins/spaces-home-control/entities/space-activity-state.entity.d.ts +14 -0
- package/dist/plugins/spaces-home-control/entities/space-activity-state.entity.js +105 -0
- package/dist/plugins/spaces-home-control/entities/space-activity-state.entity.js.map +1 -0
- package/dist/plugins/spaces-home-control/entities/space-mode-schedule.entity.d.ts +19 -0
- package/dist/plugins/spaces-home-control/entities/space-mode-schedule.entity.js +110 -0
- package/dist/plugins/spaces-home-control/entities/space-mode-schedule.entity.js.map +1 -0
- package/dist/plugins/spaces-home-control/entities/space-occupancy.entity.d.ts +23 -0
- package/dist/plugins/spaces-home-control/entities/space-occupancy.entity.js +135 -0
- package/dist/plugins/spaces-home-control/entities/space-occupancy.entity.js.map +1 -0
- package/dist/plugins/spaces-home-control/listeners/space-climate-state.listener.d.ts +2 -0
- package/dist/plugins/spaces-home-control/listeners/space-climate-state.listener.js +23 -0
- package/dist/plugins/spaces-home-control/listeners/space-climate-state.listener.js.map +1 -1
- package/dist/plugins/spaces-home-control/listeners/websocket-exchange.listener.js +3 -0
- package/dist/plugins/spaces-home-control/listeners/websocket-exchange.listener.js.map +1 -1
- package/dist/plugins/spaces-home-control/models/activity-configuration.model.d.ts +27 -0
- package/dist/plugins/spaces-home-control/models/activity-configuration.model.js +182 -0
- package/dist/plugins/spaces-home-control/models/activity-configuration.model.js.map +1 -0
- package/dist/plugins/spaces-home-control/models/activity-response.model.d.ts +16 -0
- package/dist/plugins/spaces-home-control/models/activity-response.model.js +79 -0
- package/dist/plugins/spaces-home-control/models/activity-response.model.js.map +1 -0
- package/dist/plugins/spaces-home-control/models/activity-result.model.d.ts +6 -0
- package/dist/plugins/spaces-home-control/models/activity-result.model.js +37 -0
- package/dist/plugins/spaces-home-control/models/activity-result.model.js.map +1 -0
- package/dist/plugins/spaces-home-control/models/climate-contribution.model.d.ts +11 -0
- package/dist/plugins/spaces-home-control/models/climate-contribution.model.js +66 -0
- package/dist/plugins/spaces-home-control/models/climate-contribution.model.js.map +1 -0
- package/dist/plugins/spaces-home-control/models/space-mode-schedule-response.model.d.ts +9 -0
- package/dist/plugins/spaces-home-control/models/space-mode-schedule-response.model.js +45 -0
- package/dist/plugins/spaces-home-control/models/space-mode-schedule-response.model.js.map +1 -0
- package/dist/plugins/spaces-home-control/models/space-mode-schedule.model.d.ts +34 -0
- package/dist/plugins/spaces-home-control/models/space-mode-schedule.model.js +170 -0
- package/dist/plugins/spaces-home-control/models/space-mode-schedule.model.js.map +1 -0
- package/dist/plugins/spaces-home-control/models/space-occupancy.model.d.ts +26 -0
- package/dist/plugins/spaces-home-control/models/space-occupancy.model.js +121 -0
- package/dist/plugins/spaces-home-control/models/space-occupancy.model.js.map +1 -0
- package/dist/plugins/spaces-home-control/models/spaces-response.model.d.ts +13 -0
- package/dist/plugins/spaces-home-control/models/spaces-response.model.js +81 -2
- package/dist/plugins/spaces-home-control/models/spaces-response.model.js.map +1 -1
- package/dist/plugins/spaces-home-control/occupancy/occupancy-admission.d.ts +7 -0
- package/dist/plugins/spaces-home-control/occupancy/occupancy-admission.js +57 -0
- package/dist/plugins/spaces-home-control/occupancy/occupancy-admission.js.map +1 -0
- package/dist/plugins/spaces-home-control/occupancy/space-occupancy.types.d.ts +31 -0
- package/dist/plugins/spaces-home-control/occupancy/space-occupancy.types.js +30 -0
- package/dist/plugins/spaces-home-control/occupancy/space-occupancy.types.js.map +1 -0
- package/dist/plugins/spaces-home-control/schedule/schedule-time.d.ts +9 -0
- package/dist/plugins/spaces-home-control/schedule/schedule-time.js +79 -0
- package/dist/plugins/spaces-home-control/schedule/schedule-time.js.map +1 -0
- package/dist/plugins/spaces-home-control/schedule/space-mode-schedule.types.d.ts +28 -0
- package/dist/plugins/spaces-home-control/schedule/space-mode-schedule.types.js +7 -0
- package/dist/plugins/spaces-home-control/schedule/space-mode-schedule.types.js.map +1 -0
- package/dist/plugins/spaces-home-control/services/activity-test-support.d.ts +16 -0
- package/dist/plugins/spaces-home-control/services/activity-test-support.js +34 -0
- package/dist/plugins/spaces-home-control/services/activity-test-support.js.map +1 -0
- package/dist/plugins/spaces-home-control/services/climate-contribution-planner.service.d.ts +15 -0
- package/dist/plugins/spaces-home-control/services/climate-contribution-planner.service.js +97 -0
- package/dist/plugins/spaces-home-control/services/climate-contribution-planner.service.js.map +1 -0
- package/dist/plugins/spaces-home-control/services/climate-intent.service.d.ts +15 -2
- package/dist/plugins/spaces-home-control/services/climate-intent.service.js +155 -15
- package/dist/plugins/spaces-home-control/services/climate-intent.service.js.map +1 -1
- package/dist/plugins/spaces-home-control/services/cover-group-intent.port.d.ts +31 -0
- package/dist/plugins/spaces-home-control/services/cover-group-intent.port.js +189 -0
- package/dist/plugins/spaces-home-control/services/cover-group-intent.port.js.map +1 -0
- package/dist/plugins/spaces-home-control/services/covers-intent.service.d.ts +8 -3
- package/dist/plugins/spaces-home-control/services/covers-intent.service.js +139 -65
- package/dist/plugins/spaces-home-control/services/covers-intent.service.js.map +1 -1
- package/dist/plugins/spaces-home-control/services/lighting-contribution-planner.service.d.ts +16 -0
- package/dist/plugins/spaces-home-control/services/lighting-contribution-planner.service.js +66 -0
- package/dist/plugins/spaces-home-control/services/lighting-contribution-planner.service.js.map +1 -0
- package/dist/plugins/spaces-home-control/services/lighting-intent.service.d.ts +13 -3
- package/dist/plugins/spaces-home-control/services/lighting-intent.service.js +93 -13
- package/dist/plugins/spaces-home-control/services/lighting-intent.service.js.map +1 -1
- package/dist/plugins/spaces-home-control/services/space-activity-config.service.d.ts +25 -0
- package/dist/plugins/spaces-home-control/services/space-activity-config.service.js +144 -0
- package/dist/plugins/spaces-home-control/services/space-activity-config.service.js.map +1 -0
- package/dist/plugins/spaces-home-control/services/space-activity-domains.service.d.ts +21 -0
- package/dist/plugins/spaces-home-control/services/space-activity-domains.service.js +139 -0
- package/dist/plugins/spaces-home-control/services/space-activity-domains.service.js.map +1 -0
- package/dist/plugins/spaces-home-control/services/space-climate-automation.port.d.ts +17 -0
- package/dist/plugins/spaces-home-control/services/space-climate-automation.port.js +5 -0
- package/dist/plugins/spaces-home-control/services/space-climate-automation.port.js.map +1 -0
- package/dist/plugins/spaces-home-control/services/space-climate-automation.service.d.ts +63 -0
- package/dist/plugins/spaces-home-control/services/space-climate-automation.service.js +722 -0
- package/dist/plugins/spaces-home-control/services/space-climate-automation.service.js.map +1 -0
- package/dist/plugins/spaces-home-control/services/space-climate-state.service.d.ts +8 -3
- package/dist/plugins/spaces-home-control/services/space-climate-state.service.js +25 -19
- package/dist/plugins/spaces-home-control/services/space-climate-state.service.js.map +1 -1
- package/dist/plugins/spaces-home-control/services/space-covers-state.service.d.ts +16 -2
- package/dist/plugins/spaces-home-control/services/space-covers-state.service.js +102 -18
- package/dist/plugins/spaces-home-control/services/space-covers-state.service.js.map +1 -1
- package/dist/plugins/spaces-home-control/services/space-intent-base.service.d.ts +2 -0
- package/dist/plugins/spaces-home-control/services/space-intent-base.service.js.map +1 -1
- package/dist/plugins/spaces-home-control/services/space-lighting-state.service.d.ts +4 -1
- package/dist/plugins/spaces-home-control/services/space-lighting-state.service.js +94 -24
- package/dist/plugins/spaces-home-control/services/space-lighting-state.service.js.map +1 -1
- package/dist/plugins/spaces-home-control/services/space-media-activity.service.d.ts +8 -2
- package/dist/plugins/spaces-home-control/services/space-media-activity.service.js +79 -13
- package/dist/plugins/spaces-home-control/services/space-media-activity.service.js.map +1 -1
- package/dist/plugins/spaces-home-control/services/space-mode-schedule-config.service.d.ts +24 -0
- package/dist/plugins/spaces-home-control/services/space-mode-schedule-config.service.js +132 -0
- package/dist/plugins/spaces-home-control/services/space-mode-schedule-config.service.js.map +1 -0
- package/dist/plugins/spaces-home-control/services/space-mode-scheduler.service.d.ts +39 -0
- package/dist/plugins/spaces-home-control/services/space-mode-scheduler.service.js +289 -0
- package/dist/plugins/spaces-home-control/services/space-mode-scheduler.service.js.map +1 -0
- package/dist/plugins/spaces-home-control/services/space-mode.service.d.ts +34 -0
- package/dist/plugins/spaces-home-control/services/space-mode.service.js +296 -0
- package/dist/plugins/spaces-home-control/services/space-mode.service.js.map +1 -0
- package/dist/plugins/spaces-home-control/services/space-occupancy-config.service.d.ts +26 -0
- package/dist/plugins/spaces-home-control/services/space-occupancy-config.service.js +134 -0
- package/dist/plugins/spaces-home-control/services/space-occupancy-config.service.js.map +1 -0
- package/dist/plugins/spaces-home-control/services/space-occupancy-inputs.service.d.ts +21 -0
- package/dist/plugins/spaces-home-control/services/space-occupancy-inputs.service.js +84 -0
- package/dist/plugins/spaces-home-control/services/space-occupancy-inputs.service.js.map +1 -0
- package/dist/plugins/spaces-home-control/services/space-occupancy.service.d.ts +48 -0
- package/dist/plugins/spaces-home-control/services/space-occupancy.service.js +285 -0
- package/dist/plugins/spaces-home-control/services/space-occupancy.service.js.map +1 -0
- package/dist/plugins/spaces-home-control/services/space-state-read.service.d.ts +5 -1
- package/dist/plugins/spaces-home-control/services/space-state-read.service.js +33 -7
- package/dist/plugins/spaces-home-control/services/space-state-read.service.js.map +1 -1
- package/dist/plugins/spaces-home-control/spaces-home-control.openapi.js +52 -0
- package/dist/plugins/spaces-home-control/spaces-home-control.openapi.js.map +1 -1
- package/dist/plugins/spaces-home-control/spaces-home-control.plugin.d.ts +5 -1
- package/dist/plugins/spaces-home-control/spaces-home-control.plugin.js +57 -2
- package/dist/plugins/spaces-home-control/spaces-home-control.plugin.js.map +1 -1
- package/dist/spec/channels.d.ts +27 -4
- package/dist/spec/channels.js +37 -6
- package/dist/spec/channels.js.map +1 -1
- package/dist/spec/devices.d.ts +20 -0
- package/dist/spec/devices.js +20 -0
- package/dist/spec/devices.js.map +1 -1
- package/dist/tsconfig.build.tsbuildinfo +1 -1
- package/package.json +4 -3
|
@@ -24,6 +24,10 @@ const channels_service_1 = require("../../../modules/devices/services/channels.s
|
|
|
24
24
|
const command_latency_trace_collector_service_1 = require("../../../modules/devices/services/command-latency-trace-collector.service");
|
|
25
25
|
const device_connectivity_service_1 = require("../../../modules/devices/services/device-connectivity.service");
|
|
26
26
|
const devices_service_1 = require("../../../modules/devices/services/devices.service");
|
|
27
|
+
const property_value_service_1 = require("../../../modules/devices/services/property-value.service");
|
|
28
|
+
const property_metadata_utils_1 = require("../../../modules/devices/utils/property-metadata.utils");
|
|
29
|
+
const cover_action_contract_1 = require("../contracts/cover-action.contract");
|
|
30
|
+
const native_temperature_contract_1 = require("../contracts/native-temperature.contract");
|
|
27
31
|
const devices_shelly_ng_constants_1 = require("../devices-shelly-ng.constants");
|
|
28
32
|
const devices_shelly_ng_exceptions_1 = require("../devices-shelly-ng.exceptions");
|
|
29
33
|
const update_channel_property_dto_1 = require("../dto/update-channel-property.dto");
|
|
@@ -32,6 +36,9 @@ const transformers_1 = require("../mappings/transformers/transformers");
|
|
|
32
36
|
const device_address_service_1 = require("../services/device-address.service");
|
|
33
37
|
const device_manager_service_1 = require("../services/device-manager.service");
|
|
34
38
|
const poll_placement_diagnostics_service_1 = require("../services/poll-placement-diagnostics.service");
|
|
39
|
+
const shelly_cover_ordering_service_1 = require("../services/shelly-cover-ordering.service");
|
|
40
|
+
const shelly_cover_recovery_lane_service_1 = require("../services/shelly-cover-recovery-lane.service");
|
|
41
|
+
const shelly_sample_sources_service_1 = require("../services/shelly-sample-sources.service");
|
|
35
42
|
const transform_utils_2 = require("../utils/transform.utils");
|
|
36
43
|
const shelly_device_delegate_1 = require("./shelly-device.delegate");
|
|
37
44
|
const SHELLY_TO_PANEL_EVENT_MAP = {
|
|
@@ -44,7 +51,40 @@ const SHELLY_TO_PANEL_EVENT_MAP = {
|
|
|
44
51
|
btn_up: 'up',
|
|
45
52
|
};
|
|
46
53
|
let DelegatesManagerService = DelegatesManagerService_1 = class DelegatesManagerService {
|
|
47
|
-
|
|
54
|
+
beginGuardedSessionAdmission(runtime) {
|
|
55
|
+
this.revokeGuardedSessionAdmission();
|
|
56
|
+
const admission = { runtime, open: false, revoked: false };
|
|
57
|
+
this.guardedSessionAdmission = admission;
|
|
58
|
+
return Object.freeze({
|
|
59
|
+
open: () => {
|
|
60
|
+
if (this.guardedSessionAdmission !== admission || admission.revoked || !runtime?.isCurrent())
|
|
61
|
+
return false;
|
|
62
|
+
admission.open = true;
|
|
63
|
+
return true;
|
|
64
|
+
},
|
|
65
|
+
revoke: () => {
|
|
66
|
+
admission.revoked = true;
|
|
67
|
+
admission.open = false;
|
|
68
|
+
},
|
|
69
|
+
});
|
|
70
|
+
}
|
|
71
|
+
revokeGuardedSessionAdmission() {
|
|
72
|
+
const admission = this.guardedSessionAdmission;
|
|
73
|
+
if (admission) {
|
|
74
|
+
admission.revoked = true;
|
|
75
|
+
admission.open = false;
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
captureGuardedSessionAdmission() {
|
|
79
|
+
const admission = this.guardedSessionAdmission;
|
|
80
|
+
const isCurrent = () => this.guardedSessionAdmission === admission &&
|
|
81
|
+
admission !== null &&
|
|
82
|
+
admission.open &&
|
|
83
|
+
!admission.revoked &&
|
|
84
|
+
admission.runtime?.isCurrent() === true;
|
|
85
|
+
return isCurrent() ? Object.freeze({ isCurrent }) : null;
|
|
86
|
+
}
|
|
87
|
+
constructor(devicesService, channelsService, channelsPropertiesService, deviceConnectivityService, deviceManagerService, deviceAddressService, propertyMappingStorage, transformerRegistry, commandLatencyTraceCollector = new command_latency_trace_collector_service_1.CommandLatencyTraceCollectorService(), pollPlacementDiagnostics = new poll_placement_diagnostics_service_1.PollPlacementDiagnosticsService(), channelInputOccurrencesService, sampleSourcesRegistry, coverValues, coverOrdering, coverRecoveryLane) {
|
|
48
88
|
this.devicesService = devicesService;
|
|
49
89
|
this.channelsService = channelsService;
|
|
50
90
|
this.channelsPropertiesService = channelsPropertiesService;
|
|
@@ -56,8 +96,17 @@ let DelegatesManagerService = DelegatesManagerService_1 = class DelegatesManager
|
|
|
56
96
|
this.commandLatencyTraceCollector = commandLatencyTraceCollector;
|
|
57
97
|
this.pollPlacementDiagnostics = pollPlacementDiagnostics;
|
|
58
98
|
this.channelInputOccurrencesService = channelInputOccurrencesService;
|
|
99
|
+
this.sampleSourcesRegistry = sampleSourcesRegistry;
|
|
100
|
+
this.coverValues = coverValues;
|
|
101
|
+
this.coverOrdering = coverOrdering;
|
|
102
|
+
this.coverRecoveryLane = coverRecoveryLane;
|
|
59
103
|
this.logger = (0, logger_1.createExtensionLogger)(devices_shelly_ng_constants_1.DEVICES_SHELLY_NG_PLUGIN_NAME, 'DelegatesManagerService');
|
|
60
104
|
this.delegates = new Map();
|
|
105
|
+
this.sampleHandlers = new Map();
|
|
106
|
+
this.sampleSources = new Map();
|
|
107
|
+
this.sampleRevisions = new Map();
|
|
108
|
+
this.sampleGenerations = new Map();
|
|
109
|
+
this.activeSamples = new Map();
|
|
61
110
|
this.delegateValueHandlers = new Map();
|
|
62
111
|
this.delegateConnectionHandlers = new Map();
|
|
63
112
|
this.delegateEventHandlers = new Map();
|
|
@@ -85,6 +134,8 @@ let DelegatesManagerService = DelegatesManagerService_1 = class DelegatesManager
|
|
|
85
134
|
this.canonicalMacLocks = new Map();
|
|
86
135
|
this.connectedDelegatesPerDevice = new Map();
|
|
87
136
|
this.disconnectTimers = new Map();
|
|
137
|
+
this.guardedSessionAdmission = null;
|
|
138
|
+
this.coverIssues = new Map();
|
|
88
139
|
}
|
|
89
140
|
get(id) {
|
|
90
141
|
return this.delegates.get(id);
|
|
@@ -908,9 +959,14 @@ let DelegatesManagerService = DelegatesManagerService_1 = class DelegatesManager
|
|
|
908
959
|
}
|
|
909
960
|
}
|
|
910
961
|
}
|
|
962
|
+
if (this.insertGeneration.get(shelly.id) !== generation)
|
|
963
|
+
return delegate;
|
|
964
|
+
await this.bindSampleSources(delegate, device);
|
|
911
965
|
if (this.insertGeneration.get(shelly.id) !== generation)
|
|
912
966
|
return delegate;
|
|
913
967
|
const valueHandler = (compKey, attr, val, origin = 'notify') => {
|
|
968
|
+
if ((this.sampleSources.get(delegate.id) ?? []).some((source) => source.componentKey === compKey && source.attribute === attr))
|
|
969
|
+
return;
|
|
914
970
|
const handler = this.changeHandlers.get(`${delegate.id}|${compKey}|${attr}`);
|
|
915
971
|
if (!handler) {
|
|
916
972
|
return;
|
|
@@ -934,11 +990,29 @@ let DelegatesManagerService = DelegatesManagerService_1 = class DelegatesManager
|
|
|
934
990
|
delegate.on('value', valueHandler);
|
|
935
991
|
this.delegateValueHandlers.set(delegate.id, valueHandler);
|
|
936
992
|
const connectionHandler = (state) => {
|
|
993
|
+
if (state !== true) {
|
|
994
|
+
this.sampleGenerations.set(delegate.id, (this.sampleGenerations.get(delegate.id) ?? 0) + 1);
|
|
995
|
+
for (const source of this.sampleSources.get(delegate.id) ?? []) {
|
|
996
|
+
this.sampleSourcesRegistry?.revoke(source.property.id);
|
|
997
|
+
void this.admitRawSample(source.property, null, {
|
|
998
|
+
componentKey: source.componentKey,
|
|
999
|
+
values: {},
|
|
1000
|
+
evidence: { sampledAt: new Date(), receivedAt: new Date(), observedAt: new Date(), provenance: 'live' },
|
|
1001
|
+
}).catch((error) => this.logger.error(`Failed to invalidate Shelly sample for property=${source.property.id}: ${error.message}`));
|
|
1002
|
+
}
|
|
1003
|
+
}
|
|
937
1004
|
const deviceDbId = this.delegateDeviceIds.get(delegate.id) ?? device.id;
|
|
938
1005
|
const wasConnected = this.delegateConnectedState.get(delegate.id) ?? false;
|
|
939
1006
|
if (state === true) {
|
|
940
1007
|
if (wasConnected)
|
|
941
1008
|
return;
|
|
1009
|
+
for (const source of this.sampleSources.get(delegate.id) ?? []) {
|
|
1010
|
+
if ((0, native_temperature_contract_1.hasQualifiedFloorSourceIdentity)(source.channel.identifier) ||
|
|
1011
|
+
(0, native_temperature_contract_1.hasQualifiedRawVoltageIdentity)(source.channel.identifier))
|
|
1012
|
+
void this.sampleSourcesRegistry
|
|
1013
|
+
?.get(source.property.id)
|
|
1014
|
+
.catch((error) => this.logger.error(`Failed to activate Shelly sample source=${source.property.id}: ${error.message}`));
|
|
1015
|
+
}
|
|
942
1016
|
this.delegateConnectedState.set(delegate.id, true);
|
|
943
1017
|
this.pollPlacementDiagnostics.observeDelegate({
|
|
944
1018
|
delegateId: delegate.id,
|
|
@@ -1098,11 +1172,283 @@ let DelegatesManagerService = DelegatesManagerService_1 = class DelegatesManager
|
|
|
1098
1172
|
}
|
|
1099
1173
|
}
|
|
1100
1174
|
}
|
|
1175
|
+
async unbindSamples(delegate) {
|
|
1176
|
+
this.sampleGenerations.set(delegate.id, (this.sampleGenerations.get(delegate.id) ?? 0) + 1);
|
|
1177
|
+
const handler = this.sampleHandlers.get(delegate.id);
|
|
1178
|
+
if (handler)
|
|
1179
|
+
delegate.off('sample', handler);
|
|
1180
|
+
this.sampleHandlers.delete(delegate.id);
|
|
1181
|
+
delegate.setSampleComponentKeys([]);
|
|
1182
|
+
for (const source of this.sampleSources.get(delegate.id) ?? []) {
|
|
1183
|
+
const owner = this.delegateDeviceIds.get(delegate.id);
|
|
1184
|
+
if (owner)
|
|
1185
|
+
this.coverIssues.delete(`${owner}|${source.channel.id}`);
|
|
1186
|
+
this.sampleSourcesRegistry?.revoke(source.property.id);
|
|
1187
|
+
await this.admitRawSample(source.property, null, {
|
|
1188
|
+
componentKey: source.componentKey,
|
|
1189
|
+
values: {},
|
|
1190
|
+
evidence: { sampledAt: new Date(), receivedAt: new Date(), observedAt: new Date(), provenance: 'live' },
|
|
1191
|
+
}).catch((error) => this.logger.error(`Failed to invalidate Shelly sample for property=${source.property.id}: ${error.message}`));
|
|
1192
|
+
this.sampleRevisions.delete(`${delegate.id}|${source.property.id}`);
|
|
1193
|
+
}
|
|
1194
|
+
this.sampleSources.delete(delegate.id);
|
|
1195
|
+
await Promise.allSettled([...(this.activeSamples.get(delegate.id) ?? [])]);
|
|
1196
|
+
this.activeSamples.delete(delegate.id);
|
|
1197
|
+
}
|
|
1198
|
+
async bindSampleSources(delegate, device) {
|
|
1199
|
+
const sources = [];
|
|
1200
|
+
for (const channel of await this.channelsService.findAll(device.id, devices_shelly_ng_constants_1.DEVICES_SHELLY_NG_TYPE)) {
|
|
1201
|
+
let componentKey;
|
|
1202
|
+
let attribute;
|
|
1203
|
+
if (/^temperature:\d+$/.test(channel.identifier)) {
|
|
1204
|
+
componentKey = channel.identifier;
|
|
1205
|
+
attribute = 'tC';
|
|
1206
|
+
}
|
|
1207
|
+
else if ((0, native_temperature_contract_1.hasQualifiedFloorSourceIdentity)(channel.identifier) ||
|
|
1208
|
+
(0, native_temperature_contract_1.hasQualifiedRawVoltageIdentity)(channel.identifier)) {
|
|
1209
|
+
componentKey = channel.identifier.split(':').slice(1, 3).join(':');
|
|
1210
|
+
attribute = (0, native_temperature_contract_1.hasQualifiedRawVoltageIdentity)(channel.identifier)
|
|
1211
|
+
? 'voltage'
|
|
1212
|
+
: componentKey.startsWith('input:')
|
|
1213
|
+
? 'xpercent'
|
|
1214
|
+
: componentKey.startsWith('voltmeter:')
|
|
1215
|
+
? 'xvoltage'
|
|
1216
|
+
: 'tC';
|
|
1217
|
+
}
|
|
1218
|
+
else if (/^cover:\d+$/.test(channel.identifier)) {
|
|
1219
|
+
componentKey = channel.identifier;
|
|
1220
|
+
attribute = 'state';
|
|
1221
|
+
}
|
|
1222
|
+
else if (/^(switch|light):\d+$/.test(channel.identifier)) {
|
|
1223
|
+
componentKey = channel.identifier;
|
|
1224
|
+
attribute = 'output';
|
|
1225
|
+
}
|
|
1226
|
+
else
|
|
1227
|
+
continue;
|
|
1228
|
+
let property = await this.channelsPropertiesService.findOneBy('identifier', attribute, channel.id);
|
|
1229
|
+
if (!property && attribute === 'output')
|
|
1230
|
+
property = await this.channelsPropertiesService.findOneBy('category', devices_constants_1.PropertyCategory.ON, channel.id);
|
|
1231
|
+
if (property) {
|
|
1232
|
+
const sourceLease = (0, native_temperature_contract_1.hasQualifiedFloorSourceIdentity)(channel.identifier) || (0, native_temperature_contract_1.hasQualifiedRawVoltageIdentity)(channel.identifier)
|
|
1233
|
+
? await this.sampleSourcesRegistry?.get(property.id)
|
|
1234
|
+
: undefined;
|
|
1235
|
+
sources.push({ channel, property, componentKey, attribute, sourceLease: sourceLease ?? undefined });
|
|
1236
|
+
}
|
|
1237
|
+
if (/^cover:\d+$/.test(channel.identifier)) {
|
|
1238
|
+
const position = await this.channelsPropertiesService.findOneBy('identifier', 'current_pos', channel.id);
|
|
1239
|
+
if (position)
|
|
1240
|
+
sources.push({ channel, property: position, componentKey, attribute: 'current_pos' });
|
|
1241
|
+
const tilt = await this.channelsPropertiesService.findOneBy('identifier', 'slat_pos', channel.id);
|
|
1242
|
+
if (tilt)
|
|
1243
|
+
sources.push({ channel, property: tilt, componentKey, attribute: 'slat_pos' });
|
|
1244
|
+
}
|
|
1245
|
+
if (/^light:\d+$/.test(channel.identifier)) {
|
|
1246
|
+
const brightness = await this.channelsPropertiesService.findOneBy('identifier', 'brightness', channel.id);
|
|
1247
|
+
if (brightness)
|
|
1248
|
+
sources.push({ channel, property: brightness, componentKey, attribute: 'brightness' });
|
|
1249
|
+
}
|
|
1250
|
+
}
|
|
1251
|
+
this.sampleSources.set(delegate.id, sources);
|
|
1252
|
+
delegate.setSampleComponentKeys(sources.map((source) => source.componentKey));
|
|
1253
|
+
const handler = (sample) => {
|
|
1254
|
+
const generation = this.sampleGenerations.get(delegate.id) ?? 0;
|
|
1255
|
+
for (const source of sources.filter((item) => item.componentKey === sample.componentKey)) {
|
|
1256
|
+
const errors = sample.values.errors;
|
|
1257
|
+
const fault = Array.isArray(errors) &&
|
|
1258
|
+
errors.length > 0 &&
|
|
1259
|
+
(source.attribute !== 'output' || errors.includes('source_missing'));
|
|
1260
|
+
if (!Object.hasOwn(sample.values, source.attribute) && !fault && !/^cover:\d+$/.test(source.componentKey))
|
|
1261
|
+
continue;
|
|
1262
|
+
const key = `${delegate.id}|${source.property.id}`;
|
|
1263
|
+
const revision = (this.sampleRevisions.get(key) ?? 0) + 1;
|
|
1264
|
+
this.sampleRevisions.set(key, revision);
|
|
1265
|
+
const qualifiedIdentity = (0, native_temperature_contract_1.hasQualifiedFloorSourceIdentity)(source.channel.identifier) ||
|
|
1266
|
+
(0, native_temperature_contract_1.hasQualifiedRawVoltageIdentity)(source.channel.identifier);
|
|
1267
|
+
const sourceIsCurrent = () => (this.sampleGenerations.get(delegate.id) ?? 0) === generation &&
|
|
1268
|
+
(sample.evidence.sourceIsCurrent?.() ?? sample.evidence.isCurrent?.() ?? true);
|
|
1269
|
+
const isCurrent = () => sourceIsCurrent() && this.sampleRevisions.get(key) === revision;
|
|
1270
|
+
const raw = sample.values[source.attribute];
|
|
1271
|
+
const cover = /^cover:\d+$/.test(source.componentKey)
|
|
1272
|
+
? (0, cover_action_contract_1.nativeCoverStatus)(sample.values, Number(source.componentKey.split(':')[1]))
|
|
1273
|
+
: null;
|
|
1274
|
+
if (/^cover:\d+$/.test(source.componentKey)) {
|
|
1275
|
+
const key = `${device.id}|${source.channel.id}`;
|
|
1276
|
+
if (cover)
|
|
1277
|
+
this.coverIssues.delete(key);
|
|
1278
|
+
else
|
|
1279
|
+
this.coverIssues.set(key, (0, cover_action_contract_1.coverStatusReason)(sample.values));
|
|
1280
|
+
}
|
|
1281
|
+
const value = /^cover:\d+$/.test(source.componentKey)
|
|
1282
|
+
? cover
|
|
1283
|
+
? source.attribute === 'state'
|
|
1284
|
+
? cover.state === 'open'
|
|
1285
|
+
? 'opened'
|
|
1286
|
+
: cover.state
|
|
1287
|
+
: source.attribute === 'slat_pos'
|
|
1288
|
+
? (0, cover_action_contract_1.nativeCoverPercentage)(source.property) &&
|
|
1289
|
+
typeof cover.slat_pos === 'number' &&
|
|
1290
|
+
Number.isFinite(cover.slat_pos) &&
|
|
1291
|
+
cover.slat_pos >= 0 &&
|
|
1292
|
+
cover.slat_pos <= 100
|
|
1293
|
+
? cover.slat_pos
|
|
1294
|
+
: null
|
|
1295
|
+
: cover.current_pos
|
|
1296
|
+
: null
|
|
1297
|
+
: !fault &&
|
|
1298
|
+
((source.attribute === 'output' && typeof raw === 'boolean') ||
|
|
1299
|
+
(typeof raw === 'number' && Number.isFinite(raw)))
|
|
1300
|
+
? raw
|
|
1301
|
+
: null;
|
|
1302
|
+
let lease;
|
|
1303
|
+
let sourceProof = false;
|
|
1304
|
+
const admit = (reported, report = sample) => {
|
|
1305
|
+
const sourceGuard = () => sourceIsCurrent() &&
|
|
1306
|
+
(reported === null ||
|
|
1307
|
+
!qualifiedIdentity ||
|
|
1308
|
+
(sourceProof &&
|
|
1309
|
+
Boolean(lease && this.sampleSourcesRegistry?.isCurrent(lease, sample.evidence.observedAt))));
|
|
1310
|
+
return this.admitRawSample(source.property, reported, {
|
|
1311
|
+
...report,
|
|
1312
|
+
evidence: {
|
|
1313
|
+
...report.evidence,
|
|
1314
|
+
isCurrent: () => isCurrent() && sourceGuard(),
|
|
1315
|
+
sourceIsCurrent: sourceGuard,
|
|
1316
|
+
},
|
|
1317
|
+
});
|
|
1318
|
+
};
|
|
1319
|
+
const task = (async () => {
|
|
1320
|
+
if (value !== null && qualifiedIdentity) {
|
|
1321
|
+
lease = await this.sampleSourcesRegistry?.get(source.property.id);
|
|
1322
|
+
if (!isCurrent())
|
|
1323
|
+
return;
|
|
1324
|
+
if (!lease ||
|
|
1325
|
+
lease.metadata.fingerprint !== source.channel.identifier.split(':').at(-1) ||
|
|
1326
|
+
lease.metadata.componentKey !== source.componentKey ||
|
|
1327
|
+
lease.metadata.deviceId !== device.id ||
|
|
1328
|
+
!this.sampleSourcesRegistry?.isCurrent(lease, sample.evidence.observedAt)) {
|
|
1329
|
+
await admit(null);
|
|
1330
|
+
return;
|
|
1331
|
+
}
|
|
1332
|
+
const current = await delegate.readNativeTemperatureIdentity(source.componentKey);
|
|
1333
|
+
if (!isCurrent())
|
|
1334
|
+
return;
|
|
1335
|
+
const identity = current &&
|
|
1336
|
+
((0, native_temperature_contract_1.hasQualifiedRawVoltageIdentity)(source.channel.identifier)
|
|
1337
|
+
? (0, native_temperature_contract_1.nativeVoltmeterVoltageIdentity)(source.componentKey, current.config, current.peripherals, device.canonicalMac)
|
|
1338
|
+
: (0, native_temperature_contract_1.nativeTemperatureIdentity)(source.componentKey, current.config, current.peripherals));
|
|
1339
|
+
if (!identity ||
|
|
1340
|
+
identity.channelIdentifier !== source.channel.identifier ||
|
|
1341
|
+
!this.sampleSourcesRegistry.isCurrent(lease, sample.evidence.observedAt)) {
|
|
1342
|
+
await admit(null);
|
|
1343
|
+
return;
|
|
1344
|
+
}
|
|
1345
|
+
sourceProof = true;
|
|
1346
|
+
}
|
|
1347
|
+
if (!isCurrent())
|
|
1348
|
+
return;
|
|
1349
|
+
const evidence = sample.evidence;
|
|
1350
|
+
const observedAt = evidence.observedAt;
|
|
1351
|
+
const invalidDeviceClock = !Number.isFinite(evidence.sampledAt.getTime()) ||
|
|
1352
|
+
evidence.sampledAt.getTime() > evidence.receivedAt.getTime();
|
|
1353
|
+
const ordinarySample = !qualifiedIdentity &&
|
|
1354
|
+
invalidDeviceClock &&
|
|
1355
|
+
evidence.provenance === 'live' &&
|
|
1356
|
+
(evidence.sourceIsCurrent?.() ?? evidence.isCurrent?.()) === true &&
|
|
1357
|
+
sourceIsCurrent() &&
|
|
1358
|
+
observedAt instanceof Date &&
|
|
1359
|
+
Number.isFinite(observedAt.getTime()) &&
|
|
1360
|
+
observedAt.getTime() <= evidence.receivedAt.getTime()
|
|
1361
|
+
? { ...sample, evidence: { ...evidence, sampledAt: observedAt } }
|
|
1362
|
+
: sample;
|
|
1363
|
+
const admitted = value !== null && /^temperature:1\d\d$/.test(source.channel.identifier)
|
|
1364
|
+
? { ...sample, evidence: { ...sample.evidence, provenance: 'cached' } }
|
|
1365
|
+
: ordinarySample;
|
|
1366
|
+
await admit(value, admitted);
|
|
1367
|
+
})();
|
|
1368
|
+
let active = this.activeSamples.get(delegate.id);
|
|
1369
|
+
if (!active) {
|
|
1370
|
+
active = new Set();
|
|
1371
|
+
this.activeSamples.set(delegate.id, active);
|
|
1372
|
+
}
|
|
1373
|
+
active.add(task);
|
|
1374
|
+
void task
|
|
1375
|
+
.catch((error) => this.logger.error(`Shelly sample admission failed: ${error.message}`))
|
|
1376
|
+
.finally(() => active.delete(task));
|
|
1377
|
+
}
|
|
1378
|
+
};
|
|
1379
|
+
delegate.on('sample', handler);
|
|
1380
|
+
this.sampleHandlers.set(delegate.id, handler);
|
|
1381
|
+
}
|
|
1382
|
+
async admitRawSample(property, value, sample) {
|
|
1383
|
+
await this.channelsPropertiesService.reportSample(property.id, (0, transform_utils_1.toInstance)(update_channel_property_dto_1.UpdateShellyNgChannelPropertyDto, { type: devices_shelly_ng_constants_1.DEVICES_SHELLY_NG_TYPE, value }), {
|
|
1384
|
+
...sample.evidence,
|
|
1385
|
+
...(property.category === devices_constants_1.PropertyCategory.TILT && property.identifier === 'slat_pos'
|
|
1386
|
+
? { semanticOrigin: 'native_cover_tilt_percentage' }
|
|
1387
|
+
: {}),
|
|
1388
|
+
...(property.category === devices_constants_1.PropertyCategory.STATUS &&
|
|
1389
|
+
/^cover:\d+$/.test(sample.componentKey) &&
|
|
1390
|
+
(0, cover_action_contract_1.nativeCoverStatus)(sample.values, Number(sample.componentKey.split(':')[1]))
|
|
1391
|
+
? {
|
|
1392
|
+
semanticOrigin: 'native_cover_status',
|
|
1393
|
+
nativeCoverTagPresent: Object.hasOwn(sample.values, 'tag') &&
|
|
1394
|
+
(sample.values.tag === null || typeof sample.values.tag === 'string'),
|
|
1395
|
+
}
|
|
1396
|
+
: {}),
|
|
1397
|
+
});
|
|
1398
|
+
}
|
|
1399
|
+
prepareGuardRpcSession(device, componentId, qualification) {
|
|
1400
|
+
const admission = this.captureGuardedSessionAdmission();
|
|
1401
|
+
if (!admission)
|
|
1402
|
+
return null;
|
|
1403
|
+
if (!device.identifier ||
|
|
1404
|
+
qualification.guardScript?.canonicalMac.toUpperCase() !== device.canonicalMac?.toUpperCase())
|
|
1405
|
+
return null;
|
|
1406
|
+
for (const id of this.identifierToDelegates.get(device.identifier) ?? []) {
|
|
1407
|
+
const delegate = this.delegates.get(id);
|
|
1408
|
+
if (!delegate?.guardedTransportActive || this.delegateDeviceIds.get(id) !== device.id)
|
|
1409
|
+
continue;
|
|
1410
|
+
const generation = this.sampleGenerations.get(id) ?? 0;
|
|
1411
|
+
const lease = delegate.prepareGuardRpcSession(componentId, qualification, () => admission.isCurrent() &&
|
|
1412
|
+
this.delegates.get(id) === delegate &&
|
|
1413
|
+
this.delegateDeviceIds.get(id) === device.id &&
|
|
1414
|
+
(this.sampleGenerations.get(id) ?? 0) === generation);
|
|
1415
|
+
if (lease?.isCurrent())
|
|
1416
|
+
return lease;
|
|
1417
|
+
}
|
|
1418
|
+
return null;
|
|
1419
|
+
}
|
|
1420
|
+
async admitGuardFenceSample(property, readback) {
|
|
1421
|
+
if (!readback.isCurrent())
|
|
1422
|
+
return;
|
|
1423
|
+
await this.channelsPropertiesService.reportSample(property.id, (0, transform_utils_1.toInstance)(update_channel_property_dto_1.UpdateShellyNgChannelPropertyDto, { type: devices_shelly_ng_constants_1.DEVICES_SHELLY_NG_TYPE, value: false }), readback.evidence);
|
|
1424
|
+
}
|
|
1425
|
+
async protectiveSwitch(deviceIdentifier, componentId, command, timeoutMs, isAdmitted) {
|
|
1426
|
+
if (!command.on) {
|
|
1427
|
+
for (const id of this.identifierToDelegates.get(deviceIdentifier) ?? [])
|
|
1428
|
+
this.delegates.get(id)?.revokePendingProtectiveOn();
|
|
1429
|
+
}
|
|
1430
|
+
for (const id of this.identifierToDelegates.get(deviceIdentifier) ?? []) {
|
|
1431
|
+
const delegate = this.delegates.get(id);
|
|
1432
|
+
if (delegate?.rpcConnected) {
|
|
1433
|
+
if (command.on) {
|
|
1434
|
+
const deviceId = this.delegateDeviceIds.get(id);
|
|
1435
|
+
const device = deviceId && (await this.devicesService.findOne(deviceId, devices_shelly_ng_constants_1.DEVICES_SHELLY_NG_TYPE));
|
|
1436
|
+
if (!device?.enabled)
|
|
1437
|
+
return { outcome: 'refused', reasons: ['source_disabled_or_missing'] };
|
|
1438
|
+
if (this.delegates.get(id) !== delegate || this.delegateDeviceIds.get(id) !== deviceId)
|
|
1439
|
+
return { outcome: 'refused', reasons: ['source_generation_changed'] };
|
|
1440
|
+
}
|
|
1441
|
+
return delegate.protectiveSwitch(componentId, command, timeoutMs, isAdmitted);
|
|
1442
|
+
}
|
|
1443
|
+
}
|
|
1444
|
+
return { outcome: 'refused', reasons: ['source_unavailable'] };
|
|
1445
|
+
}
|
|
1101
1446
|
async performRemove(deviceId) {
|
|
1102
1447
|
const delegate = this.delegates.get(deviceId);
|
|
1103
1448
|
if (!delegate) {
|
|
1104
1449
|
return;
|
|
1105
1450
|
}
|
|
1451
|
+
await this.unbindSamples(delegate);
|
|
1106
1452
|
const valueHandler = this.delegateValueHandlers.get(delegate.id);
|
|
1107
1453
|
if (valueHandler) {
|
|
1108
1454
|
delegate.off('value', valueHandler);
|
|
@@ -1188,6 +1534,336 @@ let DelegatesManagerService = DelegatesManagerService_1 = class DelegatesManager
|
|
|
1188
1534
|
this.delegates.delete(deviceId);
|
|
1189
1535
|
this.logger.log(`Detached Shelly device=${deviceId}`, { resource: deviceId });
|
|
1190
1536
|
}
|
|
1537
|
+
captureThermostatSetupMetadata(device, componentId) {
|
|
1538
|
+
for (const id of this.identifierToDelegates.get(device.identifier) ?? []) {
|
|
1539
|
+
const delegate = this.delegates.get(id);
|
|
1540
|
+
if (this.delegateDeviceIds.get(id) !== device.id)
|
|
1541
|
+
continue;
|
|
1542
|
+
const snapshot = delegate?.captureThermostatSetupMetadata(componentId);
|
|
1543
|
+
if (snapshot?.isCurrent())
|
|
1544
|
+
return {
|
|
1545
|
+
...snapshot,
|
|
1546
|
+
isCurrent: () => this.delegates.get(id) === delegate && this.delegateDeviceIds.get(id) === device.id && snapshot.isCurrent(),
|
|
1547
|
+
};
|
|
1548
|
+
}
|
|
1549
|
+
return null;
|
|
1550
|
+
}
|
|
1551
|
+
hasGuardedTransport(deviceIdentifier) {
|
|
1552
|
+
return [...(this.identifierToDelegates.get(deviceIdentifier) ?? [])].some((id) => this.delegates.get(id)?.guardedTransportActive === true);
|
|
1553
|
+
}
|
|
1554
|
+
async coverCommandReadiness(update) {
|
|
1555
|
+
if (![devices_constants_1.PropertyCategory.COMMAND, devices_constants_1.PropertyCategory.POSITION, devices_constants_1.PropertyCategory.TILT].includes(update.property.category))
|
|
1556
|
+
return { commandable: false, reasons: ['qualified_cover_position_or_tilt_adapter_unavailable'] };
|
|
1557
|
+
const canonicalMac = update.device.canonicalMac;
|
|
1558
|
+
if (update.device.type === 'devices-shelly-ng' &&
|
|
1559
|
+
canonicalMac &&
|
|
1560
|
+
/^cover:\d+$/.test(update.channel.identifier ?? '') &&
|
|
1561
|
+
this.coverOrdering) {
|
|
1562
|
+
const componentId = Number(update.channel.identifier.split(':')[1]);
|
|
1563
|
+
for (const id of this.identifierToDelegates.get(update.device.identifier) ?? []) {
|
|
1564
|
+
const delegate = this.delegates.get(id);
|
|
1565
|
+
if (delegate?.covers.has(componentId) &&
|
|
1566
|
+
this.delegateDeviceIds.get(id) === update.device.id &&
|
|
1567
|
+
(await this.coverOrdering.blocked(`${canonicalMac.toUpperCase()}|cover:${componentId}`)))
|
|
1568
|
+
return { commandable: false, reasons: ['cover_ordering_unresolved_operator_recovery_required'] };
|
|
1569
|
+
}
|
|
1570
|
+
}
|
|
1571
|
+
const properties = await this.channelsPropertiesService.findAll(update.channel.id);
|
|
1572
|
+
const issue = this.coverIssues.get(`${update.device.id}|${update.channel.id}`);
|
|
1573
|
+
if (issue)
|
|
1574
|
+
return { commandable: false, reasons: [issue] };
|
|
1575
|
+
if (!(0, cover_action_contract_1.configuredCoverType)(properties))
|
|
1576
|
+
return { commandable: false, reasons: ['cover_type_unconfigured'] };
|
|
1577
|
+
const status = properties.find((property) => property.category === devices_constants_1.PropertyCategory.STATUS);
|
|
1578
|
+
if (!status || this.coverValues?.readQualifiedSample(status, 300_000)?.nativeCoverTagPresent !== true)
|
|
1579
|
+
return { commandable: false, reasons: ['cover_action_tag_field_not_observed_in_qualified_status'] };
|
|
1580
|
+
for (const id of this.identifierToDelegates.get(update.device.identifier) ?? []) {
|
|
1581
|
+
const delegate = this.delegates.get(id);
|
|
1582
|
+
if (!delegate || this.delegateDeviceIds.get(id) !== update.device.id)
|
|
1583
|
+
continue;
|
|
1584
|
+
const componentId = Number(update.channel.identifier?.split(':')[1]);
|
|
1585
|
+
const component = delegate.covers.get(componentId);
|
|
1586
|
+
if (component && !(0, cover_action_contract_1.nativeCoverStatus)(component, componentId))
|
|
1587
|
+
return { commandable: false, reasons: [(0, cover_action_contract_1.coverStatusReason)(component)] };
|
|
1588
|
+
}
|
|
1589
|
+
const prepared = await this.prepareCoverAction(update);
|
|
1590
|
+
if (!prepared)
|
|
1591
|
+
return { commandable: false, reasons: ['qualified_cover_adapter_or_ordering_unavailable'] };
|
|
1592
|
+
prepared.dispose?.();
|
|
1593
|
+
return { commandable: true, reasons: [] };
|
|
1594
|
+
}
|
|
1595
|
+
async captureCoverRecoveryTarget(update) {
|
|
1596
|
+
if (!this.coverValues ||
|
|
1597
|
+
!this.coverOrdering ||
|
|
1598
|
+
!this.coverRecoveryLane ||
|
|
1599
|
+
update.property.category !== devices_constants_1.PropertyCategory.COMMAND ||
|
|
1600
|
+
!/^cover:\d+$/.test(update.channel.identifier ?? ''))
|
|
1601
|
+
return null;
|
|
1602
|
+
const properties = await this.channelsPropertiesService.findAll(update.channel.id);
|
|
1603
|
+
const status = properties.find((property) => property.category === devices_constants_1.PropertyCategory.STATUS);
|
|
1604
|
+
const position = properties.find((property) => property.category === devices_constants_1.PropertyCategory.POSITION);
|
|
1605
|
+
if (!(0, cover_action_contract_1.configuredCoverType)(properties) ||
|
|
1606
|
+
status?.identifier !== 'state' ||
|
|
1607
|
+
status.dataType !== devices_constants_1.DataTypeType.ENUM ||
|
|
1608
|
+
position?.identifier !== 'current_pos' ||
|
|
1609
|
+
position.dataType !== devices_constants_1.DataTypeType.UCHAR ||
|
|
1610
|
+
JSON.stringify(position.format) !== '[0,100]' ||
|
|
1611
|
+
update.property.dataType !== devices_constants_1.DataTypeType.ENUM ||
|
|
1612
|
+
JSON.stringify(update.property.format) !== '["open","close","stop"]')
|
|
1613
|
+
return null;
|
|
1614
|
+
const mac = update.device.canonicalMac?.toUpperCase();
|
|
1615
|
+
if (!mac)
|
|
1616
|
+
return null;
|
|
1617
|
+
for (const id of this.identifierToDelegates.get(update.device.identifier) ?? []) {
|
|
1618
|
+
const delegate = this.delegates.get(id);
|
|
1619
|
+
if (!delegate || this.delegateDeviceIds.get(id) !== update.device.id)
|
|
1620
|
+
continue;
|
|
1621
|
+
const connection = delegate.captureCoverRecoveryConnection(update.channel.identifier, mac);
|
|
1622
|
+
if (!connection)
|
|
1623
|
+
continue;
|
|
1624
|
+
const generation = this.sampleGenerations.get(id) ?? 0;
|
|
1625
|
+
const mappings = () => JSON.stringify(properties.map((property) => ({
|
|
1626
|
+
id: property.id,
|
|
1627
|
+
category: property.category,
|
|
1628
|
+
identifier: property.identifier,
|
|
1629
|
+
format: property.format,
|
|
1630
|
+
dataType: property.dataType,
|
|
1631
|
+
step: property.step,
|
|
1632
|
+
permissions: property.permissions,
|
|
1633
|
+
mapping: this.propertyMappingStorage.get(property.id),
|
|
1634
|
+
})));
|
|
1635
|
+
const mapping = mappings();
|
|
1636
|
+
const isCurrent = () => connection.isCurrent() &&
|
|
1637
|
+
this.delegates.get(id) === delegate &&
|
|
1638
|
+
this.delegateDeviceIds.get(id) === update.device.id &&
|
|
1639
|
+
(this.sampleGenerations.get(id) ?? 0) === generation &&
|
|
1640
|
+
mappings() === mapping;
|
|
1641
|
+
return {
|
|
1642
|
+
physicalIdentity: `${mac}|cover:${Number(update.channel.identifier.split(':')[1])}`,
|
|
1643
|
+
revision: JSON.stringify([id, connection.revision, generation, mapping]),
|
|
1644
|
+
isCurrent,
|
|
1645
|
+
retire: () => delegate.retireCoverSession(update.channel.identifier),
|
|
1646
|
+
begin: () => {
|
|
1647
|
+
if (!isCurrent())
|
|
1648
|
+
throw new Error('Cover connection/mapping changed');
|
|
1649
|
+
return delegate.beginCoverRecoverySession(update.channel.identifier, mac, this.coverOrdering);
|
|
1650
|
+
},
|
|
1651
|
+
};
|
|
1652
|
+
}
|
|
1653
|
+
return null;
|
|
1654
|
+
}
|
|
1655
|
+
async prepareCoverAction(update) {
|
|
1656
|
+
if (!this.coverValues ||
|
|
1657
|
+
!this.coverOrdering ||
|
|
1658
|
+
![devices_constants_1.PropertyCategory.COMMAND, devices_constants_1.PropertyCategory.POSITION, devices_constants_1.PropertyCategory.TILT].includes(update.property.category) ||
|
|
1659
|
+
(update.property.category === devices_constants_1.PropertyCategory.COMMAND
|
|
1660
|
+
? !['open', 'close', 'stop'].includes(String(update.value))
|
|
1661
|
+
: typeof update.value !== 'number' ||
|
|
1662
|
+
!Number.isInteger(update.value) ||
|
|
1663
|
+
update.value < 0 ||
|
|
1664
|
+
update.value > 100) ||
|
|
1665
|
+
!/^cover:\d+$/.test(update.channel.identifier ?? ''))
|
|
1666
|
+
return null;
|
|
1667
|
+
const properties = await this.channelsPropertiesService.findAll(update.channel.id);
|
|
1668
|
+
const status = properties.find((property) => property.category === devices_constants_1.PropertyCategory.STATUS);
|
|
1669
|
+
const position = properties.find((property) => property.category === devices_constants_1.PropertyCategory.POSITION);
|
|
1670
|
+
const command = properties.find((property) => property.id === update.property.id);
|
|
1671
|
+
const tilt = properties.find((property) => property.category === devices_constants_1.PropertyCategory.TILT && (0, cover_action_contract_1.nativeCoverPercentage)(property));
|
|
1672
|
+
if (!(0, cover_action_contract_1.configuredCoverType)(properties) ||
|
|
1673
|
+
!status ||
|
|
1674
|
+
!position ||
|
|
1675
|
+
!command ||
|
|
1676
|
+
status.identifier !== 'state' ||
|
|
1677
|
+
status.dataType !== devices_constants_1.DataTypeType.ENUM ||
|
|
1678
|
+
position.identifier !== 'current_pos' ||
|
|
1679
|
+
position.dataType !== devices_constants_1.DataTypeType.UCHAR ||
|
|
1680
|
+
JSON.stringify(position.format) !== '[0,100]' ||
|
|
1681
|
+
(update.property.category === devices_constants_1.PropertyCategory.COMMAND
|
|
1682
|
+
? command.dataType !== devices_constants_1.DataTypeType.ENUM || JSON.stringify(command.format) !== '["open","close","stop"]'
|
|
1683
|
+
: command.dataType !== devices_constants_1.DataTypeType.UCHAR ||
|
|
1684
|
+
(0, property_metadata_utils_1.resolvePropertyUnit)(command) !== '%' ||
|
|
1685
|
+
JSON.stringify(command.format) !== '[0,100]' ||
|
|
1686
|
+
(command.step != null && command.step !== 1) ||
|
|
1687
|
+
!command.permissions.includes(devices_constants_1.PermissionType.READ_WRITE) ||
|
|
1688
|
+
(update.property.category === devices_constants_1.PropertyCategory.POSITION
|
|
1689
|
+
? command.id !== position.id
|
|
1690
|
+
: command.id !== tilt?.id)))
|
|
1691
|
+
return null;
|
|
1692
|
+
if (this.coverValues.readQualifiedSample(status, 300_000)?.nativeCoverTagPresent !== true)
|
|
1693
|
+
return null;
|
|
1694
|
+
for (const id of this.identifierToDelegates.get(update.device.identifier) ?? []) {
|
|
1695
|
+
const delegate = this.delegates.get(id);
|
|
1696
|
+
if (!delegate || this.delegateDeviceIds.get(id) !== update.device.id)
|
|
1697
|
+
continue;
|
|
1698
|
+
const componentId = Number(update.channel.identifier.split(':')[1]);
|
|
1699
|
+
const component = delegate.covers.get(componentId);
|
|
1700
|
+
if (!(0, cover_action_contract_1.nativeCoverStatus)(component, componentId))
|
|
1701
|
+
continue;
|
|
1702
|
+
const slat = component.slat_pos;
|
|
1703
|
+
if (update.property.category === devices_constants_1.PropertyCategory.TILT &&
|
|
1704
|
+
(typeof slat !== 'number' || !Number.isFinite(slat) || slat < 0 || slat > 100))
|
|
1705
|
+
continue;
|
|
1706
|
+
const canonicalMac = update.device.canonicalMac;
|
|
1707
|
+
if (!canonicalMac || (await this.coverOrdering.blocked(`${canonicalMac.toUpperCase()}|cover:${componentId}`)))
|
|
1708
|
+
continue;
|
|
1709
|
+
const recoveryLease = this.coverRecoveryLane?.prepare(`${canonicalMac.toUpperCase()}|cover:${Number(update.channel.identifier.split(':')[1])}`);
|
|
1710
|
+
if (this.coverRecoveryLane && !recoveryLease)
|
|
1711
|
+
continue;
|
|
1712
|
+
const session = delegate.prepareCoverSession(update.channel.identifier, canonicalMac, this.coverOrdering);
|
|
1713
|
+
if (!session?.isReady()) {
|
|
1714
|
+
recoveryLease?.dispose();
|
|
1715
|
+
continue;
|
|
1716
|
+
}
|
|
1717
|
+
const generation = this.sampleGenerations.get(id) ?? 0;
|
|
1718
|
+
const mappings = () => JSON.stringify(properties.map((property) => ({
|
|
1719
|
+
id: property.id,
|
|
1720
|
+
category: property.category,
|
|
1721
|
+
dataType: property.dataType,
|
|
1722
|
+
format: property.format,
|
|
1723
|
+
step: property.step,
|
|
1724
|
+
permissions: property.permissions,
|
|
1725
|
+
identifier: property.identifier,
|
|
1726
|
+
mapping: this.propertyMappingStorage.get(property.id),
|
|
1727
|
+
})));
|
|
1728
|
+
const snapshot = mappings();
|
|
1729
|
+
let disposed = false;
|
|
1730
|
+
const sourceCurrent = () => snapshot === mappings() &&
|
|
1731
|
+
this.delegates.get(id) === delegate &&
|
|
1732
|
+
this.delegateDeviceIds.get(id) === update.device.id &&
|
|
1733
|
+
(this.sampleGenerations.get(id) ?? 0) === generation &&
|
|
1734
|
+
delegate.guardedTransportActive &&
|
|
1735
|
+
update.device.enabled;
|
|
1736
|
+
const isCurrent = () => !disposed && sourceCurrent() && (!recoveryLease || recoveryLease.isCurrent());
|
|
1737
|
+
const action = {
|
|
1738
|
+
kind: 'cover_action',
|
|
1739
|
+
effectScope: `shelly-ng:${canonicalMac.toUpperCase()}|cover:${componentId}`,
|
|
1740
|
+
commandPropertyId: command.id,
|
|
1741
|
+
status,
|
|
1742
|
+
position,
|
|
1743
|
+
...(update.property.category === devices_constants_1.PropertyCategory.TILT ? { tilt } : {}),
|
|
1744
|
+
effects: properties.filter((property) => [devices_constants_1.PropertyCategory.POSITION, devices_constants_1.PropertyCategory.TILT].includes(property.category)),
|
|
1745
|
+
};
|
|
1746
|
+
return {
|
|
1747
|
+
updates: [update],
|
|
1748
|
+
coverAction: action,
|
|
1749
|
+
isCurrent,
|
|
1750
|
+
dispose: () => {
|
|
1751
|
+
disposed = true;
|
|
1752
|
+
recoveryLease?.dispose();
|
|
1753
|
+
},
|
|
1754
|
+
dispatch: async (guard, context) => {
|
|
1755
|
+
if (!context || !guard() || !isCurrent())
|
|
1756
|
+
return false;
|
|
1757
|
+
const current = () => isCurrent() && guard() && context.isCurrent();
|
|
1758
|
+
const leave = recoveryLease?.enter();
|
|
1759
|
+
try {
|
|
1760
|
+
return await session.dispatch(update.property.category === devices_constants_1.PropertyCategory.POSITION
|
|
1761
|
+
? { position: update.value }
|
|
1762
|
+
: update.property.category === devices_constants_1.PropertyCategory.TILT
|
|
1763
|
+
? { tilt: update.value }
|
|
1764
|
+
: update.value, { ...context, isCurrent: current }, async (raw, observedAt, preflightState) => {
|
|
1765
|
+
if (!current())
|
|
1766
|
+
return false;
|
|
1767
|
+
this.coverIssues.delete(`${update.device.id}|${update.channel.id}`);
|
|
1768
|
+
const acceptanceBoundary = this.coverValues.currentSampleGeneration();
|
|
1769
|
+
const sample = {
|
|
1770
|
+
componentKey: update.channel.identifier,
|
|
1771
|
+
values: raw,
|
|
1772
|
+
evidence: {
|
|
1773
|
+
sampledAt: observedAt,
|
|
1774
|
+
observedAt,
|
|
1775
|
+
receivedAt: new Date(),
|
|
1776
|
+
provenance: 'live',
|
|
1777
|
+
isCurrent: current,
|
|
1778
|
+
sourceIsCurrent: sourceCurrent,
|
|
1779
|
+
commandObservation: context.observationToken,
|
|
1780
|
+
},
|
|
1781
|
+
};
|
|
1782
|
+
await this.admitRawSample(status, raw.state === 'open' ? 'opened' : raw.state, sample);
|
|
1783
|
+
await this.admitRawSample(position, raw.current_pos, sample);
|
|
1784
|
+
if (tilt)
|
|
1785
|
+
await this.admitRawSample(tilt, typeof raw.slat_pos === 'number' &&
|
|
1786
|
+
Number.isFinite(raw.slat_pos) &&
|
|
1787
|
+
raw.slat_pos >= 0 &&
|
|
1788
|
+
raw.slat_pos <= 100
|
|
1789
|
+
? raw.slat_pos
|
|
1790
|
+
: null, sample);
|
|
1791
|
+
const statusSample = this.coverValues.readQualifiedSample(status, 30_000);
|
|
1792
|
+
const positionSample = this.coverValues.readQualifiedSample(position, 30_000);
|
|
1793
|
+
if (!current() || !statusSample || !positionSample)
|
|
1794
|
+
return false;
|
|
1795
|
+
return context.observe({
|
|
1796
|
+
state: raw.state,
|
|
1797
|
+
position: raw.current_pos,
|
|
1798
|
+
tag: raw.tag,
|
|
1799
|
+
observedAt,
|
|
1800
|
+
preflightState,
|
|
1801
|
+
acceptanceBoundary,
|
|
1802
|
+
statusAcceptance: statusSample.acceptanceGeneration,
|
|
1803
|
+
positionAcceptance: positionSample.acceptanceGeneration,
|
|
1804
|
+
tilt: raw.slat_pos ?? undefined,
|
|
1805
|
+
tiltAcceptance: tilt
|
|
1806
|
+
? this.coverValues.readQualifiedSample(tilt, 30_000)?.acceptanceGeneration
|
|
1807
|
+
: undefined,
|
|
1808
|
+
});
|
|
1809
|
+
}, async (raw, observedAt) => {
|
|
1810
|
+
if (!current())
|
|
1811
|
+
return;
|
|
1812
|
+
this.coverIssues.set(`${update.device.id}|${update.channel.id}`, (0, cover_action_contract_1.coverStatusReason)(raw));
|
|
1813
|
+
const sample = {
|
|
1814
|
+
componentKey: update.channel.identifier,
|
|
1815
|
+
values: raw,
|
|
1816
|
+
evidence: {
|
|
1817
|
+
observedAt,
|
|
1818
|
+
sampledAt: observedAt,
|
|
1819
|
+
receivedAt: new Date(),
|
|
1820
|
+
provenance: 'live',
|
|
1821
|
+
isCurrent: current,
|
|
1822
|
+
sourceIsCurrent: sourceCurrent,
|
|
1823
|
+
},
|
|
1824
|
+
};
|
|
1825
|
+
await this.admitRawSample(status, null, sample);
|
|
1826
|
+
await this.admitRawSample(position, null, sample);
|
|
1827
|
+
});
|
|
1828
|
+
}
|
|
1829
|
+
finally {
|
|
1830
|
+
leave?.();
|
|
1831
|
+
}
|
|
1832
|
+
},
|
|
1833
|
+
};
|
|
1834
|
+
}
|
|
1835
|
+
return null;
|
|
1836
|
+
}
|
|
1837
|
+
async prepareLightingCommand(device, componentKey, on, brightness, properties = []) {
|
|
1838
|
+
const mappings = () => JSON.stringify(properties.map((property) => this.propertyMappingStorage.get(property.id)));
|
|
1839
|
+
const mappingSnapshot = mappings();
|
|
1840
|
+
for (const property of properties) {
|
|
1841
|
+
const mapping = this.propertyMappingStorage.get(property.id);
|
|
1842
|
+
const value = property.identifier === 'output' ? on : brightness;
|
|
1843
|
+
if (mapping && this.applyTransformer(mapping, value, 'write') !== value)
|
|
1844
|
+
return null;
|
|
1845
|
+
}
|
|
1846
|
+
for (const id of this.identifierToDelegates.get(device.identifier) ?? []) {
|
|
1847
|
+
const delegate = this.delegates.get(id);
|
|
1848
|
+
if (!delegate || this.delegateDeviceIds.get(id) !== device.id)
|
|
1849
|
+
continue;
|
|
1850
|
+
const prepared = delegate.prepareLightingCommand(componentKey, on, brightness);
|
|
1851
|
+
if (!prepared)
|
|
1852
|
+
continue;
|
|
1853
|
+
const identifier = device.identifier;
|
|
1854
|
+
const isCurrent = () => mappingSnapshot === mappings() &&
|
|
1855
|
+
device.enabled &&
|
|
1856
|
+
device.identifier === identifier &&
|
|
1857
|
+
this.delegates.get(id) === delegate &&
|
|
1858
|
+
this.delegateDeviceIds.get(id) === device.id &&
|
|
1859
|
+
prepared.isCurrent();
|
|
1860
|
+
const current = await this.devicesService.findOne(device.id, devices_shelly_ng_constants_1.DEVICES_SHELLY_NG_TYPE);
|
|
1861
|
+
if (!current?.enabled || current.identifier !== identifier || !isCurrent())
|
|
1862
|
+
return null;
|
|
1863
|
+
return { isCurrent, dispatch: (isAdmitted) => prepared.dispatch(() => isCurrent() && isAdmitted()) };
|
|
1864
|
+
}
|
|
1865
|
+
return null;
|
|
1866
|
+
}
|
|
1191
1867
|
async setChannelValue(device, channel, updates) {
|
|
1192
1868
|
const handler = this.resolveChannelHandler(device.identifier, channel.id);
|
|
1193
1869
|
if (!handler) {
|
|
@@ -1880,8 +2556,10 @@ let DelegatesManagerService = DelegatesManagerService_1 = class DelegatesManager
|
|
|
1880
2556
|
return fallback;
|
|
1881
2557
|
}
|
|
1882
2558
|
async detach() {
|
|
2559
|
+
this.revokeGuardedSessionAdmission();
|
|
1883
2560
|
const teardownPromises = [];
|
|
1884
2561
|
for (const [, delegate] of this.delegates.entries()) {
|
|
2562
|
+
teardownPromises.push(this.unbindSamples(delegate));
|
|
1885
2563
|
const valueHandler = this.delegateValueHandlers.get(delegate.id);
|
|
1886
2564
|
const connectionHandler = this.delegateConnectionHandlers.get(delegate.id);
|
|
1887
2565
|
if (valueHandler) {
|
|
@@ -2060,6 +2738,10 @@ exports.DelegatesManagerService = DelegatesManagerService = DelegatesManagerServ
|
|
|
2060
2738
|
__param(8, (0, common_1.Optional)()),
|
|
2061
2739
|
__param(9, (0, common_1.Optional)()),
|
|
2062
2740
|
__param(10, (0, common_1.Optional)()),
|
|
2741
|
+
__param(11, (0, common_1.Optional)()),
|
|
2742
|
+
__param(12, (0, common_1.Optional)()),
|
|
2743
|
+
__param(13, (0, common_1.Optional)()),
|
|
2744
|
+
__param(14, (0, common_1.Optional)()),
|
|
2063
2745
|
__metadata("design:paramtypes", [devices_service_1.DevicesService,
|
|
2064
2746
|
channels_service_1.ChannelsService,
|
|
2065
2747
|
channels_properties_service_1.ChannelsPropertiesService,
|
|
@@ -2070,6 +2752,10 @@ exports.DelegatesManagerService = DelegatesManagerService = DelegatesManagerServ
|
|
|
2070
2752
|
mappings_1.TransformerRegistry,
|
|
2071
2753
|
command_latency_trace_collector_service_1.CommandLatencyTraceCollectorService,
|
|
2072
2754
|
poll_placement_diagnostics_service_1.PollPlacementDiagnosticsService,
|
|
2073
|
-
channel_input_occurrences_service_1.ChannelInputOccurrencesService
|
|
2755
|
+
channel_input_occurrences_service_1.ChannelInputOccurrencesService,
|
|
2756
|
+
shelly_sample_sources_service_1.ShellySampleSourcesService,
|
|
2757
|
+
property_value_service_1.PropertyValueService,
|
|
2758
|
+
shelly_cover_ordering_service_1.ShellyCoverOrderingService,
|
|
2759
|
+
shelly_cover_recovery_lane_service_1.ShellyCoverRecoveryLaneService])
|
|
2074
2760
|
], DelegatesManagerService);
|
|
2075
2761
|
//# sourceMappingURL=delegates-manager.service.js.map
|