@ledgerhq/device-management-kit 0.6.5 → 0.8.0
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/README.md +40 -3
- package/lib/cjs/package.json +22 -23
- package/lib/cjs/src/api/DeviceManagementKit.js +1 -1
- package/lib/cjs/src/api/DeviceManagementKit.js.map +3 -3
- package/lib/cjs/src/api/DeviceManagementKit.test.js +1 -1
- package/lib/cjs/src/api/DeviceManagementKit.test.js.map +3 -3
- package/lib/cjs/src/api/DeviceManagementKitBuilder.js +1 -1
- package/lib/cjs/src/api/DeviceManagementKitBuilder.js.map +2 -2
- package/lib/cjs/src/api/DmkConfig.js +1 -1
- package/lib/cjs/src/api/DmkConfig.js.map +1 -1
- package/lib/cjs/src/api/apdu/utils/ByteArrayBuilder.js +1 -1
- package/lib/cjs/src/api/apdu/utils/ByteArrayBuilder.js.map +3 -3
- package/lib/cjs/src/api/apdu/utils/ByteArrayBuilder.test.js +1 -1
- package/lib/cjs/src/api/apdu/utils/ByteArrayBuilder.test.js.map +2 -2
- package/lib/cjs/src/api/apdu/utils/ByteArrayParser.js +1 -1
- package/lib/cjs/src/api/apdu/utils/ByteArrayParser.js.map +3 -3
- package/lib/cjs/src/api/command/di/commandModule.js +1 -1
- package/lib/cjs/src/api/command/di/commandModule.js.map +3 -3
- package/lib/cjs/src/api/command/di/commandModule.test.js +1 -1
- package/lib/cjs/src/api/command/di/commandModule.test.js.map +2 -2
- package/lib/cjs/src/api/command/os/GetCustomImageSizeCommand.js +2 -0
- package/lib/cjs/src/api/command/os/GetCustomImageSizeCommand.js.map +7 -0
- package/lib/cjs/src/api/command/os/GetCustomImageSizeCommand.test.js +2 -0
- package/lib/cjs/src/api/command/os/GetCustomImageSizeCommand.test.js.map +7 -0
- package/lib/cjs/src/api/command/os/GetOsVersionCommand.js +1 -1
- package/lib/cjs/src/api/command/os/GetOsVersionCommand.js.map +3 -3
- package/lib/cjs/src/api/command/os/GetOsVersionCommand.test.js +1 -1
- package/lib/cjs/src/api/command/os/GetOsVersionCommand.test.js.map +3 -3
- package/lib/cjs/src/api/command/os/ListLanguagePackCommand.js +2 -0
- package/lib/cjs/src/api/command/os/ListLanguagePackCommand.js.map +7 -0
- package/lib/cjs/src/api/command/os/ListLanguagePackCommand.test.js +2 -0
- package/lib/cjs/src/api/command/os/ListLanguagePackCommand.test.js.map +7 -0
- package/lib/cjs/src/api/command/os/__mocks__/GetOsVersionCommand.js +1 -1
- package/lib/cjs/src/api/command/os/__mocks__/GetOsVersionCommand.js.map +2 -2
- package/lib/cjs/src/api/command/use-case/SendCommandUseCase.js +1 -1
- package/lib/cjs/src/api/command/use-case/SendCommandUseCase.js.map +3 -3
- package/lib/cjs/src/api/command/utils/CommandUtils.js +1 -1
- package/lib/cjs/src/api/command/utils/CommandUtils.js.map +3 -3
- package/lib/cjs/src/api/command/utils/CommandUtils.test.js +1 -1
- package/lib/cjs/src/api/command/utils/CommandUtils.test.js.map +3 -3
- package/lib/cjs/src/api/command/utils/GlobalCommandError.js +1 -1
- package/lib/cjs/src/api/command/utils/GlobalCommandError.js.map +2 -2
- package/lib/cjs/src/api/device/DeviceModel.js +1 -1
- package/lib/cjs/src/api/device/DeviceModel.js.map +2 -2
- package/lib/cjs/src/api/device-action/DeviceAction.js +1 -1
- package/lib/cjs/src/api/device-action/DeviceAction.js.map +1 -1
- package/lib/cjs/src/api/device-action/__test-utils__/makeInternalApi.js +1 -1
- package/lib/cjs/src/api/device-action/__test-utils__/makeInternalApi.js.map +3 -3
- package/lib/cjs/src/api/device-action/__test-utils__/setupTestMachine.js +1 -1
- package/lib/cjs/src/api/device-action/__test-utils__/setupTestMachine.js.map +3 -3
- package/lib/cjs/src/api/device-action/di/deviceActionModule.js +1 -1
- package/lib/cjs/src/api/device-action/di/deviceActionModule.js.map +3 -3
- package/lib/cjs/src/api/device-action/di/deviceActionModule.test.js +1 -1
- package/lib/cjs/src/api/device-action/di/deviceActionModule.test.js.map +2 -2
- package/lib/cjs/src/api/device-action/model/UserInteractionRequired.js +1 -1
- package/lib/cjs/src/api/device-action/model/UserInteractionRequired.js.map +2 -2
- package/lib/cjs/src/api/device-action/os/CallTaskInAppDeviceAction/CallTaskInAppDeviceAction.js +1 -1
- package/lib/cjs/src/api/device-action/os/CallTaskInAppDeviceAction/CallTaskInAppDeviceAction.js.map +2 -2
- package/lib/cjs/src/api/device-action/os/CallTaskInAppDeviceAction/CallTaskInAppDeviceAction.test.js +1 -1
- package/lib/cjs/src/api/device-action/os/CallTaskInAppDeviceAction/CallTaskInAppDeviceAction.test.js.map +2 -2
- package/lib/cjs/src/api/device-action/os/CallTaskInAppDeviceAction/CallTaskInAppDeviceActionTypes.js +1 -1
- package/lib/cjs/src/api/device-action/os/CallTaskInAppDeviceAction/CallTaskInAppDeviceActionTypes.js.map +1 -1
- package/lib/cjs/src/api/device-action/os/Errors.js +1 -1
- package/lib/cjs/src/api/device-action/os/Errors.js.map +3 -3
- package/lib/cjs/src/api/device-action/os/GetDeviceMetadata/GetDeviceMetadataDeviceAction.js +2 -0
- package/lib/cjs/src/api/device-action/os/GetDeviceMetadata/GetDeviceMetadataDeviceAction.js.map +7 -0
- package/lib/cjs/src/api/device-action/os/GetDeviceMetadata/GetDeviceMetadataDeviceAction.test.js +2 -0
- package/lib/cjs/src/api/device-action/os/GetDeviceMetadata/GetDeviceMetadataDeviceAction.test.js.map +7 -0
- package/lib/cjs/src/api/device-action/os/GetDeviceMetadata/types.js +2 -0
- package/lib/cjs/src/api/device-action/os/GetDeviceMetadata/types.js.map +7 -0
- package/lib/cjs/src/api/device-action/os/GetDeviceStatus/GetDeviceStatusDeviceAction.js +1 -1
- package/lib/cjs/src/api/device-action/os/GetDeviceStatus/GetDeviceStatusDeviceAction.js.map +2 -2
- package/lib/cjs/src/api/device-action/os/GetDeviceStatus/GetDeviceStatusDeviceAction.test.js +1 -1
- package/lib/cjs/src/api/device-action/os/GetDeviceStatus/GetDeviceStatusDeviceAction.test.js.map +2 -2
- package/lib/cjs/src/api/device-action/os/GoToDashboard/GoToDashboardDeviceAction.js +1 -1
- package/lib/cjs/src/api/device-action/os/GoToDashboard/GoToDashboardDeviceAction.js.map +3 -3
- package/lib/cjs/src/api/device-action/os/GoToDashboard/types.js +1 -1
- package/lib/cjs/src/api/device-action/os/GoToDashboard/types.js.map +1 -1
- package/lib/cjs/src/api/device-action/os/InstallOrUpdateApps/InstallOrUpdateAppsDeviceAction.js +2 -0
- package/lib/cjs/src/api/device-action/os/InstallOrUpdateApps/InstallOrUpdateAppsDeviceAction.js.map +7 -0
- package/lib/cjs/src/api/device-action/os/InstallOrUpdateApps/InstallOrUpdateAppsDeviceAction.test.js +2 -0
- package/lib/cjs/src/api/device-action/os/InstallOrUpdateApps/InstallOrUpdateAppsDeviceAction.test.js.map +7 -0
- package/lib/cjs/src/api/device-action/os/InstallOrUpdateApps/types.js +2 -0
- package/lib/cjs/src/api/device-action/os/InstallOrUpdateApps/types.js.map +7 -0
- package/lib/cjs/src/api/device-action/os/ListApps/ListAppsDeviceAction.js +1 -1
- package/lib/cjs/src/api/device-action/os/ListApps/ListAppsDeviceAction.js.map +2 -2
- package/lib/cjs/src/api/device-action/os/OpenAppDeviceAction/OpenAppDeviceAction.js +1 -1
- package/lib/cjs/src/api/device-action/os/OpenAppDeviceAction/OpenAppDeviceAction.js.map +3 -3
- package/lib/cjs/src/api/device-action/os/OpenAppDeviceAction/OpenAppDeviceAction.test.js +1 -1
- package/lib/cjs/src/api/device-action/os/OpenAppDeviceAction/OpenAppDeviceAction.test.js.map +2 -2
- package/lib/cjs/src/api/device-action/os/OpenAppDeviceAction/types.js +1 -1
- package/lib/cjs/src/api/device-action/os/OpenAppDeviceAction/types.js.map +1 -1
- package/lib/cjs/src/api/device-action/os/OpenAppWithDependencies/OpenAppWithDependenciesDeviceAction.js +2 -0
- package/lib/cjs/src/api/device-action/os/OpenAppWithDependencies/OpenAppWithDependenciesDeviceAction.js.map +7 -0
- package/lib/cjs/src/api/device-action/os/OpenAppWithDependencies/OpenAppWithDependenciesDeviceAction.test.js +2 -0
- package/lib/cjs/src/api/device-action/os/OpenAppWithDependencies/OpenAppWithDependenciesDeviceAction.test.js.map +7 -0
- package/lib/cjs/src/api/device-action/os/OpenAppWithDependencies/types.js +2 -0
- package/lib/cjs/src/api/device-action/os/OpenAppWithDependencies/types.js.map +7 -0
- package/lib/cjs/src/api/device-action/os/SendCommandInAppDeviceAction/SendCommandInAppDeviceAction.js +1 -1
- package/lib/cjs/src/api/device-action/os/SendCommandInAppDeviceAction/SendCommandInAppDeviceAction.js.map +2 -2
- package/lib/cjs/src/api/device-action/os/SendCommandInAppDeviceAction/SendCommandInAppDeviceAction.test.js +1 -1
- package/lib/cjs/src/api/device-action/os/SendCommandInAppDeviceAction/SendCommandInAppDeviceAction.test.js.map +2 -2
- package/lib/cjs/src/api/device-action/os/SendCommandInAppDeviceAction/SendCommandInAppDeviceActionTypes.js +1 -1
- package/lib/cjs/src/api/device-action/os/SendCommandInAppDeviceAction/SendCommandInAppDeviceActionTypes.js.map +1 -1
- package/lib/cjs/src/api/device-action/task/BuildAppsInstallPlanTask.js +2 -0
- package/lib/cjs/src/api/device-action/task/BuildAppsInstallPlanTask.js.map +7 -0
- package/lib/cjs/src/api/device-action/task/BuildAppsInstallPlanTask.test.js +2 -0
- package/lib/cjs/src/api/device-action/task/BuildAppsInstallPlanTask.test.js.map +7 -0
- package/lib/cjs/src/api/device-action/task/GetApplicationsMetadataTask.js +2 -0
- package/lib/cjs/src/api/device-action/task/GetApplicationsMetadataTask.js.map +7 -0
- package/lib/cjs/src/api/device-action/task/GetApplicationsMetadataTask.test.js +2 -0
- package/lib/cjs/src/api/device-action/task/GetApplicationsMetadataTask.test.js.map +7 -0
- package/lib/cjs/src/api/device-action/task/GetFirmwareMetadataTask.js +2 -0
- package/lib/cjs/src/api/device-action/task/GetFirmwareMetadataTask.js.map +7 -0
- package/lib/cjs/src/api/device-action/task/GetFirmwareMetadataTask.test.js +2 -0
- package/lib/cjs/src/api/device-action/task/GetFirmwareMetadataTask.test.js.map +7 -0
- package/lib/cjs/src/api/device-action/task/PredictOutOfMemoryTask.js +2 -0
- package/lib/cjs/src/api/device-action/task/PredictOutOfMemoryTask.js.map +7 -0
- package/lib/cjs/src/api/device-action/task/PredictOutOfMemoryTask.test.js +2 -0
- package/lib/cjs/src/api/device-action/task/PredictOutOfMemoryTask.test.js.map +7 -0
- package/lib/cjs/src/api/device-model/data/StaticDeviceModelDataSource.js +1 -1
- package/lib/cjs/src/api/device-model/data/StaticDeviceModelDataSource.js.map +2 -2
- package/lib/cjs/src/api/device-model/data/StaticDeviceModelDataSource.test.js +1 -1
- package/lib/cjs/src/api/device-model/data/StaticDeviceModelDataSource.test.js.map +2 -2
- package/lib/cjs/src/api/device-model/model/DeviceModel.js +1 -1
- package/lib/cjs/src/api/device-model/model/DeviceModel.js.map +2 -2
- package/lib/cjs/src/api/device-model/model/DeviceModel.stub.js +1 -1
- package/lib/cjs/src/api/device-model/model/DeviceModel.stub.js.map +2 -2
- package/lib/cjs/src/api/device-session/DeviceSessionState.js +1 -1
- package/lib/cjs/src/api/device-session/DeviceSessionState.js.map +2 -2
- package/lib/cjs/src/api/index.js +1 -1
- package/lib/cjs/src/api/index.js.map +3 -3
- package/lib/cjs/src/api/secure-channel/device-action/GenuineCheck/GenuineCheckDeviceAction.js +1 -1
- package/lib/cjs/src/api/secure-channel/device-action/GenuineCheck/GenuineCheckDeviceAction.js.map +2 -2
- package/lib/cjs/src/api/secure-channel/device-action/GenuineCheck/types.js.map +1 -1
- package/lib/cjs/src/api/secure-channel/device-action/InstallApp/InstallAppDeviceAction.js +1 -1
- package/lib/cjs/src/api/secure-channel/device-action/InstallApp/InstallAppDeviceAction.js.map +3 -3
- package/lib/cjs/src/api/secure-channel/device-action/InstallApp/types.js +1 -1
- package/lib/cjs/src/api/secure-channel/device-action/InstallApp/types.js.map +1 -1
- package/lib/cjs/src/api/secure-channel/device-action/ListInstalledApps/ListInstalledAppsDeviceAction.js +1 -1
- package/lib/cjs/src/api/secure-channel/device-action/ListInstalledApps/ListInstalledAppsDeviceAction.js.map +2 -2
- package/lib/cjs/src/api/secure-channel/device-action/ListInstalledApps/types.js +1 -1
- package/lib/cjs/src/api/secure-channel/device-action/ListInstalledApps/types.js.map +2 -2
- package/lib/cjs/src/api/secure-channel/device-action/UninstallApp/UninstallAppDeviceAction.js +1 -1
- package/lib/cjs/src/api/secure-channel/device-action/UninstallApp/UninstallAppDeviceAction.js.map +3 -3
- package/lib/cjs/src/api/secure-channel/device-action/UninstallApp/types.js +1 -1
- package/lib/cjs/src/api/secure-channel/device-action/UninstallApp/types.js.map +1 -1
- package/lib/cjs/src/api/secure-channel/task/ConnectToSecureChannelTask.js +1 -1
- package/lib/cjs/src/api/secure-channel/task/ConnectToSecureChannelTask.js.map +3 -3
- package/lib/cjs/src/api/secure-channel/task/ConnectToSecureChannelTask.test.js +1 -1
- package/lib/cjs/src/api/secure-channel/task/ConnectToSecureChannelTask.test.js.map +3 -3
- package/lib/cjs/src/api/secure-channel/task/types.js +1 -1
- package/lib/cjs/src/api/secure-channel/task/types.js.map +2 -2
- package/lib/cjs/src/api/secure-channel/utils.js +1 -1
- package/lib/cjs/src/api/secure-channel/utils.js.map +3 -3
- package/lib/cjs/src/api/secure-channel/utils.test.js +1 -1
- package/lib/cjs/src/api/secure-channel/utils.test.js.map +3 -3
- package/lib/cjs/src/api/transport/model/DeviceApduSender.js +2 -0
- package/lib/cjs/src/api/transport/model/DeviceApduSender.js.map +7 -0
- package/lib/cjs/src/api/transport/model/DeviceConnection.js +1 -1
- package/lib/cjs/src/api/transport/model/DeviceConnection.js.map +1 -1
- package/lib/cjs/src/api/transport/model/DeviceConnectionStateMachine.js +2 -0
- package/lib/cjs/src/api/transport/model/DeviceConnectionStateMachine.js.map +7 -0
- package/lib/cjs/src/api/transport/model/DeviceConnectionStateMachine.test.js +2 -0
- package/lib/cjs/src/api/transport/model/DeviceConnectionStateMachine.test.js.map +7 -0
- package/lib/cjs/src/api/transport/model/DiscoveredDevice.js.map +1 -1
- package/lib/cjs/src/api/transport/model/Errors.js +1 -1
- package/lib/cjs/src/api/transport/model/Errors.js.map +3 -3
- package/lib/cjs/src/api/transport/model/Transport.js.map +1 -1
- package/lib/cjs/src/api/types.js +1 -1
- package/lib/cjs/src/api/types.js.map +1 -1
- package/lib/cjs/src/api/utils/AppName.js +2 -0
- package/lib/cjs/src/api/utils/AppName.js.map +7 -0
- package/lib/cjs/src/api/utils/AppName.test.js +2 -0
- package/lib/cjs/src/api/utils/AppName.test.js.map +7 -0
- package/lib/cjs/src/di.js +1 -1
- package/lib/cjs/src/di.js.map +2 -2
- package/lib/cjs/src/internal/config/di/configModule.js +1 -1
- package/lib/cjs/src/internal/config/di/configModule.js.map +3 -3
- package/lib/cjs/src/internal/config/di/configModule.test.js +1 -1
- package/lib/cjs/src/internal/config/di/configModule.test.js.map +2 -2
- package/lib/cjs/src/internal/device-model/di/deviceModelModule.js +1 -1
- package/lib/cjs/src/internal/device-model/di/deviceModelModule.js.map +3 -3
- package/lib/cjs/src/internal/device-model/di/deviceModelModule.test.js +1 -1
- package/lib/cjs/src/internal/device-model/di/deviceModelModule.test.js.map +2 -2
- package/lib/cjs/src/internal/device-session/data/ApduResponseConst.js +1 -1
- package/lib/cjs/src/internal/device-session/data/ApduResponseConst.js.map +3 -3
- package/lib/cjs/src/internal/device-session/di/deviceSessionModule.js +1 -1
- package/lib/cjs/src/internal/device-session/di/deviceSessionModule.js.map +3 -3
- package/lib/cjs/src/internal/device-session/di/deviceSessionModule.test.js +1 -1
- package/lib/cjs/src/internal/device-session/di/deviceSessionModule.test.js.map +2 -2
- package/lib/cjs/src/internal/device-session/model/DevicePinger.js +1 -1
- package/lib/cjs/src/internal/device-session/model/DevicePinger.js.map +3 -3
- package/lib/cjs/src/internal/device-session/model/DeviceSession.js +1 -1
- package/lib/cjs/src/internal/device-session/model/DeviceSession.js.map +3 -3
- package/lib/cjs/src/internal/device-session/model/DeviceSessionStateHandler.js +1 -1
- package/lib/cjs/src/internal/device-session/model/DeviceSessionStateHandler.js.map +3 -3
- package/lib/cjs/src/internal/device-session/model/DeviceSessionStateHandler.test.js +1 -1
- package/lib/cjs/src/internal/device-session/model/DeviceSessionStateHandler.test.js.map +3 -3
- package/lib/cjs/src/internal/device-session/model/Frame.js +1 -1
- package/lib/cjs/src/internal/device-session/model/Frame.js.map +3 -3
- package/lib/cjs/src/internal/device-session/service/DefaultApduSenderService.js +1 -1
- package/lib/cjs/src/internal/device-session/service/DefaultApduSenderService.js.map +2 -2
- package/lib/cjs/src/internal/device-session/service/DefaultApduSenderService.test.js +1 -1
- package/lib/cjs/src/internal/device-session/service/DefaultApduSenderService.test.js.map +2 -2
- package/lib/cjs/src/internal/device-session/use-case/CloseSessionsUseCase.js +1 -1
- package/lib/cjs/src/internal/device-session/use-case/CloseSessionsUseCase.js.map +3 -3
- package/lib/cjs/src/internal/device-session/use-case/CloseSessionsUseCase.test.js +1 -1
- package/lib/cjs/src/internal/device-session/use-case/CloseSessionsUseCase.test.js.map +3 -3
- package/lib/cjs/src/internal/discovery/di/discoveryModule.js +1 -1
- package/lib/cjs/src/internal/discovery/di/discoveryModule.js.map +3 -3
- package/lib/cjs/src/internal/discovery/di/discoveryModule.test.js +1 -1
- package/lib/cjs/src/internal/discovery/di/discoveryModule.test.js.map +2 -2
- package/lib/cjs/src/internal/discovery/use-case/DisconnectUseCase.test.js +1 -1
- package/lib/cjs/src/internal/discovery/use-case/DisconnectUseCase.test.js.map +2 -2
- package/lib/cjs/src/internal/discovery/use-case/ListenToAvailableDevicesUseCase.js +1 -1
- package/lib/cjs/src/internal/discovery/use-case/ListenToAvailableDevicesUseCase.js.map +2 -2
- package/lib/cjs/src/internal/discovery/use-case/StartDiscoveringUseCase.js +1 -1
- package/lib/cjs/src/internal/discovery/use-case/StartDiscoveringUseCase.js.map +2 -2
- package/lib/cjs/src/internal/discovery/use-case/StartDiscoveringUseCase.test.js +1 -1
- package/lib/cjs/src/internal/discovery/use-case/StartDiscoveringUseCase.test.js.map +2 -2
- package/lib/cjs/src/internal/discovery/use-case/StopDiscoveringUseCase.js +1 -1
- package/lib/cjs/src/internal/discovery/use-case/StopDiscoveringUseCase.js.map +3 -3
- package/lib/cjs/src/internal/discovery/use-case/StopDiscoveringUseCase.test.js +1 -1
- package/lib/cjs/src/internal/discovery/use-case/StopDiscoveringUseCase.test.js.map +3 -3
- package/lib/cjs/src/internal/logger-publisher/di/loggerModule.js +1 -1
- package/lib/cjs/src/internal/logger-publisher/di/loggerModule.js.map +3 -3
- package/lib/cjs/src/internal/logger-publisher/di/loggerModule.test.js +1 -1
- package/lib/cjs/src/internal/logger-publisher/di/loggerModule.test.js.map +2 -2
- package/lib/cjs/src/internal/manager-api/data/AxiosManagerApiDataSource.js +1 -1
- package/lib/cjs/src/internal/manager-api/data/AxiosManagerApiDataSource.js.map +3 -3
- package/lib/cjs/src/internal/manager-api/data/AxiosManagerApiDataSource.test.js +1 -1
- package/lib/cjs/src/internal/manager-api/data/AxiosManagerApiDataSource.test.js.map +3 -3
- package/lib/cjs/src/internal/manager-api/data/ManagerApiDataSource.js +1 -1
- package/lib/cjs/src/internal/manager-api/data/ManagerApiDataSource.js.map +1 -1
- package/lib/cjs/src/internal/manager-api/data/ManagerApiDto.js +1 -1
- package/lib/cjs/src/internal/manager-api/data/ManagerApiDto.js.map +1 -1
- package/lib/cjs/src/internal/manager-api/data/__mocks__/AxiosManagerApiDataSource.js +1 -1
- package/lib/cjs/src/internal/manager-api/data/__mocks__/AxiosManagerApiDataSource.js.map +2 -2
- package/lib/cjs/src/internal/manager-api/di/managerApiModule.js +1 -1
- package/lib/cjs/src/internal/manager-api/di/managerApiModule.js.map +3 -3
- package/lib/cjs/src/internal/manager-api/di/managerApiModule.test.js +1 -1
- package/lib/cjs/src/internal/manager-api/di/managerApiModule.test.js.map +2 -2
- package/lib/cjs/src/internal/manager-api/di/managerApiTypes.js +1 -1
- package/lib/cjs/src/internal/manager-api/di/managerApiTypes.js.map +2 -2
- package/lib/cjs/src/internal/manager-api/model/Application.js +1 -1
- package/lib/cjs/src/internal/manager-api/model/Application.js.map +1 -1
- package/lib/cjs/src/internal/manager-api/model/Const.js +1 -1
- package/lib/cjs/src/internal/manager-api/model/Const.js.map +3 -3
- package/lib/cjs/src/internal/manager-api/model/Firmware.js +1 -1
- package/lib/cjs/src/internal/manager-api/model/Firmware.js.map +1 -1
- package/lib/cjs/src/internal/manager-api/model/Language.js +2 -0
- package/lib/cjs/src/internal/manager-api/model/Language.js.map +7 -0
- package/lib/cjs/src/internal/manager-api/model/Params.js +1 -1
- package/lib/cjs/src/internal/manager-api/model/Params.js.map +1 -1
- package/lib/cjs/src/internal/manager-api/service/DefaultManagerApiService.js +1 -1
- package/lib/cjs/src/internal/manager-api/service/DefaultManagerApiService.js.map +3 -3
- package/lib/cjs/src/internal/manager-api/service/DefaultManagerApiService.test.js +1 -1
- package/lib/cjs/src/internal/manager-api/service/DefaultManagerApiService.test.js.map +3 -3
- package/lib/cjs/src/internal/manager-api/service/ManagerApiService.js +1 -1
- package/lib/cjs/src/internal/manager-api/service/ManagerApiService.js.map +1 -1
- package/lib/cjs/src/internal/manager-api/use-case/SetProviderUseCase.js +2 -0
- package/lib/cjs/src/internal/manager-api/use-case/SetProviderUseCase.js.map +7 -0
- package/lib/cjs/src/internal/manager-api/use-case/SetProviderUseCase.test.js +2 -0
- package/lib/cjs/src/internal/manager-api/use-case/SetProviderUseCase.test.js.map +7 -0
- package/lib/cjs/src/internal/secure-channel/di/secureChannelModule.js +1 -1
- package/lib/cjs/src/internal/secure-channel/di/secureChannelModule.js.map +3 -3
- package/lib/cjs/src/internal/secure-channel/di/secureChannelModule.test.js +1 -1
- package/lib/cjs/src/internal/secure-channel/di/secureChannelModule.test.js.map +2 -2
- package/lib/cjs/src/internal/secure-channel/model/Errors.js +1 -1
- package/lib/cjs/src/internal/secure-channel/model/Errors.js.map +3 -3
- package/lib/cjs/src/internal/secure-channel/service/DefaultSecureChannelService.js +1 -1
- package/lib/cjs/src/internal/secure-channel/service/DefaultSecureChannelService.js.map +3 -3
- package/lib/cjs/src/internal/secure-channel/service/DefaultSecureChannelService.test.js +1 -1
- package/lib/cjs/src/internal/secure-channel/service/DefaultSecureChannelService.test.js.map +3 -3
- package/lib/cjs/src/internal/secure-channel/service/SecureChannelService.js +1 -1
- package/lib/cjs/src/internal/secure-channel/service/SecureChannelService.js.map +1 -1
- package/lib/cjs/src/internal/send/di/sendModule.js +1 -1
- package/lib/cjs/src/internal/send/di/sendModule.js.map +3 -3
- package/lib/cjs/src/internal/send/di/sendModule.test.js +1 -1
- package/lib/cjs/src/internal/send/di/sendModule.test.js.map +2 -2
- package/lib/cjs/src/internal/send/use-case/SendApduUseCase.js +1 -1
- package/lib/cjs/src/internal/send/use-case/SendApduUseCase.js.map +3 -3
- package/lib/cjs/src/internal/transport/di/transportModule.js +1 -1
- package/lib/cjs/src/internal/transport/di/transportModule.js.map +3 -3
- package/lib/cjs/src/internal/transport/di/transportModule.test.js +1 -1
- package/lib/cjs/src/internal/transport/di/transportModule.test.js.map +2 -2
- package/lib/cjs/src/internal/transport/service/DefaultTransportService.js +1 -1
- package/lib/cjs/src/internal/transport/service/DefaultTransportService.js.map +3 -3
- package/lib/cjs/src/internal/transport/service/TransportService.js +1 -1
- package/lib/cjs/src/internal/transport/service/TransportService.js.map +1 -1
- package/lib/cjs/src/internal/transport/service/__mocks__/DefaultTransportService.js +1 -1
- package/lib/cjs/src/internal/transport/service/__mocks__/DefaultTransportService.js.map +2 -2
- package/lib/esm/package.json +22 -23
- package/lib/esm/src/api/DeviceManagementKit.js +1 -1
- package/lib/esm/src/api/DeviceManagementKit.js.map +3 -3
- package/lib/esm/src/api/DeviceManagementKit.test.js +1 -1
- package/lib/esm/src/api/DeviceManagementKit.test.js.map +3 -3
- package/lib/esm/src/api/DeviceManagementKitBuilder.js +1 -1
- package/lib/esm/src/api/DeviceManagementKitBuilder.js.map +3 -3
- package/lib/esm/src/api/apdu/utils/ByteArrayBuilder.js +1 -1
- package/lib/esm/src/api/apdu/utils/ByteArrayBuilder.js.map +3 -3
- package/lib/esm/src/api/apdu/utils/ByteArrayBuilder.test.js +1 -1
- package/lib/esm/src/api/apdu/utils/ByteArrayBuilder.test.js.map +2 -2
- package/lib/esm/src/api/apdu/utils/ByteArrayParser.js +1 -1
- package/lib/esm/src/api/apdu/utils/ByteArrayParser.js.map +3 -3
- package/lib/esm/src/api/command/di/commandModule.js +1 -1
- package/lib/esm/src/api/command/di/commandModule.js.map +3 -3
- package/lib/esm/src/api/command/di/commandModule.test.js +1 -1
- package/lib/esm/src/api/command/di/commandModule.test.js.map +2 -2
- package/lib/esm/src/api/command/os/GetCustomImageSizeCommand.js +2 -0
- package/lib/esm/src/api/command/os/GetCustomImageSizeCommand.js.map +7 -0
- package/lib/esm/src/api/command/os/GetCustomImageSizeCommand.test.js +2 -0
- package/lib/esm/src/api/command/os/GetCustomImageSizeCommand.test.js.map +7 -0
- package/lib/esm/src/api/command/os/GetOsVersionCommand.js +1 -1
- package/lib/esm/src/api/command/os/GetOsVersionCommand.js.map +3 -3
- package/lib/esm/src/api/command/os/GetOsVersionCommand.test.js +1 -1
- package/lib/esm/src/api/command/os/GetOsVersionCommand.test.js.map +3 -3
- package/lib/esm/src/api/command/os/ListLanguagePackCommand.js +2 -0
- package/lib/esm/src/api/command/os/ListLanguagePackCommand.js.map +7 -0
- package/lib/esm/src/api/command/os/ListLanguagePackCommand.test.js +2 -0
- package/lib/esm/src/api/command/os/ListLanguagePackCommand.test.js.map +7 -0
- package/lib/esm/src/api/command/os/__mocks__/GetOsVersionCommand.js +1 -1
- package/lib/esm/src/api/command/os/__mocks__/GetOsVersionCommand.js.map +2 -2
- package/lib/esm/src/api/command/use-case/SendCommandUseCase.js +1 -1
- package/lib/esm/src/api/command/use-case/SendCommandUseCase.js.map +3 -3
- package/lib/esm/src/api/command/utils/CommandUtils.js +1 -1
- package/lib/esm/src/api/command/utils/CommandUtils.js.map +3 -3
- package/lib/esm/src/api/command/utils/CommandUtils.test.js +1 -1
- package/lib/esm/src/api/command/utils/CommandUtils.test.js.map +3 -3
- package/lib/esm/src/api/command/utils/GlobalCommandError.js +1 -1
- package/lib/esm/src/api/command/utils/GlobalCommandError.js.map +2 -2
- package/lib/esm/src/api/device/DeviceModel.js +1 -1
- package/lib/esm/src/api/device/DeviceModel.js.map +2 -2
- package/lib/esm/src/api/device-action/__test-utils__/makeInternalApi.js +1 -1
- package/lib/esm/src/api/device-action/__test-utils__/makeInternalApi.js.map +3 -3
- package/lib/esm/src/api/device-action/__test-utils__/setupTestMachine.js +1 -1
- package/lib/esm/src/api/device-action/__test-utils__/setupTestMachine.js.map +3 -3
- package/lib/esm/src/api/device-action/di/deviceActionModule.js +1 -1
- package/lib/esm/src/api/device-action/di/deviceActionModule.js.map +3 -3
- package/lib/esm/src/api/device-action/di/deviceActionModule.test.js +1 -1
- package/lib/esm/src/api/device-action/di/deviceActionModule.test.js.map +2 -2
- package/lib/esm/src/api/device-action/model/UserInteractionRequired.js +1 -1
- package/lib/esm/src/api/device-action/model/UserInteractionRequired.js.map +2 -2
- package/lib/esm/src/api/device-action/os/CallTaskInAppDeviceAction/CallTaskInAppDeviceAction.js +1 -1
- package/lib/esm/src/api/device-action/os/CallTaskInAppDeviceAction/CallTaskInAppDeviceAction.js.map +2 -2
- package/lib/esm/src/api/device-action/os/CallTaskInAppDeviceAction/CallTaskInAppDeviceAction.test.js +1 -1
- package/lib/esm/src/api/device-action/os/CallTaskInAppDeviceAction/CallTaskInAppDeviceAction.test.js.map +2 -2
- package/lib/esm/src/api/device-action/os/Errors.js +1 -1
- package/lib/esm/src/api/device-action/os/Errors.js.map +3 -3
- package/lib/esm/src/api/device-action/os/GetDeviceMetadata/GetDeviceMetadataDeviceAction.js +2 -0
- package/lib/esm/src/api/device-action/os/GetDeviceMetadata/GetDeviceMetadataDeviceAction.js.map +7 -0
- package/lib/esm/src/api/device-action/os/GetDeviceMetadata/GetDeviceMetadataDeviceAction.test.js +2 -0
- package/lib/esm/src/api/device-action/os/GetDeviceMetadata/GetDeviceMetadataDeviceAction.test.js.map +7 -0
- package/lib/esm/src/api/device-action/os/GetDeviceMetadata/types.js +1 -0
- package/lib/esm/src/api/device-action/os/GetDeviceMetadata/types.js.map +7 -0
- package/lib/esm/src/api/device-action/os/GetDeviceStatus/GetDeviceStatusDeviceAction.js +1 -1
- package/lib/esm/src/api/device-action/os/GetDeviceStatus/GetDeviceStatusDeviceAction.js.map +2 -2
- package/lib/esm/src/api/device-action/os/GetDeviceStatus/GetDeviceStatusDeviceAction.test.js +1 -1
- package/lib/esm/src/api/device-action/os/GetDeviceStatus/GetDeviceStatusDeviceAction.test.js.map +2 -2
- package/lib/esm/src/api/device-action/os/GoToDashboard/GoToDashboardDeviceAction.js +1 -1
- package/lib/esm/src/api/device-action/os/GoToDashboard/GoToDashboardDeviceAction.js.map +3 -3
- package/lib/esm/src/api/device-action/os/InstallOrUpdateApps/InstallOrUpdateAppsDeviceAction.js +2 -0
- package/lib/esm/src/api/device-action/os/InstallOrUpdateApps/InstallOrUpdateAppsDeviceAction.js.map +7 -0
- package/lib/esm/src/api/device-action/os/InstallOrUpdateApps/InstallOrUpdateAppsDeviceAction.test.js +2 -0
- package/lib/esm/src/api/device-action/os/InstallOrUpdateApps/InstallOrUpdateAppsDeviceAction.test.js.map +7 -0
- package/lib/esm/src/api/device-action/os/InstallOrUpdateApps/types.js +1 -0
- package/lib/esm/src/api/device-action/os/InstallOrUpdateApps/types.js.map +7 -0
- package/lib/esm/src/api/device-action/os/ListApps/ListAppsDeviceAction.js +1 -1
- package/lib/esm/src/api/device-action/os/ListApps/ListAppsDeviceAction.js.map +2 -2
- package/lib/esm/src/api/device-action/os/OpenAppDeviceAction/OpenAppDeviceAction.js +1 -1
- package/lib/esm/src/api/device-action/os/OpenAppDeviceAction/OpenAppDeviceAction.js.map +3 -3
- package/lib/esm/src/api/device-action/os/OpenAppDeviceAction/OpenAppDeviceAction.test.js +1 -1
- package/lib/esm/src/api/device-action/os/OpenAppDeviceAction/OpenAppDeviceAction.test.js.map +3 -3
- package/lib/esm/src/api/device-action/os/OpenAppWithDependencies/OpenAppWithDependenciesDeviceAction.js +2 -0
- package/lib/esm/src/api/device-action/os/OpenAppWithDependencies/OpenAppWithDependenciesDeviceAction.js.map +7 -0
- package/lib/esm/src/api/device-action/os/OpenAppWithDependencies/OpenAppWithDependenciesDeviceAction.test.js +2 -0
- package/lib/esm/src/api/device-action/os/OpenAppWithDependencies/OpenAppWithDependenciesDeviceAction.test.js.map +7 -0
- package/lib/esm/src/api/device-action/os/OpenAppWithDependencies/types.js +1 -0
- package/lib/esm/src/api/device-action/os/OpenAppWithDependencies/types.js.map +7 -0
- package/lib/esm/src/api/device-action/os/SendCommandInAppDeviceAction/SendCommandInAppDeviceAction.js +1 -1
- package/lib/esm/src/api/device-action/os/SendCommandInAppDeviceAction/SendCommandInAppDeviceAction.js.map +2 -2
- package/lib/esm/src/api/device-action/os/SendCommandInAppDeviceAction/SendCommandInAppDeviceAction.test.js +1 -1
- package/lib/esm/src/api/device-action/os/SendCommandInAppDeviceAction/SendCommandInAppDeviceAction.test.js.map +2 -2
- package/lib/esm/src/api/device-action/task/BuildAppsInstallPlanTask.js +2 -0
- package/lib/esm/src/api/device-action/task/BuildAppsInstallPlanTask.js.map +7 -0
- package/lib/esm/src/api/device-action/task/BuildAppsInstallPlanTask.test.js +2 -0
- package/lib/esm/src/api/device-action/task/BuildAppsInstallPlanTask.test.js.map +7 -0
- package/lib/esm/src/api/device-action/task/GetApplicationsMetadataTask.js +2 -0
- package/lib/esm/src/api/device-action/task/GetApplicationsMetadataTask.js.map +7 -0
- package/lib/esm/src/api/device-action/task/GetApplicationsMetadataTask.test.js +2 -0
- package/lib/esm/src/api/device-action/task/GetApplicationsMetadataTask.test.js.map +7 -0
- package/lib/esm/src/api/device-action/task/GetFirmwareMetadataTask.js +2 -0
- package/lib/esm/src/api/device-action/task/GetFirmwareMetadataTask.js.map +7 -0
- package/lib/esm/src/api/device-action/task/GetFirmwareMetadataTask.test.js +2 -0
- package/lib/esm/src/api/device-action/task/GetFirmwareMetadataTask.test.js.map +7 -0
- package/lib/esm/src/api/device-action/task/PredictOutOfMemoryTask.js +2 -0
- package/lib/esm/src/api/device-action/task/PredictOutOfMemoryTask.js.map +7 -0
- package/lib/esm/src/api/device-action/task/PredictOutOfMemoryTask.test.js +2 -0
- package/lib/esm/src/api/device-action/task/PredictOutOfMemoryTask.test.js.map +7 -0
- package/lib/esm/src/api/device-model/data/StaticDeviceModelDataSource.js +1 -1
- package/lib/esm/src/api/device-model/data/StaticDeviceModelDataSource.js.map +2 -2
- package/lib/esm/src/api/device-model/data/StaticDeviceModelDataSource.test.js +1 -1
- package/lib/esm/src/api/device-model/data/StaticDeviceModelDataSource.test.js.map +2 -2
- package/lib/esm/src/api/device-model/model/DeviceModel.js +1 -1
- package/lib/esm/src/api/device-model/model/DeviceModel.js.map +2 -2
- package/lib/esm/src/api/device-model/model/DeviceModel.stub.js +1 -1
- package/lib/esm/src/api/device-model/model/DeviceModel.stub.js.map +2 -2
- package/lib/esm/src/api/device-session/DeviceSessionState.js +1 -1
- package/lib/esm/src/api/device-session/DeviceSessionState.js.map +2 -2
- package/lib/esm/src/api/index.js +1 -1
- package/lib/esm/src/api/index.js.map +3 -3
- package/lib/esm/src/api/secure-channel/device-action/GenuineCheck/GenuineCheckDeviceAction.js +1 -1
- package/lib/esm/src/api/secure-channel/device-action/GenuineCheck/GenuineCheckDeviceAction.js.map +2 -2
- package/lib/esm/src/api/secure-channel/device-action/InstallApp/InstallAppDeviceAction.js +1 -1
- package/lib/esm/src/api/secure-channel/device-action/InstallApp/InstallAppDeviceAction.js.map +3 -3
- package/lib/esm/src/api/secure-channel/device-action/ListInstalledApps/ListInstalledAppsDeviceAction.js +1 -1
- package/lib/esm/src/api/secure-channel/device-action/ListInstalledApps/ListInstalledAppsDeviceAction.js.map +2 -2
- package/lib/esm/src/api/secure-channel/device-action/ListInstalledApps/types.js +1 -1
- package/lib/esm/src/api/secure-channel/device-action/ListInstalledApps/types.js.map +2 -2
- package/lib/esm/src/api/secure-channel/device-action/UninstallApp/UninstallAppDeviceAction.js +1 -1
- package/lib/esm/src/api/secure-channel/device-action/UninstallApp/UninstallAppDeviceAction.js.map +3 -3
- package/lib/esm/src/api/secure-channel/task/ConnectToSecureChannelTask.js +1 -1
- package/lib/esm/src/api/secure-channel/task/ConnectToSecureChannelTask.js.map +3 -3
- package/lib/esm/src/api/secure-channel/task/ConnectToSecureChannelTask.test.js +1 -1
- package/lib/esm/src/api/secure-channel/task/ConnectToSecureChannelTask.test.js.map +3 -3
- package/lib/esm/src/api/secure-channel/task/types.js +1 -1
- package/lib/esm/src/api/secure-channel/task/types.js.map +2 -2
- package/lib/esm/src/api/secure-channel/utils.js +1 -1
- package/lib/esm/src/api/secure-channel/utils.js.map +3 -3
- package/lib/esm/src/api/secure-channel/utils.test.js +1 -1
- package/lib/esm/src/api/secure-channel/utils.test.js.map +3 -3
- package/lib/esm/src/api/transport/model/DeviceApduSender.js +1 -0
- package/lib/esm/src/api/transport/model/DeviceApduSender.js.map +7 -0
- package/lib/esm/src/api/transport/model/DeviceConnectionStateMachine.js +2 -0
- package/lib/esm/src/api/transport/model/DeviceConnectionStateMachine.js.map +7 -0
- package/lib/esm/src/api/transport/model/DeviceConnectionStateMachine.test.js +2 -0
- package/lib/esm/src/api/transport/model/DeviceConnectionStateMachine.test.js.map +7 -0
- package/lib/esm/src/api/transport/model/Errors.js +1 -1
- package/lib/esm/src/api/transport/model/Errors.js.map +3 -3
- package/lib/esm/src/api/utils/AppName.js +2 -0
- package/lib/esm/src/api/utils/AppName.js.map +7 -0
- package/lib/esm/src/api/utils/AppName.test.js +2 -0
- package/lib/esm/src/api/utils/AppName.test.js.map +7 -0
- package/lib/esm/src/di.js +1 -1
- package/lib/esm/src/di.js.map +3 -3
- package/lib/esm/src/internal/config/di/configModule.js +1 -1
- package/lib/esm/src/internal/config/di/configModule.js.map +3 -3
- package/lib/esm/src/internal/config/di/configModule.test.js +1 -1
- package/lib/esm/src/internal/config/di/configModule.test.js.map +2 -2
- package/lib/esm/src/internal/device-model/di/deviceModelModule.js +1 -1
- package/lib/esm/src/internal/device-model/di/deviceModelModule.js.map +3 -3
- package/lib/esm/src/internal/device-model/di/deviceModelModule.test.js +1 -1
- package/lib/esm/src/internal/device-model/di/deviceModelModule.test.js.map +2 -2
- package/lib/esm/src/internal/device-session/data/ApduResponseConst.js +1 -1
- package/lib/esm/src/internal/device-session/data/ApduResponseConst.js.map +3 -3
- package/lib/esm/src/internal/device-session/di/deviceSessionModule.js +1 -1
- package/lib/esm/src/internal/device-session/di/deviceSessionModule.js.map +3 -3
- package/lib/esm/src/internal/device-session/di/deviceSessionModule.test.js +1 -1
- package/lib/esm/src/internal/device-session/di/deviceSessionModule.test.js.map +2 -2
- package/lib/esm/src/internal/device-session/model/DevicePinger.js +1 -1
- package/lib/esm/src/internal/device-session/model/DevicePinger.js.map +3 -3
- package/lib/esm/src/internal/device-session/model/DeviceSession.js +1 -1
- package/lib/esm/src/internal/device-session/model/DeviceSession.js.map +3 -3
- package/lib/esm/src/internal/device-session/model/DeviceSessionStateHandler.js +1 -1
- package/lib/esm/src/internal/device-session/model/DeviceSessionStateHandler.js.map +3 -3
- package/lib/esm/src/internal/device-session/model/DeviceSessionStateHandler.test.js +1 -1
- package/lib/esm/src/internal/device-session/model/DeviceSessionStateHandler.test.js.map +3 -3
- package/lib/esm/src/internal/device-session/model/Frame.js +1 -1
- package/lib/esm/src/internal/device-session/model/Frame.js.map +3 -3
- package/lib/esm/src/internal/device-session/service/DefaultApduSenderService.js +1 -1
- package/lib/esm/src/internal/device-session/service/DefaultApduSenderService.js.map +2 -2
- package/lib/esm/src/internal/device-session/service/DefaultApduSenderService.test.js +1 -1
- package/lib/esm/src/internal/device-session/service/DefaultApduSenderService.test.js.map +2 -2
- package/lib/esm/src/internal/device-session/use-case/CloseSessionsUseCase.js +1 -1
- package/lib/esm/src/internal/device-session/use-case/CloseSessionsUseCase.js.map +3 -3
- package/lib/esm/src/internal/device-session/use-case/CloseSessionsUseCase.test.js +1 -1
- package/lib/esm/src/internal/device-session/use-case/CloseSessionsUseCase.test.js.map +3 -3
- package/lib/esm/src/internal/discovery/di/discoveryModule.js +1 -1
- package/lib/esm/src/internal/discovery/di/discoveryModule.js.map +3 -3
- package/lib/esm/src/internal/discovery/di/discoveryModule.test.js +1 -1
- package/lib/esm/src/internal/discovery/di/discoveryModule.test.js.map +2 -2
- package/lib/esm/src/internal/discovery/use-case/DisconnectUseCase.test.js +1 -1
- package/lib/esm/src/internal/discovery/use-case/DisconnectUseCase.test.js.map +2 -2
- package/lib/esm/src/internal/discovery/use-case/ListenToAvailableDevicesUseCase.js +1 -1
- package/lib/esm/src/internal/discovery/use-case/ListenToAvailableDevicesUseCase.js.map +2 -2
- package/lib/esm/src/internal/discovery/use-case/StartDiscoveringUseCase.js +1 -1
- package/lib/esm/src/internal/discovery/use-case/StartDiscoveringUseCase.js.map +2 -2
- package/lib/esm/src/internal/discovery/use-case/StartDiscoveringUseCase.test.js +1 -1
- package/lib/esm/src/internal/discovery/use-case/StartDiscoveringUseCase.test.js.map +2 -2
- package/lib/esm/src/internal/discovery/use-case/StopDiscoveringUseCase.js +1 -1
- package/lib/esm/src/internal/discovery/use-case/StopDiscoveringUseCase.js.map +3 -3
- package/lib/esm/src/internal/discovery/use-case/StopDiscoveringUseCase.test.js +1 -1
- package/lib/esm/src/internal/discovery/use-case/StopDiscoveringUseCase.test.js.map +3 -3
- package/lib/esm/src/internal/logger-publisher/di/loggerModule.js +1 -1
- package/lib/esm/src/internal/logger-publisher/di/loggerModule.js.map +3 -3
- package/lib/esm/src/internal/logger-publisher/di/loggerModule.test.js +1 -1
- package/lib/esm/src/internal/logger-publisher/di/loggerModule.test.js.map +2 -2
- package/lib/esm/src/internal/manager-api/data/AxiosManagerApiDataSource.js +1 -1
- package/lib/esm/src/internal/manager-api/data/AxiosManagerApiDataSource.js.map +3 -3
- package/lib/esm/src/internal/manager-api/data/AxiosManagerApiDataSource.test.js +1 -1
- package/lib/esm/src/internal/manager-api/data/AxiosManagerApiDataSource.test.js.map +3 -3
- package/lib/esm/src/internal/manager-api/data/ManagerApiDto.js +1 -1
- package/lib/esm/src/internal/manager-api/data/ManagerApiDto.js.map +1 -1
- package/lib/esm/src/internal/manager-api/data/__mocks__/AxiosManagerApiDataSource.js +1 -1
- package/lib/esm/src/internal/manager-api/data/__mocks__/AxiosManagerApiDataSource.js.map +2 -2
- package/lib/esm/src/internal/manager-api/di/managerApiModule.js +1 -1
- package/lib/esm/src/internal/manager-api/di/managerApiModule.js.map +3 -3
- package/lib/esm/src/internal/manager-api/di/managerApiModule.test.js +1 -1
- package/lib/esm/src/internal/manager-api/di/managerApiModule.test.js.map +2 -2
- package/lib/esm/src/internal/manager-api/di/managerApiTypes.js +1 -1
- package/lib/esm/src/internal/manager-api/di/managerApiTypes.js.map +2 -2
- package/lib/esm/src/internal/manager-api/model/Application.js +1 -1
- package/lib/esm/src/internal/manager-api/model/Application.js.map +1 -1
- package/lib/esm/src/internal/manager-api/model/Const.js +1 -1
- package/lib/esm/src/internal/manager-api/model/Const.js.map +3 -3
- package/lib/esm/src/internal/manager-api/model/Language.js +1 -0
- package/lib/esm/src/internal/manager-api/model/Language.js.map +7 -0
- package/lib/esm/src/internal/manager-api/service/DefaultManagerApiService.js +1 -1
- package/lib/esm/src/internal/manager-api/service/DefaultManagerApiService.js.map +3 -3
- package/lib/esm/src/internal/manager-api/service/DefaultManagerApiService.test.js +1 -1
- package/lib/esm/src/internal/manager-api/service/DefaultManagerApiService.test.js.map +3 -3
- package/lib/esm/src/internal/manager-api/use-case/SetProviderUseCase.js +2 -0
- package/lib/esm/src/internal/manager-api/use-case/SetProviderUseCase.js.map +7 -0
- package/lib/esm/src/internal/manager-api/use-case/SetProviderUseCase.test.js +2 -0
- package/lib/esm/src/internal/manager-api/use-case/SetProviderUseCase.test.js.map +7 -0
- package/lib/esm/src/internal/secure-channel/di/secureChannelModule.js +1 -1
- package/lib/esm/src/internal/secure-channel/di/secureChannelModule.js.map +3 -3
- package/lib/esm/src/internal/secure-channel/di/secureChannelModule.test.js +1 -1
- package/lib/esm/src/internal/secure-channel/di/secureChannelModule.test.js.map +2 -2
- package/lib/esm/src/internal/secure-channel/model/Errors.js +1 -1
- package/lib/esm/src/internal/secure-channel/model/Errors.js.map +3 -3
- package/lib/esm/src/internal/secure-channel/service/DefaultSecureChannelService.js.map +3 -3
- package/lib/esm/src/internal/secure-channel/service/DefaultSecureChannelService.test.js +1 -1
- package/lib/esm/src/internal/secure-channel/service/DefaultSecureChannelService.test.js.map +3 -3
- package/lib/esm/src/internal/send/di/sendModule.js +1 -1
- package/lib/esm/src/internal/send/di/sendModule.js.map +3 -3
- package/lib/esm/src/internal/send/di/sendModule.test.js +1 -1
- package/lib/esm/src/internal/send/di/sendModule.test.js.map +2 -2
- package/lib/esm/src/internal/send/use-case/SendApduUseCase.js +1 -1
- package/lib/esm/src/internal/send/use-case/SendApduUseCase.js.map +3 -3
- package/lib/esm/src/internal/transport/di/transportModule.js +1 -1
- package/lib/esm/src/internal/transport/di/transportModule.js.map +3 -3
- package/lib/esm/src/internal/transport/di/transportModule.test.js +1 -1
- package/lib/esm/src/internal/transport/di/transportModule.test.js.map +2 -2
- package/lib/esm/src/internal/transport/service/DefaultTransportService.js +1 -1
- package/lib/esm/src/internal/transport/service/DefaultTransportService.js.map +3 -3
- package/lib/esm/src/internal/transport/service/__mocks__/DefaultTransportService.js +1 -1
- package/lib/esm/src/internal/transport/service/__mocks__/DefaultTransportService.js.map +2 -2
- package/lib/types/src/api/DeviceManagementKit.d.ts +11 -1
- package/lib/types/src/api/DeviceManagementKit.d.ts.map +1 -1
- package/lib/types/src/api/DeviceManagementKitBuilder.d.ts.map +1 -1
- package/lib/types/src/api/DmkConfig.d.ts +2 -0
- package/lib/types/src/api/DmkConfig.d.ts.map +1 -1
- package/lib/types/src/api/apdu/utils/ApduBuilder.d.ts.map +1 -1
- package/lib/types/src/api/apdu/utils/ApduParser.d.ts.map +1 -1
- package/lib/types/src/api/apdu/utils/ByteArrayBuilder.d.ts +28 -0
- package/lib/types/src/api/apdu/utils/ByteArrayBuilder.d.ts.map +1 -1
- package/lib/types/src/api/apdu/utils/ByteArrayParser.d.ts +1 -0
- package/lib/types/src/api/apdu/utils/ByteArrayParser.d.ts.map +1 -1
- package/lib/types/src/api/command/di/commandModule.d.ts.map +1 -1
- package/lib/types/src/api/command/os/GetCustomImageSizeCommand.d.ts +16 -0
- package/lib/types/src/api/command/os/GetCustomImageSizeCommand.d.ts.map +1 -0
- package/lib/types/src/api/command/os/GetCustomImageSizeCommand.test.d.ts +2 -0
- package/lib/types/src/api/command/os/GetCustomImageSizeCommand.test.d.ts.map +1 -0
- package/lib/types/src/api/command/os/GetOsVersionCommand.d.ts +30 -2
- package/lib/types/src/api/command/os/GetOsVersionCommand.d.ts.map +1 -1
- package/lib/types/src/api/command/os/ListLanguagePackCommand.d.ts +24 -0
- package/lib/types/src/api/command/os/ListLanguagePackCommand.d.ts.map +1 -0
- package/lib/types/src/api/command/os/ListLanguagePackCommand.test.d.ts +2 -0
- package/lib/types/src/api/command/os/ListLanguagePackCommand.test.d.ts.map +1 -0
- package/lib/types/src/api/command/os/__mocks__/GetOsVersionCommand.d.ts.map +1 -1
- package/lib/types/src/api/command/use-case/SendCommandUseCase.d.ts +5 -1
- package/lib/types/src/api/command/use-case/SendCommandUseCase.d.ts.map +1 -1
- package/lib/types/src/api/command/utils/CommandErrors.d.ts.map +1 -1
- package/lib/types/src/api/command/utils/CommandUtils.d.ts +4 -0
- package/lib/types/src/api/command/utils/CommandUtils.d.ts.map +1 -1
- package/lib/types/src/api/command/utils/GlobalCommandError.d.ts +1 -1
- package/lib/types/src/api/command/utils/GlobalCommandError.d.ts.map +1 -1
- package/lib/types/src/api/device/DeviceModel.d.ts +2 -1
- package/lib/types/src/api/device/DeviceModel.d.ts.map +1 -1
- package/lib/types/src/api/device-action/DeviceAction.d.ts +3 -1
- package/lib/types/src/api/device-action/DeviceAction.d.ts.map +1 -1
- package/lib/types/src/api/device-action/__test-utils__/makeInternalApi.d.ts.map +1 -1
- package/lib/types/src/api/device-action/__test-utils__/setupTestMachine.d.ts +5 -0
- package/lib/types/src/api/device-action/__test-utils__/setupTestMachine.d.ts.map +1 -1
- package/lib/types/src/api/device-action/di/deviceActionModule.d.ts.map +1 -1
- package/lib/types/src/api/device-action/model/UserInteractionRequired.d.ts +1 -0
- package/lib/types/src/api/device-action/model/UserInteractionRequired.d.ts.map +1 -1
- package/lib/types/src/api/device-action/os/CallTaskInAppDeviceAction/CallTaskInAppDeviceAction.d.ts.map +1 -1
- package/lib/types/src/api/device-action/os/CallTaskInAppDeviceAction/CallTaskInAppDeviceActionTypes.d.ts +1 -1
- package/lib/types/src/api/device-action/os/CallTaskInAppDeviceAction/CallTaskInAppDeviceActionTypes.d.ts.map +1 -1
- package/lib/types/src/api/device-action/os/Errors.d.ts +20 -0
- package/lib/types/src/api/device-action/os/Errors.d.ts.map +1 -1
- package/lib/types/src/api/device-action/os/GetDeviceMetadata/GetDeviceMetadataDeviceAction.d.ts +58 -0
- package/lib/types/src/api/device-action/os/GetDeviceMetadata/GetDeviceMetadataDeviceAction.d.ts.map +1 -0
- package/lib/types/src/api/device-action/os/GetDeviceMetadata/GetDeviceMetadataDeviceAction.test.d.ts +2 -0
- package/lib/types/src/api/device-action/os/GetDeviceMetadata/GetDeviceMetadataDeviceAction.test.d.ts.map +1 -0
- package/lib/types/src/api/device-action/os/GetDeviceMetadata/types.d.ts +28 -0
- package/lib/types/src/api/device-action/os/GetDeviceMetadata/types.d.ts.map +1 -0
- package/lib/types/src/api/device-action/os/GetDeviceStatus/GetDeviceStatusDeviceAction.d.ts.map +1 -1
- package/lib/types/src/api/device-action/os/GoToDashboard/GoToDashboardDeviceAction.d.ts.map +1 -1
- package/lib/types/src/api/device-action/os/GoToDashboard/types.d.ts +3 -4
- package/lib/types/src/api/device-action/os/GoToDashboard/types.d.ts.map +1 -1
- package/lib/types/src/api/device-action/os/InstallOrUpdateApps/InstallOrUpdateAppsDeviceAction.d.ts +40 -0
- package/lib/types/src/api/device-action/os/InstallOrUpdateApps/InstallOrUpdateAppsDeviceAction.d.ts.map +1 -0
- package/lib/types/src/api/device-action/os/InstallOrUpdateApps/InstallOrUpdateAppsDeviceAction.test.d.ts +2 -0
- package/lib/types/src/api/device-action/os/InstallOrUpdateApps/InstallOrUpdateAppsDeviceAction.test.d.ts.map +1 -0
- package/lib/types/src/api/device-action/os/InstallOrUpdateApps/types.d.ts +65 -0
- package/lib/types/src/api/device-action/os/InstallOrUpdateApps/types.d.ts.map +1 -0
- package/lib/types/src/api/device-action/os/OpenAppDeviceAction/OpenAppDeviceAction.d.ts.map +1 -1
- package/lib/types/src/api/device-action/os/OpenAppDeviceAction/types.d.ts +0 -1
- package/lib/types/src/api/device-action/os/OpenAppDeviceAction/types.d.ts.map +1 -1
- package/lib/types/src/api/device-action/os/OpenAppWithDependencies/OpenAppWithDependenciesDeviceAction.d.ts +15 -0
- package/lib/types/src/api/device-action/os/OpenAppWithDependencies/OpenAppWithDependenciesDeviceAction.d.ts.map +1 -0
- package/lib/types/src/api/device-action/os/OpenAppWithDependencies/OpenAppWithDependenciesDeviceAction.test.d.ts +2 -0
- package/lib/types/src/api/device-action/os/OpenAppWithDependencies/OpenAppWithDependenciesDeviceAction.test.d.ts.map +1 -0
- package/lib/types/src/api/device-action/os/OpenAppWithDependencies/types.d.ts +24 -0
- package/lib/types/src/api/device-action/os/OpenAppWithDependencies/types.d.ts.map +1 -0
- package/lib/types/src/api/device-action/os/SendCommandInAppDeviceAction/SendCommandInAppDeviceAction.d.ts.map +1 -1
- package/lib/types/src/api/device-action/os/SendCommandInAppDeviceAction/SendCommandInAppDeviceActionTypes.d.ts +1 -1
- package/lib/types/src/api/device-action/os/SendCommandInAppDeviceAction/SendCommandInAppDeviceActionTypes.d.ts.map +1 -1
- package/lib/types/src/api/device-action/task/BuildAppsInstallPlanTask.d.ts +30 -0
- package/lib/types/src/api/device-action/task/BuildAppsInstallPlanTask.d.ts.map +1 -0
- package/lib/types/src/api/device-action/task/BuildAppsInstallPlanTask.test.d.ts +2 -0
- package/lib/types/src/api/device-action/task/BuildAppsInstallPlanTask.test.d.ts.map +1 -0
- package/lib/types/src/api/device-action/task/GetApplicationsMetadataTask.d.ts +31 -0
- package/lib/types/src/api/device-action/task/GetApplicationsMetadataTask.d.ts.map +1 -0
- package/lib/types/src/api/device-action/task/GetApplicationsMetadataTask.test.d.ts +2 -0
- package/lib/types/src/api/device-action/task/GetApplicationsMetadataTask.test.d.ts.map +1 -0
- package/lib/types/src/api/device-action/task/GetFirmwareMetadataTask.d.ts +18 -0
- package/lib/types/src/api/device-action/task/GetFirmwareMetadataTask.d.ts.map +1 -0
- package/lib/types/src/api/device-action/task/GetFirmwareMetadataTask.test.d.ts +2 -0
- package/lib/types/src/api/device-action/task/GetFirmwareMetadataTask.test.d.ts.map +1 -0
- package/lib/types/src/api/device-action/task/PredictOutOfMemoryTask.d.ts +21 -0
- package/lib/types/src/api/device-action/task/PredictOutOfMemoryTask.d.ts.map +1 -0
- package/lib/types/src/api/device-action/task/PredictOutOfMemoryTask.test.d.ts +2 -0
- package/lib/types/src/api/device-action/task/PredictOutOfMemoryTask.test.d.ts.map +1 -0
- package/lib/types/src/api/device-model/data/StaticDeviceModelDataSource.d.ts.map +1 -1
- package/lib/types/src/api/device-model/model/DeviceModel.d.ts +2 -0
- package/lib/types/src/api/device-model/model/DeviceModel.d.ts.map +1 -1
- package/lib/types/src/api/device-model/model/DeviceModel.stub.d.ts.map +1 -1
- package/lib/types/src/api/device-session/DeviceSessionState.d.ts +93 -0
- package/lib/types/src/api/device-session/DeviceSessionState.d.ts.map +1 -1
- package/lib/types/src/api/device-session/service/DefaultApduReceiverService.stub.d.ts.map +1 -1
- package/lib/types/src/api/device-session/service/DefaultApduSenderService.stub.d.ts.map +1 -1
- package/lib/types/src/api/index.d.ts +6 -1
- package/lib/types/src/api/index.d.ts.map +1 -1
- package/lib/types/src/api/secure-channel/device-action/GenuineCheck/GenuineCheckDeviceAction.d.ts.map +1 -1
- package/lib/types/src/api/secure-channel/device-action/GenuineCheck/types.d.ts +2 -1
- package/lib/types/src/api/secure-channel/device-action/GenuineCheck/types.d.ts.map +1 -1
- package/lib/types/src/api/secure-channel/device-action/InstallApp/InstallAppDeviceAction.d.ts.map +1 -1
- package/lib/types/src/api/secure-channel/device-action/InstallApp/types.d.ts +2 -1
- package/lib/types/src/api/secure-channel/device-action/InstallApp/types.d.ts.map +1 -1
- package/lib/types/src/api/secure-channel/device-action/ListInstalledApps/ListInstalledAppsDeviceAction.d.ts.map +1 -1
- package/lib/types/src/api/secure-channel/device-action/ListInstalledApps/types.d.ts +2 -1
- package/lib/types/src/api/secure-channel/device-action/ListInstalledApps/types.d.ts.map +1 -1
- package/lib/types/src/api/secure-channel/device-action/UninstallApp/UninstallAppDeviceAction.d.ts.map +1 -1
- package/lib/types/src/api/secure-channel/device-action/UninstallApp/types.d.ts +2 -1
- package/lib/types/src/api/secure-channel/device-action/UninstallApp/types.d.ts.map +1 -1
- package/lib/types/src/api/secure-channel/task/ConnectToSecureChannelTask.d.ts +5 -2
- package/lib/types/src/api/secure-channel/task/ConnectToSecureChannelTask.d.ts.map +1 -1
- package/lib/types/src/api/secure-channel/task/types.d.ts +6 -1
- package/lib/types/src/api/secure-channel/task/types.d.ts.map +1 -1
- package/lib/types/src/api/secure-channel/utils.d.ts +0 -11
- package/lib/types/src/api/secure-channel/utils.d.ts.map +1 -1
- package/lib/types/src/api/transport/model/DeviceApduSender.d.ts +17 -0
- package/lib/types/src/api/transport/model/DeviceApduSender.d.ts.map +1 -0
- package/lib/types/src/api/transport/model/DeviceConnection.d.ts +2 -1
- package/lib/types/src/api/transport/model/DeviceConnection.d.ts.map +1 -1
- package/lib/types/src/api/transport/model/DeviceConnectionStateMachine.d.ts +63 -0
- package/lib/types/src/api/transport/model/DeviceConnectionStateMachine.d.ts.map +1 -0
- package/lib/types/src/api/transport/model/DeviceConnectionStateMachine.test.d.ts +2 -0
- package/lib/types/src/api/transport/model/DeviceConnectionStateMachine.test.d.ts.map +1 -0
- package/lib/types/src/api/transport/model/DiscoveredDevice.d.ts +1 -1
- package/lib/types/src/api/transport/model/DiscoveredDevice.d.ts.map +1 -1
- package/lib/types/src/api/transport/model/Errors.d.ts +27 -3
- package/lib/types/src/api/transport/model/Errors.d.ts.map +1 -1
- package/lib/types/src/api/transport/model/Transport.d.ts +1 -1
- package/lib/types/src/api/transport/model/Transport.d.ts.map +1 -1
- package/lib/types/src/api/types.d.ts +6 -2
- package/lib/types/src/api/types.d.ts.map +1 -1
- package/lib/types/src/api/utils/AppName.d.ts +2 -0
- package/lib/types/src/api/utils/AppName.d.ts.map +1 -0
- package/lib/types/src/api/utils/AppName.test.d.ts +2 -0
- package/lib/types/src/api/utils/AppName.test.d.ts.map +1 -0
- package/lib/types/src/api/utils/HexaString.d.ts.map +1 -1
- package/lib/types/src/di.d.ts.map +1 -1
- package/lib/types/src/internal/config/di/configModule.d.ts.map +1 -1
- package/lib/types/src/internal/device-model/di/deviceModelModule.d.ts.map +1 -1
- package/lib/types/src/internal/device-session/data/ApduResponseConst.d.ts +1 -0
- package/lib/types/src/internal/device-session/data/ApduResponseConst.d.ts.map +1 -1
- package/lib/types/src/internal/device-session/di/deviceSessionModule.d.ts.map +1 -1
- package/lib/types/src/internal/device-session/model/DevicePinger.d.ts +1 -1
- package/lib/types/src/internal/device-session/model/DevicePinger.d.ts.map +1 -1
- package/lib/types/src/internal/device-session/model/DeviceSession.d.ts +3 -1
- package/lib/types/src/internal/device-session/model/DeviceSession.d.ts.map +1 -1
- package/lib/types/src/internal/device-session/model/DeviceSession.stub.d.ts.map +1 -1
- package/lib/types/src/internal/device-session/model/DeviceSessionStateHandler.d.ts.map +1 -1
- package/lib/types/src/internal/device-session/model/Frame.d.ts.map +1 -1
- package/lib/types/src/internal/device-session/use-case/CloseSessionsUseCase.d.ts +3 -1
- package/lib/types/src/internal/device-session/use-case/CloseSessionsUseCase.d.ts.map +1 -1
- package/lib/types/src/internal/device-session/utils/deviceSessionUtils.d.ts.map +1 -1
- package/lib/types/src/internal/discovery/di/discoveryModule.d.ts.map +1 -1
- package/lib/types/src/internal/discovery/use-case/ListenToAvailableDevicesUseCase.d.ts +1 -1
- package/lib/types/src/internal/discovery/use-case/ListenToAvailableDevicesUseCase.d.ts.map +1 -1
- package/lib/types/src/internal/discovery/use-case/StartDiscoveringUseCase.d.ts +1 -1
- package/lib/types/src/internal/discovery/use-case/StartDiscoveringUseCase.d.ts.map +1 -1
- package/lib/types/src/internal/discovery/use-case/StopDiscoveringUseCase.d.ts +4 -2
- package/lib/types/src/internal/discovery/use-case/StopDiscoveringUseCase.d.ts.map +1 -1
- package/lib/types/src/internal/logger-publisher/di/loggerModule.d.ts.map +1 -1
- package/lib/types/src/internal/manager-api/data/AxiosManagerApiDataSource.d.ts +24 -5
- package/lib/types/src/internal/manager-api/data/AxiosManagerApiDataSource.d.ts.map +1 -1
- package/lib/types/src/internal/manager-api/data/ManagerApiDataSource.d.ts +51 -6
- package/lib/types/src/internal/manager-api/data/ManagerApiDataSource.d.ts.map +1 -1
- package/lib/types/src/internal/manager-api/data/ManagerApiDto.d.ts +104 -18
- package/lib/types/src/internal/manager-api/data/ManagerApiDto.d.ts.map +1 -1
- package/lib/types/src/internal/manager-api/data/__mocks__/AxiosManagerApiDataSource.d.ts +7 -0
- package/lib/types/src/internal/manager-api/data/__mocks__/AxiosManagerApiDataSource.d.ts.map +1 -1
- package/lib/types/src/internal/manager-api/di/managerApiModule.d.ts.map +1 -1
- package/lib/types/src/internal/manager-api/di/managerApiTypes.d.ts +1 -0
- package/lib/types/src/internal/manager-api/di/managerApiTypes.d.ts.map +1 -1
- package/lib/types/src/internal/manager-api/model/Application.d.ts +12 -12
- package/lib/types/src/internal/manager-api/model/Application.d.ts.map +1 -1
- package/lib/types/src/internal/manager-api/model/Const.d.ts +2 -0
- package/lib/types/src/internal/manager-api/model/Const.d.ts.map +1 -1
- package/lib/types/src/internal/manager-api/model/Firmware.d.ts +17 -3
- package/lib/types/src/internal/manager-api/model/Firmware.d.ts.map +1 -1
- package/lib/types/src/internal/manager-api/model/Language.d.ts +12 -0
- package/lib/types/src/internal/manager-api/model/Language.d.ts.map +1 -0
- package/lib/types/src/internal/manager-api/model/Params.d.ts +20 -6
- package/lib/types/src/internal/manager-api/model/Params.d.ts.map +1 -1
- package/lib/types/src/internal/manager-api/service/DefaultManagerApiService.d.ts +9 -3
- package/lib/types/src/internal/manager-api/service/DefaultManagerApiService.d.ts.map +1 -1
- package/lib/types/src/internal/manager-api/service/ManagerApiService.d.ts +42 -7
- package/lib/types/src/internal/manager-api/service/ManagerApiService.d.ts.map +1 -1
- package/lib/types/src/internal/manager-api/use-case/SetProviderUseCase.d.ts +13 -0
- package/lib/types/src/internal/manager-api/use-case/SetProviderUseCase.d.ts.map +1 -0
- package/lib/types/src/internal/manager-api/use-case/SetProviderUseCase.test.d.ts +2 -0
- package/lib/types/src/internal/manager-api/use-case/SetProviderUseCase.test.d.ts.map +1 -0
- package/lib/types/src/internal/secure-channel/di/secureChannelModule.d.ts.map +1 -1
- package/lib/types/src/internal/secure-channel/model/Errors.d.ts +22 -2
- package/lib/types/src/internal/secure-channel/model/Errors.d.ts.map +1 -1
- package/lib/types/src/internal/secure-channel/service/DefaultSecureChannelService.d.ts +2 -2
- package/lib/types/src/internal/secure-channel/service/DefaultSecureChannelService.d.ts.map +1 -1
- package/lib/types/src/internal/secure-channel/service/SecureChannelService.d.ts +3 -3
- package/lib/types/src/internal/secure-channel/service/SecureChannelService.d.ts.map +1 -1
- package/lib/types/src/internal/send/di/sendModule.d.ts.map +1 -1
- package/lib/types/src/internal/send/use-case/SendApduUseCase.d.ts +9 -1
- package/lib/types/src/internal/send/use-case/SendApduUseCase.d.ts.map +1 -1
- package/lib/types/src/internal/transport/di/transportModule.d.ts.map +1 -1
- package/lib/types/src/internal/transport/service/DefaultTransportService.d.ts +2 -0
- package/lib/types/src/internal/transport/service/DefaultTransportService.d.ts.map +1 -1
- package/lib/types/src/internal/transport/service/TransportService.d.ts +3 -1
- package/lib/types/src/internal/transport/service/TransportService.d.ts.map +1 -1
- package/lib/types/src/internal/transport/service/__mocks__/DefaultTransportService.d.ts +1 -0
- package/lib/types/src/internal/transport/service/__mocks__/DefaultTransportService.d.ts.map +1 -1
- package/lib/types/tsconfig.prod.tsbuildinfo +1 -1
- package/package.json +14 -15
@@ -0,0 +1,2 @@
|
|
1
|
+
import{Left as p,Right as n}from"purify-ts/Either";import{afterEach as U,beforeEach as w,describe as m,expect as e,it as c,vi as i}from"vitest";import{ApduResponse as x}from"../../device-session/ApduResponse";import{DeviceConnectionStateMachine as D}from"./DeviceConnectionStateMachine";import{AlreadySendingApduError as y,DeviceDisconnectedWhileSendingError as f}from"./Errors";m("DeviceConnectionStateMachine",()=>{let d;const s={sendApdu:i.fn(),getDependencies:i.fn(),setDependencies:i.fn(),closeConnection:i.fn(),setupConnection:i.fn()},t=new x({statusCode:Uint8Array.from([144,0]),data:new Uint8Array}),v=new x({statusCode:Uint8Array.from([102,1]),data:new Uint8Array});w(()=>{i.useFakeTimers(),d=new D({deviceId:"deviceId",deviceApduSender:s,timeoutDuration:1e3,tryToReconnect:i.fn(),onTerminated:i.fn()})}),U(()=>{i.useRealTimers(),i.restoreAllMocks()}),m("Send APDUs",()=>{c("should send APDU successfully",async()=>{const o=Uint8Array.from([1,2,3,4]);s.sendApdu.mockResolvedValue(n(t));const a=await d.sendApdu(o);e(s.sendApdu).toHaveBeenCalledTimes(1),e(a).toStrictEqual(n(t))}),c("should send several APDUs successfully",async()=>{const o=Uint8Array.from([1,2,3,4]),a=Uint8Array.from([9,2,3,4]);s.sendApdu.mockResolvedValue(n(t));const r=await d.sendApdu(o),u=await d.sendApdu(a);e(s.sendApdu).toHaveBeenCalledTimes(2),e(r).toStrictEqual(n(t)),e(u).toStrictEqual(n(t))}),c("should not send several APDUs in parallel",async()=>{const o=Uint8Array.from([1,2,3,4]),a=Uint8Array.from([9,2,3,4]);s.sendApdu.mockResolvedValue(n(t));const r=d.sendApdu(o),u=await d.sendApdu(a),l=await r;e(s.sendApdu).toHaveBeenCalledTimes(1),e(l).toStrictEqual(n(t)),e(u).toStrictEqual(p(new y))}),c("Disconnected while sending APDU",async()=>{const o=Uint8Array.from([1,2,3,4]);s.sendApdu.mockResolvedValue(n(t));const a=d.sendApdu(o);d.eventDeviceDisconnected();const r=await a;e(s.sendApdu).toHaveBeenCalledTimes(1),e(r).toStrictEqual(p(new f))}),c("Request disconnection while sending APDU",async()=>{const o=Uint8Array.from([1,2,3,4]);s.sendApdu.mockResolvedValue(n(t));const a=d.sendApdu(o);d.closeConnection();const r=await a;e(s.sendApdu).toHaveBeenCalledTimes(1),e(r).toStrictEqual(p(new f))})}),m("Send APDUs triggering disconnection",()=>{c("should send one APDU successfully",async()=>{const o=Uint8Array.from([1,2,3,4]);s.sendApdu.mockResolvedValue(n(t));const a=await d.sendApdu(o,!0);e(s.sendApdu).toHaveBeenCalledTimes(2),e(s.sendApdu.mock.calls).toEqual([[o,!1,void 0],[Uint8Array.from([176,1,0,0,0]),!1,void 0]]),e(a).toStrictEqual(n(t))}),c("should send several APDUs successfully",async()=>{const o=Uint8Array.from([1,2,3,4]),a=Uint8Array.from([9,2,3,4]);s.sendApdu.mockResolvedValueOnce(n(t)).mockRejectedValueOnce(new Error("Transport error")).mockResolvedValueOnce(n(t));const r=d.sendApdu(o,!0);await Promise.resolve(),d.eventDeviceDisconnected(),d.eventDeviceConnected();const u=d.sendApdu(a),l=await r,A=await u;e(s.sendApdu).toHaveBeenCalledTimes(3),e(s.sendApdu.mock.calls).toEqual([[o,!1,void 0],[Uint8Array.from([176,1,0,0,0]),!1,void 0],[a,!1,void 0]]),e(l).toStrictEqual(n(t)),e(A).toStrictEqual(n(t))}),c("should send a second APDU after reconnection",async()=>{const o=Uint8Array.from([1,2,3,4]),a=Uint8Array.from([9,2,3,4]);s.sendApdu.mockResolvedValueOnce(n(t)).mockRejectedValueOnce(new Error("Transport error")).mockResolvedValueOnce(n(t));const r=await d.sendApdu(o,!0);d.eventDeviceDisconnected(),d.eventDeviceConnected();const u=await d.sendApdu(a);e(s.sendApdu).toHaveBeenCalledTimes(3),e(s.sendApdu.mock.calls).toEqual([[o,!1,void 0],[Uint8Array.from([176,1,0,0,0]),!1,void 0],[a,!1,void 0]]),e(r).toStrictEqual(n(t)),e(u).toStrictEqual(n(t))}),c("should send a second APDU without reconnection, after GetAppAndVersion response",async()=>{const o=Uint8Array.from([1,2,3,4]),a=Uint8Array.from([9,2,3,4]);s.sendApdu.mockResolvedValueOnce(n(t)).mockResolvedValueOnce(n(t)).mockResolvedValueOnce(n(t));const r=await d.sendApdu(o,!0),u=await d.sendApdu(a);e(s.sendApdu).toHaveBeenCalledTimes(3),e(s.sendApdu.mock.calls).toEqual([[o,!1,void 0],[Uint8Array.from([176,1,0,0,0]),!1,void 0],[a,!1,void 0]]),e(r).toStrictEqual(n(t)),e(u).toStrictEqual(n(t))}),c("should send a second APDU without reconnection, after GetAppAndVersion retries",async()=>{const o=Uint8Array.from([1,2,3,4]),a=Uint8Array.from([9,2,3,4]);s.sendApdu.mockResolvedValueOnce(n(t)).mockResolvedValueOnce(n(v)).mockResolvedValueOnce(n(v)).mockResolvedValueOnce(n(t)).mockResolvedValueOnce(n(t));const r=await d.sendApdu(o,!0),u=await d.sendApdu(a);e(s.sendApdu).toHaveBeenCalledTimes(5),e(s.sendApdu.mock.calls).toEqual([[o,!1,void 0],[Uint8Array.from([176,1,0,0,0]),!1,void 0],[Uint8Array.from([176,1,0,0,0]),!1,void 0],[Uint8Array.from([176,1,0,0,0]),!1,void 0],[a,!1,void 0]]),e(r).toStrictEqual(n(t)),e(u).toStrictEqual(n(t))}),c("should not send several APDUs in parallel",async()=>{const o=Uint8Array.from([1,2,3,4]),a=Uint8Array.from([9,2,3,4]);s.sendApdu.mockResolvedValue(n(t));const r=d.sendApdu(o,!0),u=await d.sendApdu(a),l=await r;e(s.sendApdu).toHaveBeenCalledTimes(2),e(s.sendApdu.mock.calls).toEqual([[o,!1,void 0],[Uint8Array.from([176,1,0,0,0]),!1,void 0]]),e(l).toStrictEqual(n(t)),e(u).toStrictEqual(p(new y))}),c("should send another APDU in promise handler",async()=>{const o=Uint8Array.from([1,2,3,4]),a=Uint8Array.from([9,2,3,4]);s.sendApdu.mockResolvedValue(n(t));let r;const u=await d.sendApdu(o,!0).then(A=>(r=d.sendApdu(a),A));d.eventDeviceDisconnected(),d.eventDeviceConnected();const l=await r;e(s.sendApdu).toHaveBeenCalledTimes(3),e(s.sendApdu.mock.calls).toEqual([[o,!1,void 0],[Uint8Array.from([176,1,0,0,0]),!1,void 0],[a,!1,void 0]]),e(u).toStrictEqual(n(t)),e(l).toStrictEqual(n(t))}),c("send an APDU while device is reconnecting",async()=>{const o=Uint8Array.from([1,2,3,4]);s.sendApdu.mockResolvedValue(n(t)),d.eventDeviceDisconnected();const a=d.sendApdu(o,!0);d.eventDeviceConnected();const r=await a;e(s.sendApdu).toHaveBeenCalledTimes(2),e(s.sendApdu.mock.calls).toEqual([[o,!1,void 0],[Uint8Array.from([176,1,0,0,0]),!1,void 0]]),e(r).toStrictEqual(n(t))}),c("Close while an APDU is waiting for reconnection",async()=>{const o=Uint8Array.from([1,2,3,4]),a=Uint8Array.from([9,2,3,4]);s.sendApdu.mockResolvedValue(n(t));let r;const u=d.sendApdu(o,!0);await Promise.resolve(),d.eventDeviceDisconnected();const l=await u;r=d.sendApdu(a),d.closeConnection();const A=await r;e(s.sendApdu.mock.calls).toEqual([[o,!1,void 0],[Uint8Array.from([176,1,0,0,0]),!1,void 0]]),e(l).toStrictEqual(n(t)),e(A).toStrictEqual(p(new f))})})});
|
2
|
+
//# sourceMappingURL=DeviceConnectionStateMachine.test.js.map
|
@@ -0,0 +1,7 @@
|
|
1
|
+
{
|
2
|
+
"version": 3,
|
3
|
+
"sources": ["../../../../../../src/api/transport/model/DeviceConnectionStateMachine.test.ts"],
|
4
|
+
"sourcesContent": ["import { Left, Right } from \"purify-ts/Either\";\nimport { afterEach, beforeEach, describe, expect, it, vi } from \"vitest\";\n\nimport { ApduResponse } from \"@api/device-session/ApduResponse\";\n\nimport { type SendApduResult } from \"./DeviceConnection\";\nimport { DeviceConnectionStateMachine } from \"./DeviceConnectionStateMachine\";\nimport {\n AlreadySendingApduError,\n DeviceDisconnectedWhileSendingError,\n} from \"./Errors\";\n\ndescribe(\"DeviceConnectionStateMachine\", () => {\n let machine: DeviceConnectionStateMachine<void>;\n const mockApduSender = {\n sendApdu: vi.fn(),\n getDependencies: vi.fn(),\n setDependencies: vi.fn(),\n closeConnection: vi.fn(),\n setupConnection: vi.fn(),\n };\n\n const apduResponse = new ApduResponse({\n statusCode: Uint8Array.from([0x90, 0x00]),\n data: new Uint8Array(),\n });\n const apduResponseErrorBusy = new ApduResponse({\n statusCode: Uint8Array.from([0x66, 0x01]),\n data: new Uint8Array(),\n });\n\n beforeEach(() => {\n vi.useFakeTimers();\n machine = new DeviceConnectionStateMachine<void>({\n deviceId: \"deviceId\",\n deviceApduSender: mockApduSender,\n timeoutDuration: 1000,\n tryToReconnect: vi.fn(),\n onTerminated: vi.fn(),\n });\n });\n\n afterEach(() => {\n vi.useRealTimers();\n vi.restoreAllMocks();\n });\n\n describe(\"Send APDUs\", () => {\n it(\"should send APDU successfully\", async () => {\n // GIVEN\n const apdu = Uint8Array.from([1, 2, 3, 4]);\n mockApduSender.sendApdu.mockResolvedValue(Right(apduResponse));\n\n // WHEN\n const result = await machine.sendApdu(apdu);\n\n // THEN\n expect(mockApduSender.sendApdu).toHaveBeenCalledTimes(1);\n expect(result).toStrictEqual(Right(apduResponse));\n });\n\n it(\"should send several APDUs successfully\", async () => {\n // GIVEN\n const apdu = Uint8Array.from([1, 2, 3, 4]);\n const apdu2 = Uint8Array.from([9, 2, 3, 4]);\n mockApduSender.sendApdu.mockResolvedValue(Right(apduResponse));\n\n // WHEN\n const result = await machine.sendApdu(apdu);\n const result2 = await machine.sendApdu(apdu2);\n\n // THEN\n expect(mockApduSender.sendApdu).toHaveBeenCalledTimes(2);\n expect(result).toStrictEqual(Right(apduResponse));\n expect(result2).toStrictEqual(Right(apduResponse));\n });\n\n it(\"should not send several APDUs in parallel\", async () => {\n // GIVEN\n const apdu = Uint8Array.from([1, 2, 3, 4]);\n const apdu2 = Uint8Array.from([9, 2, 3, 4]);\n mockApduSender.sendApdu.mockResolvedValue(Right(apduResponse));\n\n // WHEN\n const promise = machine.sendApdu(apdu);\n const result2 = await machine.sendApdu(apdu2);\n const result = await promise;\n\n // THEN\n expect(mockApduSender.sendApdu).toHaveBeenCalledTimes(1);\n expect(result).toStrictEqual(Right(apduResponse));\n expect(result2).toStrictEqual(Left(new AlreadySendingApduError()));\n });\n\n it(\"Disconnected while sending APDU\", async () => {\n // GIVEN\n const apdu = Uint8Array.from([1, 2, 3, 4]);\n mockApduSender.sendApdu.mockResolvedValue(Right(apduResponse));\n\n // WHEN\n const promise = machine.sendApdu(apdu);\n machine.eventDeviceDisconnected();\n const result = await promise;\n\n // THEN\n expect(mockApduSender.sendApdu).toHaveBeenCalledTimes(1);\n expect(result).toStrictEqual(\n Left(new DeviceDisconnectedWhileSendingError()),\n );\n });\n\n it(\"Request disconnection while sending APDU\", async () => {\n // GIVEN\n const apdu = Uint8Array.from([1, 2, 3, 4]);\n mockApduSender.sendApdu.mockResolvedValue(Right(apduResponse));\n\n // WHEN\n const promise = machine.sendApdu(apdu);\n machine.closeConnection();\n const result = await promise;\n\n // THEN\n expect(mockApduSender.sendApdu).toHaveBeenCalledTimes(1);\n expect(result).toStrictEqual(\n Left(new DeviceDisconnectedWhileSendingError()),\n );\n });\n });\n\n describe(\"Send APDUs triggering disconnection\", () => {\n it(\"should send one APDU successfully\", async () => {\n // GIVEN\n const apdu = Uint8Array.from([1, 2, 3, 4]);\n mockApduSender.sendApdu.mockResolvedValue(Right(apduResponse));\n\n // WHEN\n const result = await machine.sendApdu(apdu, true);\n\n // THEN\n expect(mockApduSender.sendApdu).toHaveBeenCalledTimes(2);\n expect(mockApduSender.sendApdu.mock.calls).toEqual([\n [apdu, false, undefined],\n [Uint8Array.from([0xb0, 0x01, 0x00, 0x00, 0x00]), false, undefined], // GetAppAndVersion APDU sent after a successful result from an APDU that triggers disconnection\n ]);\n expect(result).toStrictEqual(Right(apduResponse));\n });\n\n it(\"should send several APDUs successfully\", async () => {\n // GIVEN\n const apdu = Uint8Array.from([1, 2, 3, 4]);\n const apdu2 = Uint8Array.from([9, 2, 3, 4]);\n mockApduSender.sendApdu\n .mockResolvedValueOnce(Right(apduResponse))\n .mockRejectedValueOnce(new Error(\"Transport error\"))\n .mockResolvedValueOnce(Right(apduResponse));\n\n // WHEN\n const promise1 = machine.sendApdu(apdu, true);\n await Promise.resolve(); // Allow the first APDU to be sent and processed before the disconnection event\n machine.eventDeviceDisconnected();\n machine.eventDeviceConnected();\n const promise2 = machine.sendApdu(apdu2);\n const result1 = await promise1;\n const result2 = await promise2;\n\n // THEN\n expect(mockApduSender.sendApdu).toHaveBeenCalledTimes(3);\n expect(mockApduSender.sendApdu.mock.calls).toEqual([\n [apdu, false, undefined],\n [Uint8Array.from([0xb0, 0x01, 0x00, 0x00, 0x00]), false, undefined], // GetAppAndVersion APDU sent after a successful result from an APDU that triggers disconnection\n [apdu2, false, undefined],\n ]);\n\n expect(result1).toStrictEqual(Right(apduResponse));\n expect(result2).toStrictEqual(Right(apduResponse));\n });\n\n it(\"should send a second APDU after reconnection\", async () => {\n // GIVEN\n const apdu = Uint8Array.from([1, 2, 3, 4]);\n const apdu2 = Uint8Array.from([9, 2, 3, 4]);\n mockApduSender.sendApdu\n .mockResolvedValueOnce(Right(apduResponse))\n .mockRejectedValueOnce(new Error(\"Transport error\"))\n .mockResolvedValueOnce(Right(apduResponse));\n\n // WHEN\n const result = await machine.sendApdu(apdu, true);\n machine.eventDeviceDisconnected();\n machine.eventDeviceConnected();\n const result2 = await machine.sendApdu(apdu2);\n\n // THEN\n expect(mockApduSender.sendApdu).toHaveBeenCalledTimes(3);\n expect(mockApduSender.sendApdu.mock.calls).toEqual([\n [apdu, false, undefined],\n [Uint8Array.from([0xb0, 0x01, 0x00, 0x00, 0x00]), false, undefined], // GetAppAndVersion APDU sent after a successful result from an APDU that triggers disconnection\n [apdu2, false, undefined],\n ]);\n expect(result).toStrictEqual(Right(apduResponse));\n expect(result2).toStrictEqual(Right(apduResponse));\n });\n\n it(\"should send a second APDU without reconnection, after GetAppAndVersion response\", async () => {\n // GIVEN\n const apdu = Uint8Array.from([1, 2, 3, 4]);\n const apdu2 = Uint8Array.from([9, 2, 3, 4]);\n mockApduSender.sendApdu\n .mockResolvedValueOnce(Right(apduResponse))\n .mockResolvedValueOnce(Right(apduResponse))\n .mockResolvedValueOnce(Right(apduResponse));\n\n // WHEN\n const result = await machine.sendApdu(apdu, true);\n const result2 = await machine.sendApdu(apdu2);\n\n // THEN\n expect(mockApduSender.sendApdu).toHaveBeenCalledTimes(3);\n expect(mockApduSender.sendApdu.mock.calls).toEqual([\n [apdu, false, undefined],\n [Uint8Array.from([0xb0, 0x01, 0x00, 0x00, 0x00]), false, undefined], // GetAppAndVersion APDU sent after a successful result from an APDU that triggers disconnection\n [apdu2, false, undefined],\n ]);\n expect(result).toStrictEqual(Right(apduResponse));\n expect(result2).toStrictEqual(Right(apduResponse));\n });\n\n it(\"should send a second APDU without reconnection, after GetAppAndVersion retries\", async () => {\n // GIVEN\n const apdu = Uint8Array.from([1, 2, 3, 4]);\n const apdu2 = Uint8Array.from([9, 2, 3, 4]);\n mockApduSender.sendApdu\n .mockResolvedValueOnce(Right(apduResponse))\n .mockResolvedValueOnce(Right(apduResponseErrorBusy))\n .mockResolvedValueOnce(Right(apduResponseErrorBusy))\n .mockResolvedValueOnce(Right(apduResponse))\n .mockResolvedValueOnce(Right(apduResponse));\n\n // WHEN\n const result = await machine.sendApdu(apdu, true);\n const result2 = await machine.sendApdu(apdu2);\n\n // THEN\n expect(mockApduSender.sendApdu).toHaveBeenCalledTimes(5);\n expect(mockApduSender.sendApdu.mock.calls).toEqual([\n [apdu, false, undefined],\n [Uint8Array.from([0xb0, 0x01, 0x00, 0x00, 0x00]), false, undefined],\n [Uint8Array.from([0xb0, 0x01, 0x00, 0x00, 0x00]), false, undefined],\n [Uint8Array.from([0xb0, 0x01, 0x00, 0x00, 0x00]), false, undefined],\n [apdu2, false, undefined],\n ]);\n expect(result).toStrictEqual(Right(apduResponse));\n expect(result2).toStrictEqual(Right(apduResponse));\n });\n\n it(\"should not send several APDUs in parallel\", async () => {\n // GIVEN\n const apdu = Uint8Array.from([1, 2, 3, 4]);\n const apdu2 = Uint8Array.from([9, 2, 3, 4]);\n mockApduSender.sendApdu.mockResolvedValue(Right(apduResponse));\n\n // WHEN\n const promise = machine.sendApdu(apdu, true);\n const result2 = await machine.sendApdu(apdu2);\n const result = await promise;\n\n // THEN\n expect(mockApduSender.sendApdu).toHaveBeenCalledTimes(2);\n expect(mockApduSender.sendApdu.mock.calls).toEqual([\n [apdu, false, undefined],\n [Uint8Array.from([0xb0, 0x01, 0x00, 0x00, 0x00]), false, undefined], // GetAppAndVersion APDU sent after a successful result from an APDU that triggers disconnection\n ]);\n expect(result).toStrictEqual(Right(apduResponse));\n expect(result2).toStrictEqual(Left(new AlreadySendingApduError()));\n });\n\n it(\"should send another APDU in promise handler\", async () => {\n // GIVEN\n const apdu = Uint8Array.from([1, 2, 3, 4]);\n const apdu2 = Uint8Array.from([9, 2, 3, 4]);\n mockApduSender.sendApdu.mockResolvedValue(Right(apduResponse));\n\n // WHEN\n let promise: Promise<SendApduResult> | undefined = undefined;\n const result = await machine.sendApdu(apdu, true).then((value) => {\n promise = machine.sendApdu(apdu2);\n return value;\n });\n machine.eventDeviceDisconnected();\n machine.eventDeviceConnected();\n const result2 = await promise!;\n\n // THEN\n expect(mockApduSender.sendApdu).toHaveBeenCalledTimes(3);\n expect(mockApduSender.sendApdu.mock.calls).toEqual([\n [apdu, false, undefined],\n [Uint8Array.from([0xb0, 0x01, 0x00, 0x00, 0x00]), false, undefined], // GetAppAndVersion APDU sent after a successful result from an APDU that triggers disconnection\n [apdu2, false, undefined],\n ]);\n expect(result).toStrictEqual(Right(apduResponse));\n expect(result2).toStrictEqual(Right(apduResponse));\n });\n\n it(\"send an APDU while device is reconnecting\", async () => {\n // GIVEN\n const apdu = Uint8Array.from([1, 2, 3, 4]);\n mockApduSender.sendApdu.mockResolvedValue(Right(apduResponse));\n\n // WHEN\n machine.eventDeviceDisconnected();\n const promise = machine.sendApdu(apdu, true);\n machine.eventDeviceConnected();\n const result = await promise;\n\n // THEN\n expect(mockApduSender.sendApdu).toHaveBeenCalledTimes(2);\n expect(mockApduSender.sendApdu.mock.calls).toEqual([\n [apdu, false, undefined],\n [Uint8Array.from([0xb0, 0x01, 0x00, 0x00, 0x00]), false, undefined], // GetAppAndVersion APDU sent after a successful result from an APDU that triggers disconnection\n ]);\n expect(result).toStrictEqual(Right(apduResponse));\n });\n\n it(\"Close while an APDU is waiting for reconnection\", async () => {\n // GIVEN\n const apdu = Uint8Array.from([1, 2, 3, 4]);\n const apdu2 = Uint8Array.from([9, 2, 3, 4]);\n mockApduSender.sendApdu.mockResolvedValue(Right(apduResponse));\n\n // WHEN\n let promise: Promise<SendApduResult> | undefined = undefined;\n const promise1 = machine.sendApdu(apdu, true);\n await Promise.resolve(); // Allow the first APDU promise to resolve before triggering disconnection\n machine.eventDeviceDisconnected();\n const result1 = await promise1;\n promise = machine.sendApdu(apdu2);\n machine.closeConnection();\n const result2 = await promise!;\n\n // THEN\n // expect(mockApduSender.sendApdu).toHaveBeenCalledTimes(2);\n expect(mockApduSender.sendApdu.mock.calls).toEqual([\n [apdu, false, undefined],\n [Uint8Array.from([0xb0, 0x01, 0x00, 0x00, 0x00]), false, undefined], // GetAppAndVersion APDU sent after a successful result from an APDU that triggers disconnection\n ]);\n expect(result1).toStrictEqual(Right(apduResponse));\n expect(result2).toStrictEqual(\n Left(new DeviceDisconnectedWhileSendingError()),\n );\n });\n });\n});\n"],
|
5
|
+
"mappings": "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",
|
6
|
+
"names": ["Left", "Right", "afterEach", "beforeEach", "describe", "expect", "it", "vi", "ApduResponse", "DeviceConnectionStateMachine", "AlreadySendingApduError", "DeviceDisconnectedWhileSendingError", "machine", "mockApduSender", "apduResponse", "apduResponseErrorBusy", "apdu", "result", "apdu2", "result2", "promise", "promise1", "promise2", "result1", "value"]
|
7
|
+
}
|
@@ -1,2 +1,2 @@
|
|
1
|
-
class n{_tag="GeneralDmkError";originalError;constructor(
|
1
|
+
class n{_tag="GeneralDmkError";originalError;constructor(e){e instanceof Error?this.originalError=e:e!==void 0&&(this.originalError=new Error(String(e)))}}class t extends n{constructor(r){super(r);this.err=r}_tag="DeviceAlreadyDiscoveredError"}class s extends n{constructor(r){super(r);this.err=r}_tag="DeviceNotRecognizedError"}class d extends n{constructor(r){super(r);this.err=r}_tag="NoAccessibleDeviceError"}class c extends n{_tag="ConnectionOpeningError";constructor(e){super(e)}}class a extends n{constructor(r){super(r);this.err=r}_tag="UnknownDeviceError"}class i extends n{constructor(r){super(r);this.err=r}_tag="TransportNotSupportedError"}class l extends n{constructor(r){super(r);this.err=r}_tag="SendApduConcurrencyError"}class u extends n{constructor(r){super(r);this.err=r}_tag="SendApduTimeoutError"}class p extends n{constructor(r){super(r);this.err=r}_tag="SendApduEmptyResponseError"}class E extends n{constructor(r){super(r);this.err=r}_tag="DisconnectError"}class y extends n{constructor(r){super(r);this.err=r}_tag="ReconnectionFailedError"}class x extends n{constructor(r){super(r);this.err=r}_tag="DeviceNotInitializedError"}class v extends n{constructor(r){super(r);this.err=r}_tag="NoTransportsProvidedError"}class g extends n{constructor(r){super(r);this.err=r}_tag="TransportAlreadyExistsError"}class k extends n{constructor(r){super(r);this.err=r}_tag="DeviceDisconnectedWhileSendingError"}class D extends n{constructor(r){super(r);this.err=r}_tag="AlreadySendingApduError"}class w extends n{constructor(r){super(r);this.err=r}_tag="DeviceDisconnectedBeforeSendingApdu"}class A extends n{constructor(r){super(r);this.err=r}_tag="NoTransportProvidedError"}export{D as AlreadySendingApduError,t as DeviceAlreadyConnectedError,w as DeviceDisconnectedBeforeSendingApdu,k as DeviceDisconnectedWhileSendingError,x as DeviceNotInitializedError,s as DeviceNotRecognizedError,E as DisconnectError,n as GeneralDmkError,d as NoAccessibleDeviceError,A as NoTransportProvidedError,v as NoTransportsProvidedError,c as OpeningConnectionError,y as ReconnectionFailedError,l as SendApduConcurrencyError,p as SendApduEmptyResponseError,u as SendApduTimeoutError,g as TransportAlreadyExistsError,i as TransportNotSupportedError,a as UnknownDeviceError};
|
2
2
|
//# sourceMappingURL=Errors.js.map
|
@@ -1,7 +1,7 @@
|
|
1
1
|
{
|
2
2
|
"version": 3,
|
3
3
|
"sources": ["../../../../../../src/api/transport/model/Errors.ts"],
|
4
|
-
"sourcesContent": ["import { type DmkError } from \"@api/Error\";\n\nexport type ConnectError =\n | UnknownDeviceError\n | OpeningConnectionError\n | DeviceAlreadyConnectedError;\n\nexport class GeneralDmkError implements DmkError {\n _tag = \"GeneralDmkError\";\n originalError?: unknown;\n constructor(err?: unknown) {\n if (err instanceof Error) {\n this.originalError = err;\n } else if (err !== undefined) {\n this.originalError = new Error(String(err));\n }\n }\n}\n\nexport class DeviceAlreadyConnectedError extends GeneralDmkError {\n override readonly _tag = \"DeviceAlreadyDiscoveredError\";\n constructor(readonly err?: unknown) {\n super(err);\n }\n}\n\nexport class DeviceNotRecognizedError extends GeneralDmkError {\n override readonly _tag = \"DeviceNotRecognizedError\";\n constructor(readonly err?: unknown) {\n super(err);\n }\n}\n\nexport class NoAccessibleDeviceError extends GeneralDmkError {\n override readonly _tag = \"NoAccessibleDeviceError\";\n constructor(readonly err?: unknown) {\n super(err);\n }\n}\n\nexport class OpeningConnectionError extends GeneralDmkError {\n override
|
5
|
-
"mappings": "AAOO,MAAMA,CAAoC,CAC/C,KAAO,kBACP,cACA,YAAYC,EAAe,CACrBA,aAAe,MACjB,KAAK,cAAgBA,EACZA,IAAQ,SACjB,KAAK,cAAgB,IAAI,MAAM,OAAOA,CAAG,CAAC,EAE9C,CACF,CAEO,MAAMC,UAAoCF,CAAgB,CAE/D,YAAqBC,EAAe,CAClC,MAAMA,CAAG,EADU,SAAAA,CAErB,CAHkB,KAAO,8BAI3B,CAEO,MAAME,UAAiCH,CAAgB,CAE5D,YAAqBC,EAAe,CAClC,MAAMA,CAAG,EADU,SAAAA,CAErB,CAHkB,KAAO,0BAI3B,CAEO,MAAMG,UAAgCJ,CAAgB,CAE3D,YAAqBC,EAAe,CAClC,MAAMA,CAAG,EADU,SAAAA,CAErB,CAHkB,KAAO,yBAI3B,CAEO,MAAMI,UAA+BL,CAAgB,
|
6
|
-
"names": ["GeneralDmkError", "err", "DeviceAlreadyConnectedError", "DeviceNotRecognizedError", "NoAccessibleDeviceError", "OpeningConnectionError", "UnknownDeviceError", "TransportNotSupportedError", "SendApduConcurrencyError", "DisconnectError", "ReconnectionFailedError", "DeviceNotInitializedError", "NoTransportsProvidedError", "TransportAlreadyExistsError", "NoTransportProvidedError"]
|
4
|
+
"sourcesContent": ["import { type DmkError } from \"@api/Error\";\n\nexport type ConnectError =\n | UnknownDeviceError\n | OpeningConnectionError\n | DeviceAlreadyConnectedError;\n\nexport class GeneralDmkError implements DmkError {\n _tag = \"GeneralDmkError\";\n originalError?: unknown;\n constructor(err?: unknown) {\n if (err instanceof Error) {\n this.originalError = err;\n } else if (err !== undefined) {\n this.originalError = new Error(String(err));\n }\n }\n}\n\nexport class DeviceAlreadyConnectedError extends GeneralDmkError {\n override readonly _tag = \"DeviceAlreadyDiscoveredError\";\n constructor(readonly err?: unknown) {\n super(err);\n }\n}\n\nexport class DeviceNotRecognizedError extends GeneralDmkError {\n override readonly _tag = \"DeviceNotRecognizedError\";\n constructor(readonly err?: unknown) {\n super(err);\n }\n}\n\nexport class NoAccessibleDeviceError extends GeneralDmkError {\n override readonly _tag = \"NoAccessibleDeviceError\";\n constructor(readonly err?: unknown) {\n super(err);\n }\n}\n\nexport class OpeningConnectionError extends GeneralDmkError {\n override _tag = \"ConnectionOpeningError\";\n constructor(err?: unknown) {\n super(err);\n }\n}\n\nexport class UnknownDeviceError extends GeneralDmkError {\n override readonly _tag = \"UnknownDeviceError\";\n constructor(readonly err?: unknown) {\n super(err);\n }\n}\n\nexport class TransportNotSupportedError extends GeneralDmkError {\n override readonly _tag = \"TransportNotSupportedError\";\n constructor(readonly err?: unknown) {\n super(err);\n }\n}\nexport class SendApduConcurrencyError extends GeneralDmkError {\n override readonly _tag = \"SendApduConcurrencyError\";\n constructor(readonly err?: unknown) {\n super(err);\n }\n}\n\nexport class SendApduTimeoutError extends GeneralDmkError {\n override readonly _tag = \"SendApduTimeoutError\";\n constructor(readonly err?: unknown) {\n super(err);\n }\n}\n\nexport class SendApduEmptyResponseError extends GeneralDmkError {\n override readonly _tag = \"SendApduEmptyResponseError\";\n constructor(readonly err?: unknown) {\n super(err);\n }\n}\n\nexport class DisconnectError extends GeneralDmkError {\n override readonly _tag = \"DisconnectError\";\n constructor(readonly err?: unknown) {\n super(err);\n }\n}\n\nexport class ReconnectionFailedError extends GeneralDmkError {\n override readonly _tag = \"ReconnectionFailedError\";\n constructor(readonly err?: unknown) {\n super(err);\n }\n}\n\nexport class DeviceNotInitializedError extends GeneralDmkError {\n override readonly _tag = \"DeviceNotInitializedError\";\n constructor(readonly err?: unknown) {\n super(err);\n }\n}\n\nexport class NoTransportsProvidedError extends GeneralDmkError {\n override readonly _tag = \"NoTransportsProvidedError\";\n constructor(readonly err?: unknown) {\n super(err);\n }\n}\n\nexport class TransportAlreadyExistsError extends GeneralDmkError {\n override readonly _tag = \"TransportAlreadyExistsError\";\n constructor(readonly err?: unknown) {\n super(err);\n }\n}\n\nexport class DeviceDisconnectedWhileSendingError extends GeneralDmkError {\n override readonly _tag = \"DeviceDisconnectedWhileSendingError\";\n constructor(readonly err?: unknown) {\n super(err);\n }\n}\n\nexport class AlreadySendingApduError extends GeneralDmkError {\n override readonly _tag = \"AlreadySendingApduError\";\n constructor(readonly err?: unknown) {\n super(err);\n }\n}\n\nexport class DeviceDisconnectedBeforeSendingApdu extends GeneralDmkError {\n override readonly _tag = \"DeviceDisconnectedBeforeSendingApdu\";\n constructor(readonly err?: unknown) {\n super(err);\n }\n}\n\nexport class NoTransportProvidedError extends GeneralDmkError {\n override readonly _tag = \"NoTransportProvidedError\";\n constructor(readonly err?: unknown) {\n super(err);\n }\n}\n"],
|
5
|
+
"mappings": "AAOO,MAAMA,CAAoC,CAC/C,KAAO,kBACP,cACA,YAAYC,EAAe,CACrBA,aAAe,MACjB,KAAK,cAAgBA,EACZA,IAAQ,SACjB,KAAK,cAAgB,IAAI,MAAM,OAAOA,CAAG,CAAC,EAE9C,CACF,CAEO,MAAMC,UAAoCF,CAAgB,CAE/D,YAAqBC,EAAe,CAClC,MAAMA,CAAG,EADU,SAAAA,CAErB,CAHkB,KAAO,8BAI3B,CAEO,MAAME,UAAiCH,CAAgB,CAE5D,YAAqBC,EAAe,CAClC,MAAMA,CAAG,EADU,SAAAA,CAErB,CAHkB,KAAO,0BAI3B,CAEO,MAAMG,UAAgCJ,CAAgB,CAE3D,YAAqBC,EAAe,CAClC,MAAMA,CAAG,EADU,SAAAA,CAErB,CAHkB,KAAO,yBAI3B,CAEO,MAAMI,UAA+BL,CAAgB,CACjD,KAAO,yBAChB,YAAYC,EAAe,CACzB,MAAMA,CAAG,CACX,CACF,CAEO,MAAMK,UAA2BN,CAAgB,CAEtD,YAAqBC,EAAe,CAClC,MAAMA,CAAG,EADU,SAAAA,CAErB,CAHkB,KAAO,oBAI3B,CAEO,MAAMM,UAAmCP,CAAgB,CAE9D,YAAqBC,EAAe,CAClC,MAAMA,CAAG,EADU,SAAAA,CAErB,CAHkB,KAAO,4BAI3B,CACO,MAAMO,UAAiCR,CAAgB,CAE5D,YAAqBC,EAAe,CAClC,MAAMA,CAAG,EADU,SAAAA,CAErB,CAHkB,KAAO,0BAI3B,CAEO,MAAMQ,UAA6BT,CAAgB,CAExD,YAAqBC,EAAe,CAClC,MAAMA,CAAG,EADU,SAAAA,CAErB,CAHkB,KAAO,sBAI3B,CAEO,MAAMS,UAAmCV,CAAgB,CAE9D,YAAqBC,EAAe,CAClC,MAAMA,CAAG,EADU,SAAAA,CAErB,CAHkB,KAAO,4BAI3B,CAEO,MAAMU,UAAwBX,CAAgB,CAEnD,YAAqBC,EAAe,CAClC,MAAMA,CAAG,EADU,SAAAA,CAErB,CAHkB,KAAO,iBAI3B,CAEO,MAAMW,UAAgCZ,CAAgB,CAE3D,YAAqBC,EAAe,CAClC,MAAMA,CAAG,EADU,SAAAA,CAErB,CAHkB,KAAO,yBAI3B,CAEO,MAAMY,UAAkCb,CAAgB,CAE7D,YAAqBC,EAAe,CAClC,MAAMA,CAAG,EADU,SAAAA,CAErB,CAHkB,KAAO,2BAI3B,CAEO,MAAMa,UAAkCd,CAAgB,CAE7D,YAAqBC,EAAe,CAClC,MAAMA,CAAG,EADU,SAAAA,CAErB,CAHkB,KAAO,2BAI3B,CAEO,MAAMc,UAAoCf,CAAgB,CAE/D,YAAqBC,EAAe,CAClC,MAAMA,CAAG,EADU,SAAAA,CAErB,CAHkB,KAAO,6BAI3B,CAEO,MAAMe,UAA4ChB,CAAgB,CAEvE,YAAqBC,EAAe,CAClC,MAAMA,CAAG,EADU,SAAAA,CAErB,CAHkB,KAAO,qCAI3B,CAEO,MAAMgB,UAAgCjB,CAAgB,CAE3D,YAAqBC,EAAe,CAClC,MAAMA,CAAG,EADU,SAAAA,CAErB,CAHkB,KAAO,yBAI3B,CAEO,MAAMiB,UAA4ClB,CAAgB,CAEvE,YAAqBC,EAAe,CAClC,MAAMA,CAAG,EADU,SAAAA,CAErB,CAHkB,KAAO,qCAI3B,CAEO,MAAMkB,UAAiCnB,CAAgB,CAE5D,YAAqBC,EAAe,CAClC,MAAMA,CAAG,EADU,SAAAA,CAErB,CAHkB,KAAO,0BAI3B",
|
6
|
+
"names": ["GeneralDmkError", "err", "DeviceAlreadyConnectedError", "DeviceNotRecognizedError", "NoAccessibleDeviceError", "OpeningConnectionError", "UnknownDeviceError", "TransportNotSupportedError", "SendApduConcurrencyError", "SendApduTimeoutError", "SendApduEmptyResponseError", "DisconnectError", "ReconnectionFailedError", "DeviceNotInitializedError", "NoTransportsProvidedError", "TransportAlreadyExistsError", "DeviceDisconnectedWhileSendingError", "AlreadySendingApduError", "DeviceDisconnectedBeforeSendingApdu", "NoTransportProvidedError"]
|
7
7
|
}
|
@@ -0,0 +1,7 @@
|
|
1
|
+
{
|
2
|
+
"version": 3,
|
3
|
+
"sources": ["../../../../../src/api/utils/AppName.ts"],
|
4
|
+
"sourcesContent": ["const DASHBOARD_NAMES = [\"BOLOS\", \"OLOS\", \"OLOS\\u0000\"];\n\nexport const isDashboardName = (name: string) => DASHBOARD_NAMES.includes(name);\n"],
|
5
|
+
"mappings": "AAAA,MAAMA,EAAkB,CAAC,QAAS,OAAQ,QAAY,EAEzCC,EAAmBC,GAAiBF,EAAgB,SAASE,CAAI",
|
6
|
+
"names": ["DASHBOARD_NAMES", "isDashboardName", "name"]
|
7
|
+
}
|
@@ -0,0 +1,2 @@
|
|
1
|
+
import{isDashboardName as t}from"./AppName";describe("AppName",()=>{describe("isDashboardName",()=>{it("should return true if the value is BOLOS",()=>{const e=t("BOLOS");expect(e).toBeTruthy()}),it("should return true if the value is OLOS",()=>{const e=t("OLOS\0");expect(e).toBeTruthy()}),it("should return false if the value is Bitcoin",()=>{const e=t("Bitcoin");expect(e).toBeFalsy()})})});
|
2
|
+
//# sourceMappingURL=AppName.test.js.map
|
@@ -0,0 +1,7 @@
|
|
1
|
+
{
|
2
|
+
"version": 3,
|
3
|
+
"sources": ["../../../../../src/api/utils/AppName.test.ts"],
|
4
|
+
"sourcesContent": ["import { isDashboardName } from \"./AppName\";\n\ndescribe(\"AppName\", () => {\n describe(\"isDashboardName\", () => {\n it(\"should return true if the value is BOLOS\", () => {\n // GIVEN\n const value = \"BOLOS\";\n\n // WHEN\n const result = isDashboardName(value);\n\n // THEN\n expect(result).toBeTruthy();\n });\n\n it(\"should return true if the value is OLOS\", () => {\n // GIVEN\n const value = \"OLOS\\0\";\n\n // WHEN\n const result = isDashboardName(value);\n\n // THEN\n expect(result).toBeTruthy();\n });\n\n it(\"should return false if the value is Bitcoin\", () => {\n // GIVEN\n const value = \"Bitcoin\";\n\n // WHEN\n const result = isDashboardName(value);\n\n // THEN\n expect(result).toBeFalsy();\n });\n });\n});\n"],
|
5
|
+
"mappings": "AAAA,OAAS,mBAAAA,MAAuB,YAEhC,SAAS,UAAW,IAAM,CACxB,SAAS,kBAAmB,IAAM,CAChC,GAAG,2CAA4C,IAAM,CAKnD,MAAMC,EAASD,EAHD,OAGsB,EAGpC,OAAOC,CAAM,EAAE,WAAW,CAC5B,CAAC,EAED,GAAG,0CAA2C,IAAM,CAKlD,MAAMA,EAASD,EAHD,QAGsB,EAGpC,OAAOC,CAAM,EAAE,WAAW,CAC5B,CAAC,EAED,GAAG,8CAA+C,IAAM,CAKtD,MAAMA,EAASD,EAHD,SAGsB,EAGpC,OAAOC,CAAM,EAAE,UAAU,CAC3B,CAAC,CACH,CAAC,CACH,CAAC",
|
6
|
+
"names": ["isDashboardName", "result"]
|
7
|
+
}
|
package/lib/esm/src/di.js
CHANGED
@@ -1,2 +1,2 @@
|
|
1
|
-
import{Container as
|
1
|
+
import{Container as m}from"inversify";import{commandModuleFactory as a}from"./api/command/di/commandModule";import{deviceActionModuleFactory as p}from"./api/device-action/di/deviceActionModule";import{configModuleFactory as c}from"./internal/config/di/configModule";import{deviceModelModuleFactory as n}from"./internal/device-model/di/deviceModelModule";import{deviceSessionModuleFactory as l}from"./internal/device-session/di/deviceSessionModule";import{discoveryModuleFactory as f}from"./internal/discovery/di/discoveryModule";import{loggerModuleFactory as d}from"./internal/logger-publisher/di/loggerModule";import{managerApiModuleFactory as y}from"./internal/manager-api/di/managerApiModule";import{DEFAULT_FIRMWARE_DISTRIBUTION_SALT as F,DEFAULT_MANAGER_API_BASE_URL as M,DEFAULT_MOCK_SERVER_BASE_URL as A,DEFAULT_PROVIDER as _}from"./internal/manager-api/model/Const";import{secureChannelModuleFactory as E}from"./internal/secure-channel/di/secureChannelModule";import{DEFAULT_WEB_SOCKET_BASE_URL as S}from"./internal/secure-channel/model/Const";import{sendModuleFactory as s}from"./internal/send/di/sendModule";import{transportModuleFactory as g}from"./internal/transport/di/transportModule";const x=({stub:o=!1,transports:t=[],loggers:i=[],config:r={mockUrl:A,managerApiUrl:M,webSocketUrl:S,provider:_,firmwareDistributionSalt:F}})=>{const e=new m;return e.loadSync(c({stub:o}),n({stub:o}),g({stub:o,transports:t,config:r}),y({stub:o,config:r}),E({stub:o,config:r}),f({stub:o}),d({subscribers:i}),l({stub:o}),s({stub:o}),a({stub:o}),p({stub:o})),e};export{x as makeContainer};
|
2
2
|
//# sourceMappingURL=di.js.map
|
package/lib/esm/src/di.js.map
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
{
|
2
2
|
"version": 3,
|
3
3
|
"sources": ["../../../src/di.ts"],
|
4
|
-
"sourcesContent": ["import { Container } from \"inversify\";\n\
|
5
|
-
"mappings": "AAAA,OAAS,aAAAA,MAAiB,
|
6
|
-
"names": ["Container", "commandModuleFactory", "deviceActionModuleFactory", "configModuleFactory", "deviceModelModuleFactory", "deviceSessionModuleFactory", "discoveryModuleFactory", "loggerModuleFactory", "managerApiModuleFactory", "DEFAULT_MANAGER_API_BASE_URL", "DEFAULT_MOCK_SERVER_BASE_URL", "secureChannelModuleFactory", "DEFAULT_WEB_SOCKET_BASE_URL", "sendModuleFactory", "transportModuleFactory", "makeContainer", "stub", "transports", "loggers", "config", "container"]
|
4
|
+
"sourcesContent": ["import { Container } from \"inversify\";\n\nimport { commandModuleFactory } from \"@api/command/di/commandModule\";\nimport { deviceActionModuleFactory } from \"@api/device-action/di/deviceActionModule\";\nimport { type DmkConfig } from \"@api/DmkConfig\";\nimport { type LoggerSubscriberService } from \"@api/logger-subscriber/service/LoggerSubscriberService\";\nimport { type TransportFactory } from \"@api/transport/model/Transport\";\nimport { configModuleFactory } from \"@internal/config/di/configModule\";\nimport { deviceModelModuleFactory } from \"@internal/device-model/di/deviceModelModule\";\nimport { deviceSessionModuleFactory } from \"@internal/device-session/di/deviceSessionModule\";\nimport { discoveryModuleFactory } from \"@internal/discovery/di/discoveryModule\";\nimport { loggerModuleFactory } from \"@internal/logger-publisher/di/loggerModule\";\nimport { managerApiModuleFactory } from \"@internal/manager-api/di/managerApiModule\";\nimport {\n DEFAULT_FIRMWARE_DISTRIBUTION_SALT,\n DEFAULT_MANAGER_API_BASE_URL,\n DEFAULT_MOCK_SERVER_BASE_URL,\n DEFAULT_PROVIDER,\n} from \"@internal/manager-api/model/Const\";\nimport { secureChannelModuleFactory } from \"@internal/secure-channel/di/secureChannelModule\";\nimport { DEFAULT_WEB_SOCKET_BASE_URL } from \"@internal/secure-channel/model/Const\";\nimport { sendModuleFactory } from \"@internal/send/di/sendModule\";\nimport { transportModuleFactory } from \"@internal/transport//di/transportModule\";\n\nexport type MakeContainerProps = {\n stub: boolean;\n transports: TransportFactory[];\n loggers: LoggerSubscriberService[];\n config: DmkConfig;\n};\n\nexport const makeContainer = ({\n stub = false,\n transports = [],\n loggers = [],\n config = {\n mockUrl: DEFAULT_MOCK_SERVER_BASE_URL,\n managerApiUrl: DEFAULT_MANAGER_API_BASE_URL,\n webSocketUrl: DEFAULT_WEB_SOCKET_BASE_URL,\n provider: DEFAULT_PROVIDER,\n firmwareDistributionSalt: DEFAULT_FIRMWARE_DISTRIBUTION_SALT,\n },\n}: Partial<MakeContainerProps>) => {\n const container = new Container();\n\n container.loadSync(\n configModuleFactory({ stub }),\n deviceModelModuleFactory({ stub }),\n transportModuleFactory({ stub, transports, config }),\n managerApiModuleFactory({ stub, config }),\n secureChannelModuleFactory({ stub, config }),\n discoveryModuleFactory({ stub }),\n loggerModuleFactory({ subscribers: loggers }),\n deviceSessionModuleFactory({ stub }),\n sendModuleFactory({ stub }),\n commandModuleFactory({ stub }),\n deviceActionModuleFactory({ stub }),\n // modules go here\n );\n\n return container;\n};\n"],
|
5
|
+
"mappings": "AAAA,OAAS,aAAAA,MAAiB,YAE1B,OAAS,wBAAAC,MAA4B,gCACrC,OAAS,6BAAAC,MAAiC,2CAI1C,OAAS,uBAAAC,MAA2B,mCACpC,OAAS,4BAAAC,MAAgC,8CACzC,OAAS,8BAAAC,MAAkC,kDAC3C,OAAS,0BAAAC,MAA8B,yCACvC,OAAS,uBAAAC,MAA2B,6CACpC,OAAS,2BAAAC,MAA+B,4CACxC,OACE,sCAAAC,EACA,gCAAAC,EACA,gCAAAC,EACA,oBAAAC,MACK,oCACP,OAAS,8BAAAC,MAAkC,kDAC3C,OAAS,+BAAAC,MAAmC,uCAC5C,OAAS,qBAAAC,MAAyB,+BAClC,OAAS,0BAAAC,MAA8B,0CAShC,MAAMC,EAAgB,CAAC,CAC5B,KAAAC,EAAO,GACP,WAAAC,EAAa,CAAC,EACd,QAAAC,EAAU,CAAC,EACX,OAAAC,EAAS,CACP,QAASV,EACT,cAAeD,EACf,aAAcI,EACd,SAAUF,EACV,yBAA0BH,CAC5B,CACF,IAAmC,CACjC,MAAMa,EAAY,IAAItB,EAEtB,OAAAsB,EAAU,SACRnB,EAAoB,CAAE,KAAAe,CAAK,CAAC,EAC5Bd,EAAyB,CAAE,KAAAc,CAAK,CAAC,EACjCF,EAAuB,CAAE,KAAAE,EAAM,WAAAC,EAAY,OAAAE,CAAO,CAAC,EACnDb,EAAwB,CAAE,KAAAU,EAAM,OAAAG,CAAO,CAAC,EACxCR,EAA2B,CAAE,KAAAK,EAAM,OAAAG,CAAO,CAAC,EAC3Cf,EAAuB,CAAE,KAAAY,CAAK,CAAC,EAC/BX,EAAoB,CAAE,YAAaa,CAAQ,CAAC,EAC5Cf,EAA2B,CAAE,KAAAa,CAAK,CAAC,EACnCH,EAAkB,CAAE,KAAAG,CAAK,CAAC,EAC1BjB,EAAqB,CAAE,KAAAiB,CAAK,CAAC,EAC7BhB,EAA0B,CAAE,KAAAgB,CAAK,CAAC,CAEpC,EAEOI,CACT",
|
6
|
+
"names": ["Container", "commandModuleFactory", "deviceActionModuleFactory", "configModuleFactory", "deviceModelModuleFactory", "deviceSessionModuleFactory", "discoveryModuleFactory", "loggerModuleFactory", "managerApiModuleFactory", "DEFAULT_FIRMWARE_DISTRIBUTION_SALT", "DEFAULT_MANAGER_API_BASE_URL", "DEFAULT_MOCK_SERVER_BASE_URL", "DEFAULT_PROVIDER", "secureChannelModuleFactory", "DEFAULT_WEB_SOCKET_BASE_URL", "sendModuleFactory", "transportModuleFactory", "makeContainer", "stub", "transports", "loggers", "config", "container"]
|
7
7
|
}
|
@@ -1,2 +1,2 @@
|
|
1
|
-
import{ContainerModule as a}from"inversify";import{FileLocalConfigDataSource as i}from"../../config/data/LocalConfigDataSource";import{StubLocalConfigDataSource as f}from"../../config/data/LocalConfigDataSource.stub";import{RestRemoteConfigDataSource as m}from"../../config/data/RemoteConfigDataSource";import{StubRemoteConfigDataSource as c}from"../../config/data/RemoteConfigDataSource.stub";import{DefaultConfigService as n}from"../../config/service/DefaultConfigService";import{GetDmkVersionUseCase as u}from"../../config/use-case/GetDmkVersionUseCase";import{configTypes as o}from"./configTypes";const
|
1
|
+
import{ContainerModule as a}from"inversify";import{FileLocalConfigDataSource as i}from"../../config/data/LocalConfigDataSource";import{StubLocalConfigDataSource as f}from"../../config/data/LocalConfigDataSource.stub";import{RestRemoteConfigDataSource as m}from"../../config/data/RemoteConfigDataSource";import{StubRemoteConfigDataSource as c}from"../../config/data/RemoteConfigDataSource.stub";import{DefaultConfigService as n}from"../../config/service/DefaultConfigService";import{GetDmkVersionUseCase as u}from"../../config/use-case/GetDmkVersionUseCase";import{configTypes as o}from"./configTypes";const y=({stub:r})=>new a(({bind:t,rebindSync:e})=>{t(o.LocalConfigDataSource).to(i),t(o.RemoteConfigDataSource).to(m),t(o.GetDmkVersionUseCase).to(u),t(o.ConfigService).to(n),r&&(e(o.LocalConfigDataSource).to(f),e(o.RemoteConfigDataSource).to(c))});export{y as configModuleFactory};
|
2
2
|
//# sourceMappingURL=configModule.js.map
|
@@ -1,7 +1,7 @@
|
|
1
1
|
{
|
2
2
|
"version": 3,
|
3
3
|
"sources": ["../../../../../../src/internal/config/di/configModule.ts"],
|
4
|
-
"sourcesContent": ["import { ContainerModule } from \"inversify\";\n\nimport { FileLocalConfigDataSource } from \"@internal/config/data/LocalConfigDataSource\";\nimport { StubLocalConfigDataSource } from \"@internal/config/data/LocalConfigDataSource.stub\";\nimport { RestRemoteConfigDataSource } from \"@internal/config/data/RemoteConfigDataSource\";\nimport { StubRemoteConfigDataSource } from \"@internal/config/data/RemoteConfigDataSource.stub\";\nimport { DefaultConfigService } from \"@internal/config/service/DefaultConfigService\";\nimport { GetDmkVersionUseCase } from \"@internal/config/use-case/GetDmkVersionUseCase\";\n\nimport { configTypes } from \"./configTypes\";\n\n// This module is used to configure the dependency injection container\n// This is where we will bind our interfaces to their implementations (or mocks...)\ntype FactoryProps = {\n stub: boolean;\n};\n\nexport const configModuleFactory = ({ stub }: FactoryProps) =>\n new ContainerModule((bind,
|
5
|
-
"mappings": "AAAA,OAAS,mBAAAA,MAAuB,YAEhC,OAAS,6BAAAC,MAAiC,8CAC1C,OAAS,6BAAAC,MAAiC,mDAC1C,OAAS,8BAAAC,MAAkC,+CAC3C,OAAS,8BAAAC,MAAkC,oDAC3C,OAAS,wBAAAC,MAA4B,gDACrC,OAAS,wBAAAC,MAA4B,iDAErC,OAAS,eAAAC,MAAmB,gBAQrB,MAAMC,EAAsB,CAAC,CAAE,KAAAC,CAAK,IACzC,IAAIT,EAAgB,
|
6
|
-
"names": ["ContainerModule", "FileLocalConfigDataSource", "StubLocalConfigDataSource", "RestRemoteConfigDataSource", "StubRemoteConfigDataSource", "DefaultConfigService", "GetDmkVersionUseCase", "configTypes", "configModuleFactory", "stub", "bind", "
|
4
|
+
"sourcesContent": ["import { ContainerModule } from \"inversify\";\n\nimport { FileLocalConfigDataSource } from \"@internal/config/data/LocalConfigDataSource\";\nimport { StubLocalConfigDataSource } from \"@internal/config/data/LocalConfigDataSource.stub\";\nimport { RestRemoteConfigDataSource } from \"@internal/config/data/RemoteConfigDataSource\";\nimport { StubRemoteConfigDataSource } from \"@internal/config/data/RemoteConfigDataSource.stub\";\nimport { DefaultConfigService } from \"@internal/config/service/DefaultConfigService\";\nimport { GetDmkVersionUseCase } from \"@internal/config/use-case/GetDmkVersionUseCase\";\n\nimport { configTypes } from \"./configTypes\";\n\n// This module is used to configure the dependency injection container\n// This is where we will bind our interfaces to their implementations (or mocks...)\ntype FactoryProps = {\n stub: boolean;\n};\n\nexport const configModuleFactory = ({ stub }: FactoryProps) =>\n new ContainerModule(({ bind, rebindSync }) => {\n bind(configTypes.LocalConfigDataSource).to(FileLocalConfigDataSource);\n bind(configTypes.RemoteConfigDataSource).to(RestRemoteConfigDataSource);\n bind(configTypes.GetDmkVersionUseCase).to(GetDmkVersionUseCase);\n bind(configTypes.ConfigService).to(DefaultConfigService);\n\n if (stub) {\n // We can rebind our interfaces to their mock implementations\n rebindSync(configTypes.LocalConfigDataSource).to(\n StubLocalConfigDataSource,\n );\n rebindSync(configTypes.RemoteConfigDataSource).to(\n StubRemoteConfigDataSource,\n );\n }\n });\n"],
|
5
|
+
"mappings": "AAAA,OAAS,mBAAAA,MAAuB,YAEhC,OAAS,6BAAAC,MAAiC,8CAC1C,OAAS,6BAAAC,MAAiC,mDAC1C,OAAS,8BAAAC,MAAkC,+CAC3C,OAAS,8BAAAC,MAAkC,oDAC3C,OAAS,wBAAAC,MAA4B,gDACrC,OAAS,wBAAAC,MAA4B,iDAErC,OAAS,eAAAC,MAAmB,gBAQrB,MAAMC,EAAsB,CAAC,CAAE,KAAAC,CAAK,IACzC,IAAIT,EAAgB,CAAC,CAAE,KAAAU,EAAM,WAAAC,CAAW,IAAM,CAC5CD,EAAKH,EAAY,qBAAqB,EAAE,GAAGN,CAAyB,EACpES,EAAKH,EAAY,sBAAsB,EAAE,GAAGJ,CAA0B,EACtEO,EAAKH,EAAY,oBAAoB,EAAE,GAAGD,CAAoB,EAC9DI,EAAKH,EAAY,aAAa,EAAE,GAAGF,CAAoB,EAEnDI,IAEFE,EAAWJ,EAAY,qBAAqB,EAAE,GAC5CL,CACF,EACAS,EAAWJ,EAAY,sBAAsB,EAAE,GAC7CH,CACF,EAEJ,CAAC",
|
6
|
+
"names": ["ContainerModule", "FileLocalConfigDataSource", "StubLocalConfigDataSource", "RestRemoteConfigDataSource", "StubRemoteConfigDataSource", "DefaultConfigService", "GetDmkVersionUseCase", "configTypes", "configModuleFactory", "stub", "bind", "rebindSync"]
|
7
7
|
}
|
@@ -1,2 +1,2 @@
|
|
1
|
-
import{Container as a}from"inversify";import{FileLocalConfigDataSource as i}from"../../config/data/LocalConfigDataSource";import{StubLocalConfigDataSource as u}from"../../config/data/LocalConfigDataSource.stub";import{RestRemoteConfigDataSource as f}from"../../config/data/RemoteConfigDataSource";import{StubRemoteConfigDataSource as l}from"../../config/data/RemoteConfigDataSource.stub";import{configModuleFactory as n}from"./configModule";import{configTypes as t}from"./configTypes";describe("configModuleFactory",()=>{describe("Default",()=>{let e,o;beforeEach(()=>{o=n({stub:!1}),e=new a,e.
|
1
|
+
import{Container as a}from"inversify";import{FileLocalConfigDataSource as i}from"../../config/data/LocalConfigDataSource";import{StubLocalConfigDataSource as u}from"../../config/data/LocalConfigDataSource.stub";import{RestRemoteConfigDataSource as f}from"../../config/data/RemoteConfigDataSource";import{StubRemoteConfigDataSource as l}from"../../config/data/RemoteConfigDataSource.stub";import{configModuleFactory as n}from"./configModule";import{configTypes as t}from"./configTypes";describe("configModuleFactory",()=>{describe("Default",()=>{let e,o;beforeEach(()=>{o=n({stub:!1}),e=new a,e.loadSync(o)}),it("should return the config module",()=>{expect(o).toBeDefined()}),it("should return none mocked data sources",()=>{const c=e.get(t.LocalConfigDataSource),r=e.get(t.RemoteConfigDataSource);expect(c).toBeInstanceOf(i),expect(r).toBeInstanceOf(f)})}),describe("Mocked",()=>{let e,o;beforeEach(()=>{o=n({stub:!0}),e=new a,e.loadSync(o)}),it("should return the config module",()=>{expect(o).toBeDefined()}),it("should return mocked data sources",()=>{const c=e.get(t.LocalConfigDataSource),r=e.get(t.RemoteConfigDataSource);expect(c).toBeInstanceOf(u),expect(r).toBeInstanceOf(l)})})});
|
2
2
|
//# sourceMappingURL=configModule.test.js.map
|
@@ -1,7 +1,7 @@
|
|
1
1
|
{
|
2
2
|
"version": 3,
|
3
3
|
"sources": ["../../../../../../src/internal/config/di/configModule.test.ts"],
|
4
|
-
"sourcesContent": ["import { Container } from \"inversify\";\n\nimport { FileLocalConfigDataSource } from \"@internal/config/data/LocalConfigDataSource\";\nimport { StubLocalConfigDataSource } from \"@internal/config/data/LocalConfigDataSource.stub\";\nimport { RestRemoteConfigDataSource } from \"@internal/config/data/RemoteConfigDataSource\";\nimport { StubRemoteConfigDataSource } from \"@internal/config/data/RemoteConfigDataSource.stub\";\n\nimport { configModuleFactory } from \"./configModule\";\nimport { configTypes } from \"./configTypes\";\n\ndescribe(\"configModuleFactory\", () => {\n describe(\"Default\", () => {\n let container: Container;\n let mod: ReturnType<typeof configModuleFactory>;\n beforeEach(() => {\n mod = configModuleFactory({ stub: false });\n container = new Container();\n container.
|
5
|
-
"mappings": "AAAA,OAAS,aAAAA,MAAiB,YAE1B,OAAS,6BAAAC,MAAiC,8CAC1C,OAAS,6BAAAC,MAAiC,mDAC1C,OAAS,8BAAAC,MAAkC,+CAC3C,OAAS,8BAAAC,MAAkC,oDAE3C,OAAS,uBAAAC,MAA2B,iBACpC,OAAS,eAAAC,MAAmB,gBAE5B,SAAS,sBAAuB,IAAM,CACpC,SAAS,UAAW,IAAM,CACxB,IAAIC,EACAC,EACJ,WAAW,IAAM,CACfA,EAAMH,EAAoB,CAAE,KAAM,EAAM,CAAC,EACzCE,EAAY,IAAIP,EAChBO,EAAU,
|
4
|
+
"sourcesContent": ["import { Container } from \"inversify\";\n\nimport { FileLocalConfigDataSource } from \"@internal/config/data/LocalConfigDataSource\";\nimport { StubLocalConfigDataSource } from \"@internal/config/data/LocalConfigDataSource.stub\";\nimport { RestRemoteConfigDataSource } from \"@internal/config/data/RemoteConfigDataSource\";\nimport { StubRemoteConfigDataSource } from \"@internal/config/data/RemoteConfigDataSource.stub\";\n\nimport { configModuleFactory } from \"./configModule\";\nimport { configTypes } from \"./configTypes\";\n\ndescribe(\"configModuleFactory\", () => {\n describe(\"Default\", () => {\n let container: Container;\n let mod: ReturnType<typeof configModuleFactory>;\n beforeEach(() => {\n mod = configModuleFactory({ stub: false });\n container = new Container();\n container.loadSync(mod);\n });\n\n it(\"should return the config module\", () => {\n expect(mod).toBeDefined();\n });\n\n it(\"should return none mocked data sources\", () => {\n const localDataSource = container.get(configTypes.LocalConfigDataSource);\n const remoteDataSource = container.get(\n configTypes.RemoteConfigDataSource,\n );\n expect(localDataSource).toBeInstanceOf(FileLocalConfigDataSource);\n expect(remoteDataSource).toBeInstanceOf(RestRemoteConfigDataSource);\n });\n });\n\n describe(\"Mocked\", () => {\n let container: Container;\n let mod: ReturnType<typeof configModuleFactory>;\n beforeEach(() => {\n mod = configModuleFactory({ stub: true });\n container = new Container();\n container.loadSync(mod);\n });\n\n it(\"should return the config module\", () => {\n expect(mod).toBeDefined();\n });\n\n it(\"should return mocked data sources\", () => {\n const localDataSource = container.get(configTypes.LocalConfigDataSource);\n const remoteDataSource = container.get(\n configTypes.RemoteConfigDataSource,\n );\n expect(localDataSource).toBeInstanceOf(StubLocalConfigDataSource);\n expect(remoteDataSource).toBeInstanceOf(StubRemoteConfigDataSource);\n });\n });\n});\n"],
|
5
|
+
"mappings": "AAAA,OAAS,aAAAA,MAAiB,YAE1B,OAAS,6BAAAC,MAAiC,8CAC1C,OAAS,6BAAAC,MAAiC,mDAC1C,OAAS,8BAAAC,MAAkC,+CAC3C,OAAS,8BAAAC,MAAkC,oDAE3C,OAAS,uBAAAC,MAA2B,iBACpC,OAAS,eAAAC,MAAmB,gBAE5B,SAAS,sBAAuB,IAAM,CACpC,SAAS,UAAW,IAAM,CACxB,IAAIC,EACAC,EACJ,WAAW,IAAM,CACfA,EAAMH,EAAoB,CAAE,KAAM,EAAM,CAAC,EACzCE,EAAY,IAAIP,EAChBO,EAAU,SAASC,CAAG,CACxB,CAAC,EAED,GAAG,kCAAmC,IAAM,CAC1C,OAAOA,CAAG,EAAE,YAAY,CAC1B,CAAC,EAED,GAAG,yCAA0C,IAAM,CACjD,MAAMC,EAAkBF,EAAU,IAAID,EAAY,qBAAqB,EACjEI,EAAmBH,EAAU,IACjCD,EAAY,sBACd,EACA,OAAOG,CAAe,EAAE,eAAeR,CAAyB,EAChE,OAAOS,CAAgB,EAAE,eAAeP,CAA0B,CACpE,CAAC,CACH,CAAC,EAED,SAAS,SAAU,IAAM,CACvB,IAAII,EACAC,EACJ,WAAW,IAAM,CACfA,EAAMH,EAAoB,CAAE,KAAM,EAAK,CAAC,EACxCE,EAAY,IAAIP,EAChBO,EAAU,SAASC,CAAG,CACxB,CAAC,EAED,GAAG,kCAAmC,IAAM,CAC1C,OAAOA,CAAG,EAAE,YAAY,CAC1B,CAAC,EAED,GAAG,oCAAqC,IAAM,CAC5C,MAAMC,EAAkBF,EAAU,IAAID,EAAY,qBAAqB,EACjEI,EAAmBH,EAAU,IACjCD,EAAY,sBACd,EACA,OAAOG,CAAe,EAAE,eAAeP,CAAyB,EAChE,OAAOQ,CAAgB,EAAE,eAAeN,CAA0B,CACpE,CAAC,CACH,CAAC,CACH,CAAC",
|
6
6
|
"names": ["Container", "FileLocalConfigDataSource", "StubLocalConfigDataSource", "RestRemoteConfigDataSource", "StubRemoteConfigDataSource", "configModuleFactory", "configTypes", "container", "mod", "localDataSource", "remoteDataSource"]
|
7
7
|
}
|
@@ -1,2 +1,2 @@
|
|
1
|
-
import{ContainerModule as
|
1
|
+
import{ContainerModule as t}from"inversify";import{StaticDeviceModelDataSource as r}from"../../../api/device-model/data/StaticDeviceModelDataSource";import{deviceModelTypes as c}from"./deviceModelTypes";const p=({stub:o})=>new t(({bind:e})=>{e(c.DeviceModelDataSource).to(r)});export{p as deviceModelModuleFactory};
|
2
2
|
//# sourceMappingURL=deviceModelModule.js.map
|
@@ -1,7 +1,7 @@
|
|
1
1
|
{
|
2
2
|
"version": 3,
|
3
3
|
"sources": ["../../../../../../src/internal/device-model/di/deviceModelModule.ts"],
|
4
|
-
"sourcesContent": ["import { ContainerModule } from \"inversify\";\n\nimport { StaticDeviceModelDataSource } from \"@api/device-model/data/StaticDeviceModelDataSource\";\n\nimport { deviceModelTypes } from \"./deviceModelTypes\";\n\ntype FactoryProps = {\n stub: boolean;\n};\n\nexport const deviceModelModuleFactory = ({ stub }: FactoryProps) =>\n new ContainerModule((bind
|
5
|
-
"mappings": "AAAA,OAAS,mBAAAA,MAAuB,YAEhC,OAAS,+BAAAC,MAAmC,qDAE5C,OAAS,oBAAAC,MAAwB,qBAM1B,MAAMC,EAA2B,CAAC,CAAE,KAAAC,CAAK,IAC9C,IAAIJ,EAAgB,
|
6
|
-
"names": ["ContainerModule", "StaticDeviceModelDataSource", "deviceModelTypes", "deviceModelModuleFactory", "stub", "bind"
|
4
|
+
"sourcesContent": ["import { ContainerModule } from \"inversify\";\n\nimport { StaticDeviceModelDataSource } from \"@api/device-model/data/StaticDeviceModelDataSource\";\n\nimport { deviceModelTypes } from \"./deviceModelTypes\";\n\ntype FactoryProps = {\n stub: boolean;\n};\n\nexport const deviceModelModuleFactory = ({ stub }: FactoryProps) =>\n new ContainerModule(({ bind }) => {\n bind(deviceModelTypes.DeviceModelDataSource).to(\n StaticDeviceModelDataSource,\n );\n\n if (stub) {\n // We can rebind our interfaces to their mock implementations\n // rebind(...).to(....);\n }\n });\n"],
|
5
|
+
"mappings": "AAAA,OAAS,mBAAAA,MAAuB,YAEhC,OAAS,+BAAAC,MAAmC,qDAE5C,OAAS,oBAAAC,MAAwB,qBAM1B,MAAMC,EAA2B,CAAC,CAAE,KAAAC,CAAK,IAC9C,IAAIJ,EAAgB,CAAC,CAAE,KAAAK,CAAK,IAAM,CAChCA,EAAKH,EAAiB,qBAAqB,EAAE,GAC3CD,CACF,CAMF,CAAC",
|
6
|
+
"names": ["ContainerModule", "StaticDeviceModelDataSource", "deviceModelTypes", "deviceModelModuleFactory", "stub", "bind"]
|
7
7
|
}
|
@@ -1,2 +1,2 @@
|
|
1
|
-
import{Container as
|
1
|
+
import{Container as c}from"inversify";import{StaticDeviceModelDataSource as d}from"../../../api/device-model/data/StaticDeviceModelDataSource";import{deviceModelModuleFactory as r}from"./deviceModelModule";import{deviceModelTypes as i}from"./deviceModelTypes";describe("deviceModelModuleFactory",()=>{let e,o;beforeEach(()=>{o=r({stub:!1}),e=new c,e.loadSync(o)}),it("should return the device module",()=>{expect(o).toBeDefined()}),it("should return none mocked services and data sources",()=>{const t=e.get(i.DeviceModelDataSource);expect(t).toBeInstanceOf(d)})});
|
2
2
|
//# sourceMappingURL=deviceModelModule.test.js.map
|
@@ -1,7 +1,7 @@
|
|
1
1
|
{
|
2
2
|
"version": 3,
|
3
3
|
"sources": ["../../../../../../src/internal/device-model/di/deviceModelModule.test.ts"],
|
4
|
-
"sourcesContent": ["import { Container } from \"inversify\";\n\nimport { StaticDeviceModelDataSource } from \"@api/device-model/data/StaticDeviceModelDataSource\";\n\nimport { deviceModelModuleFactory } from \"./deviceModelModule\";\nimport { deviceModelTypes } from \"./deviceModelTypes\";\n\ndescribe(\"deviceModelModuleFactory\", () => {\n let container: Container;\n let mod: ReturnType<typeof deviceModelModuleFactory>;\n beforeEach(() => {\n mod = deviceModelModuleFactory({ stub: false });\n container = new Container();\n container.
|
5
|
-
"mappings": "AAAA,OAAS,aAAAA,MAAiB,YAE1B,OAAS,+BAAAC,MAAmC,qDAE5C,OAAS,4BAAAC,MAAgC,sBACzC,OAAS,oBAAAC,MAAwB,qBAEjC,SAAS,2BAA4B,IAAM,CACzC,IAAIC,EACAC,EACJ,WAAW,IAAM,CACfA,EAAMH,EAAyB,CAAE,KAAM,EAAM,CAAC,EAC9CE,EAAY,IAAIJ,EAChBI,EAAU,
|
4
|
+
"sourcesContent": ["import { Container } from \"inversify\";\n\nimport { StaticDeviceModelDataSource } from \"@api/device-model/data/StaticDeviceModelDataSource\";\n\nimport { deviceModelModuleFactory } from \"./deviceModelModule\";\nimport { deviceModelTypes } from \"./deviceModelTypes\";\n\ndescribe(\"deviceModelModuleFactory\", () => {\n let container: Container;\n let mod: ReturnType<typeof deviceModelModuleFactory>;\n beforeEach(() => {\n mod = deviceModelModuleFactory({ stub: false });\n container = new Container();\n container.loadSync(mod);\n });\n\n it(\"should return the device module\", () => {\n expect(mod).toBeDefined();\n });\n\n it(\"should return none mocked services and data sources\", () => {\n const deviceModelDataSource = container.get(\n deviceModelTypes.DeviceModelDataSource,\n );\n expect(deviceModelDataSource).toBeInstanceOf(StaticDeviceModelDataSource);\n });\n});\n"],
|
5
|
+
"mappings": "AAAA,OAAS,aAAAA,MAAiB,YAE1B,OAAS,+BAAAC,MAAmC,qDAE5C,OAAS,4BAAAC,MAAgC,sBACzC,OAAS,oBAAAC,MAAwB,qBAEjC,SAAS,2BAA4B,IAAM,CACzC,IAAIC,EACAC,EACJ,WAAW,IAAM,CACfA,EAAMH,EAAyB,CAAE,KAAM,EAAM,CAAC,EAC9CE,EAAY,IAAIJ,EAChBI,EAAU,SAASC,CAAG,CACxB,CAAC,EAED,GAAG,kCAAmC,IAAM,CAC1C,OAAOA,CAAG,EAAE,YAAY,CAC1B,CAAC,EAED,GAAG,sDAAuD,IAAM,CAC9D,MAAMC,EAAwBF,EAAU,IACtCD,EAAiB,qBACnB,EACA,OAAOG,CAAqB,EAAE,eAAeL,CAA2B,CAC1E,CAAC,CACH,CAAC",
|
6
6
|
"names": ["Container", "StaticDeviceModelDataSource", "deviceModelModuleFactory", "deviceModelTypes", "container", "mod", "deviceModelDataSource"]
|
7
7
|
}
|
@@ -1,2 +1,2 @@
|
|
1
|
-
const E=2;export{E as APDU_RESPONSE_STATUS_CODE_LENGTH};
|
1
|
+
const E=2,T=800;export{E as APDU_RESPONSE_STATUS_CODE_LENGTH,T as PINGER_TIMEOUT};
|
2
2
|
//# sourceMappingURL=ApduResponseConst.js.map
|
@@ -1,7 +1,7 @@
|
|
1
1
|
{
|
2
2
|
"version": 3,
|
3
3
|
"sources": ["../../../../../../src/internal/device-session/data/ApduResponseConst.ts"],
|
4
|
-
"sourcesContent": ["export const APDU_RESPONSE_STATUS_CODE_LENGTH = 2;\n"],
|
5
|
-
"mappings": "AAAO,MAAMA,EAAmC",
|
6
|
-
"names": ["APDU_RESPONSE_STATUS_CODE_LENGTH"]
|
4
|
+
"sourcesContent": ["export const APDU_RESPONSE_STATUS_CODE_LENGTH = 2;\nexport const PINGER_TIMEOUT = 800;\n"],
|
5
|
+
"mappings": "AAAO,MAAMA,EAAmC,EACnCC,EAAiB",
|
6
|
+
"names": ["APDU_RESPONSE_STATUS_CODE_LENGTH", "PINGER_TIMEOUT"]
|
7
7
|
}
|
@@ -1,2 +1,2 @@
|
|
1
|
-
import{ContainerModule as
|
1
|
+
import{ContainerModule as n}from"inversify";import{DisableDeviceSessionRefresherUseCase as a}from"../../../api/device-session/use-case/DisableDeviceSessionRefresher";import{DefaultApduReceiverService as u}from"../../device-session/service/DefaultApduReceiverService";import{DefaultApduSenderService as v}from"../../device-session/service/DefaultApduSenderService";import{DefaultDeviceSessionService as m}from"../../device-session/service/DefaultDeviceSessionService";import{CloseSessionsUseCase as g}from"../../device-session/use-case/CloseSessionsUseCase";import{GetDeviceSessionStateUseCase as l}from"../../device-session/use-case/GetDeviceSessionStateUseCase";import{loggerTypes as c}from"../../logger-publisher/di/loggerTypes";import{StubUseCase as S}from"../../../../src/di.stub";import{deviceSessionTypes as e}from"./deviceSessionTypes";const b=({stub:p}={stub:!1})=>new n(({bind:r,rebindSync:i})=>{r(e.ApduSenderServiceFactory).toFactory(o=>{const s=o.get(c.LoggerPublisherServiceFactory);return t=>new v(t,s)}),r(e.ApduReceiverServiceFactory).toFactory(o=>{const s=o.get(c.LoggerPublisherServiceFactory);return(t={})=>new u(t,s)}),r(e.DeviceSessionService).to(m).inSingletonScope(),r(e.GetDeviceSessionStateUseCase).to(l),r(e.CloseSessionsUseCase).to(g),r(e.DisableDeviceSessionRefresherUseCase).to(a),p&&(i(e.GetDeviceSessionStateUseCase).to(S),i(e.DisableDeviceSessionRefresherUseCase).to(S))});export{b as deviceSessionModuleFactory};
|
2
2
|
//# sourceMappingURL=deviceSessionModule.js.map
|
@@ -1,7 +1,7 @@
|
|
1
1
|
{
|
2
2
|
"version": 3,
|
3
3
|
"sources": ["../../../../../../src/internal/device-session/di/deviceSessionModule.ts"],
|
4
|
-
"sourcesContent": ["import { ContainerModule, type
|
5
|
-
"mappings": "AAAA,OAAS,mBAAAA,
|
6
|
-
"names": ["ContainerModule", "DisableDeviceSessionRefresherUseCase", "DefaultApduReceiverService", "DefaultApduSenderService", "DefaultDeviceSessionService", "CloseSessionsUseCase", "GetDeviceSessionStateUseCase", "loggerTypes", "StubUseCase", "deviceSessionTypes", "deviceSessionModuleFactory", "stub", "bind", "
|
4
|
+
"sourcesContent": ["import { ContainerModule, type Factory } from \"inversify\";\n\nimport { type ApduReceiverService } from \"@api/device-session/service/ApduReceiverService\";\nimport { type ApduReceiverConstructorArgs } from \"@api/device-session/service/ApduReceiverService\";\nimport { type ApduSenderService } from \"@api/device-session/service/ApduSenderService\";\nimport { type ApduSenderServiceConstructorArgs } from \"@api/device-session/service/ApduSenderService\";\nimport { DisableDeviceSessionRefresherUseCase } from \"@api/device-session/use-case/DisableDeviceSessionRefresher\";\nimport { type LoggerPublisherService } from \"@api/logger-publisher/service/LoggerPublisherService\";\nimport { DefaultApduReceiverService } from \"@internal/device-session/service/DefaultApduReceiverService\";\nimport { DefaultApduSenderService } from \"@internal/device-session/service/DefaultApduSenderService\";\nimport { DefaultDeviceSessionService } from \"@internal/device-session/service/DefaultDeviceSessionService\";\nimport { CloseSessionsUseCase } from \"@internal/device-session/use-case/CloseSessionsUseCase\";\nimport { GetDeviceSessionStateUseCase } from \"@internal/device-session/use-case/GetDeviceSessionStateUseCase\";\nimport { loggerTypes } from \"@internal/logger-publisher/di/loggerTypes\";\nimport { StubUseCase } from \"@root/src/di.stub\";\n\nimport { deviceSessionTypes } from \"./deviceSessionTypes\";\n\nexport type DeviceSessionModuleArgs = Partial<{\n stub: boolean;\n}>;\n\nexport const deviceSessionModuleFactory = (\n { stub }: DeviceSessionModuleArgs = { stub: false },\n) =>\n new ContainerModule(({ bind, rebindSync }) => {\n bind<Factory<ApduSenderService>>(\n deviceSessionTypes.ApduSenderServiceFactory,\n ).toFactory((context) => {\n const logger = context.get<(name: string) => LoggerPublisherService>(\n loggerTypes.LoggerPublisherServiceFactory,\n );\n\n return (args: ApduSenderServiceConstructorArgs) => {\n return new DefaultApduSenderService(args, logger);\n };\n });\n\n bind<Factory<ApduReceiverService>>(\n deviceSessionTypes.ApduReceiverServiceFactory,\n ).toFactory((context) => {\n const logger = context.get<(name: string) => LoggerPublisherService>(\n loggerTypes.LoggerPublisherServiceFactory,\n );\n\n return (args: ApduReceiverConstructorArgs = {}) => {\n return new DefaultApduReceiverService(args, logger);\n };\n });\n\n bind(deviceSessionTypes.DeviceSessionService)\n .to(DefaultDeviceSessionService)\n .inSingletonScope();\n\n bind(deviceSessionTypes.GetDeviceSessionStateUseCase).to(\n GetDeviceSessionStateUseCase,\n );\n bind(deviceSessionTypes.CloseSessionsUseCase).to(CloseSessionsUseCase);\n bind(deviceSessionTypes.DisableDeviceSessionRefresherUseCase).to(\n DisableDeviceSessionRefresherUseCase,\n );\n\n if (stub) {\n rebindSync(deviceSessionTypes.GetDeviceSessionStateUseCase).to(\n StubUseCase,\n );\n rebindSync(deviceSessionTypes.DisableDeviceSessionRefresherUseCase).to(\n StubUseCase,\n );\n }\n });\n"],
|
5
|
+
"mappings": "AAAA,OAAS,mBAAAA,MAAqC,YAM9C,OAAS,wCAAAC,MAA4C,6DAErD,OAAS,8BAAAC,MAAkC,8DAC3C,OAAS,4BAAAC,MAAgC,4DACzC,OAAS,+BAAAC,MAAmC,+DAC5C,OAAS,wBAAAC,MAA4B,yDACrC,OAAS,gCAAAC,MAAoC,iEAC7C,OAAS,eAAAC,MAAmB,4CAC5B,OAAS,eAAAC,MAAmB,oBAE5B,OAAS,sBAAAC,MAA0B,uBAM5B,MAAMC,EAA6B,CACxC,CAAE,KAAAC,CAAK,EAA6B,CAAE,KAAM,EAAM,IAElD,IAAIX,EAAgB,CAAC,CAAE,KAAAY,EAAM,WAAAC,CAAW,IAAM,CAC5CD,EACEH,EAAmB,wBACrB,EAAE,UAAWK,GAAY,CACvB,MAAMC,EAASD,EAAQ,IACrBP,EAAY,6BACd,EAEA,OAAQS,GACC,IAAIb,EAAyBa,EAAMD,CAAM,CAEpD,CAAC,EAEDH,EACEH,EAAmB,0BACrB,EAAE,UAAWK,GAAY,CACvB,MAAMC,EAASD,EAAQ,IACrBP,EAAY,6BACd,EAEA,MAAO,CAACS,EAAoC,CAAC,IACpC,IAAId,EAA2Bc,EAAMD,CAAM,CAEtD,CAAC,EAEDH,EAAKH,EAAmB,oBAAoB,EACzC,GAAGL,CAA2B,EAC9B,iBAAiB,EAEpBQ,EAAKH,EAAmB,4BAA4B,EAAE,GACpDH,CACF,EACAM,EAAKH,EAAmB,oBAAoB,EAAE,GAAGJ,CAAoB,EACrEO,EAAKH,EAAmB,oCAAoC,EAAE,GAC5DR,CACF,EAEIU,IACFE,EAAWJ,EAAmB,4BAA4B,EAAE,GAC1DD,CACF,EACAK,EAAWJ,EAAmB,oCAAoC,EAAE,GAClED,CACF,EAEJ,CAAC",
|
6
|
+
"names": ["ContainerModule", "DisableDeviceSessionRefresherUseCase", "DefaultApduReceiverService", "DefaultApduSenderService", "DefaultDeviceSessionService", "CloseSessionsUseCase", "GetDeviceSessionStateUseCase", "loggerTypes", "StubUseCase", "deviceSessionTypes", "deviceSessionModuleFactory", "stub", "bind", "rebindSync", "context", "logger", "args"]
|
7
7
|
}
|
@@ -1,2 +1,2 @@
|
|
1
|
-
import{Container as t}from"inversify";import{deviceSessionModuleFactory as i}from"./deviceSessionModule";describe("deviceSessionModuleFactory",()=>{describe("Default",()=>{let o,e;beforeEach(()=>{e=i(),o=new t,o.
|
1
|
+
import{Container as t}from"inversify";import{deviceSessionModuleFactory as i}from"./deviceSessionModule";describe("deviceSessionModuleFactory",()=>{describe("Default",()=>{let o,e;beforeEach(()=>{e=i(),o=new t,o.loadSync(e)}),it("should return the config module",()=>{expect(e).toBeDefined()})})});
|
2
2
|
//# sourceMappingURL=deviceSessionModule.test.js.map
|
@@ -1,7 +1,7 @@
|
|
1
1
|
{
|
2
2
|
"version": 3,
|
3
3
|
"sources": ["../../../../../../src/internal/device-session/di/deviceSessionModule.test.ts"],
|
4
|
-
"sourcesContent": ["import { Container } from \"inversify\";\n\nimport { deviceSessionModuleFactory } from \"./deviceSessionModule\";\n\ndescribe(\"deviceSessionModuleFactory\", () => {\n describe(\"Default\", () => {\n let container: Container;\n let mod: ReturnType<typeof deviceSessionModuleFactory>;\n beforeEach(() => {\n mod = deviceSessionModuleFactory();\n container = new Container();\n container.
|
5
|
-
"mappings": "AAAA,OAAS,aAAAA,MAAiB,YAE1B,OAAS,8BAAAC,MAAkC,wBAE3C,SAAS,6BAA8B,IAAM,CAC3C,SAAS,UAAW,IAAM,CACxB,IAAIC,EACAC,EACJ,WAAW,IAAM,CACfA,EAAMF,EAA2B,EACjCC,EAAY,IAAIF,EAChBE,EAAU,
|
4
|
+
"sourcesContent": ["import { Container } from \"inversify\";\n\nimport { deviceSessionModuleFactory } from \"./deviceSessionModule\";\n\ndescribe(\"deviceSessionModuleFactory\", () => {\n describe(\"Default\", () => {\n let container: Container;\n let mod: ReturnType<typeof deviceSessionModuleFactory>;\n beforeEach(() => {\n mod = deviceSessionModuleFactory();\n container = new Container();\n container.loadSync(mod);\n });\n\n it(\"should return the config module\", () => {\n expect(mod).toBeDefined();\n });\n });\n});\n"],
|
5
|
+
"mappings": "AAAA,OAAS,aAAAA,MAAiB,YAE1B,OAAS,8BAAAC,MAAkC,wBAE3C,SAAS,6BAA8B,IAAM,CAC3C,SAAS,UAAW,IAAM,CACxB,IAAIC,EACAC,EACJ,WAAW,IAAM,CACfA,EAAMF,EAA2B,EACjCC,EAAY,IAAIF,EAChBE,EAAU,SAASC,CAAG,CACxB,CAAC,EAED,GAAG,kCAAmC,IAAM,CAC1C,OAAOA,CAAG,EAAE,YAAY,CAC1B,CAAC,CACH,CAAC,CACH,CAAC",
|
6
6
|
"names": ["Container", "deviceSessionModuleFactory", "container", "mod"]
|
7
7
|
}
|
@@ -1,2 +1,2 @@
|
|
1
|
-
import{DeviceModelId as
|
1
|
+
import{DeviceModelId as c}from"../../../api/device/DeviceModel";import{GetAppAndVersionCommand as a,GetOsVersionCommand as m}from"../../../api/index";import{PINGER_TIMEOUT as o}from"../../device-session/data/ApduResponseConst";import{DEVICE_SESSION_REFRESHER_POLLING_INTERVAL as p}from"../../device-session/data/DeviceSessionRefresherConst";import{SessionEvents as i}from"../../device-session/model/DeviceSessionEventDispatcher";class D{constructor(e,t,r,n){this.connectedDevice=t;this._sessionEventDispatcher=r;this._sendCommandFunction=n,this._logger=e("device-pinger"),this._subscription=this._sessionEventDispatcher.listen().subscribe(async s=>await this.mapEventAction(s))}_sendCommandFunction;_subscription;_logger;async ping(){try{return await this.mapDevicePingAction(this.connectedDevice.deviceModel.id)}catch(e){throw this._logger.error("Error while pinging device",{data:{error:e}}),e}}mapEventAction=async e=>{switch(e.eventName){case i.REFRESH_NEEDED:return await this.ping();default:return null}};async mapDevicePingAction(e){switch(e){case c.NANO_S:{const t=async()=>{const s=await this._sendCommandFunction(new a,o);return this._sendCommandFunction(new m,o),s},r=new Promise(s=>{setTimeout(()=>s(null),p*2+100)}),n=await Promise.race([t(),r]);return n?this._sessionEventDispatcher.dispatch({eventName:i.COMMAND_SUCCEEDED,eventData:n}):this._sessionEventDispatcher.dispatch({eventName:i.DEVICE_STATE_UPDATE_LOCKED}),n}default:{const t=await this._sendCommandFunction(new a,o);return this._sessionEventDispatcher.dispatch({eventName:i.COMMAND_SUCCEEDED,eventData:t}),t}}}unsubscribe(){this._subscription.unsubscribe()}}export{D as DevicePinger};
|
2
2
|
//# sourceMappingURL=DevicePinger.js.map
|
@@ -1,7 +1,7 @@
|
|
1
1
|
{
|
2
2
|
"version": 3,
|
3
3
|
"sources": ["../../../../../../src/internal/device-session/model/DevicePinger.ts"],
|
4
|
-
"sourcesContent": ["import { type Subscription } from \"rxjs\";\n\nimport { DeviceModelId } from \"@api/device/DeviceModel\";\nimport {\n GetAppAndVersionCommand,\n type GetAppAndVersionResponse,\n GetOsVersionCommand,\n type TransportConnectedDevice,\n} from \"@api/index\";\nimport {\n type Command,\n type CommandResult,\n type LoggerPublisherService,\n} from \"@api/types\";\nimport { DEVICE_SESSION_REFRESHER_POLLING_INTERVAL } from \"@internal/device-session/data/DeviceSessionRefresherConst\";\nimport {\n type DeviceSessionEventDispatcher,\n type NewEvent,\n SessionEvents,\n} from \"@internal/device-session/model/DeviceSessionEventDispatcher\";\n\ntype SendCommandFunction = <Response, Args, ErrorStatusCodes>(\n command: Command<Response, Args, ErrorStatusCodes>,\n) => Promise<CommandResult<Response, ErrorStatusCodes>>;\n\nexport class DevicePinger {\n private readonly _sendCommandFunction: SendCommandFunction;\n private _subscription: Subscription;\n private _logger: LoggerPublisherService;\n\n constructor(\n loggerModuleFactory: (tag: string) => LoggerPublisherService,\n private connectedDevice: TransportConnectedDevice,\n private _sessionEventDispatcher: DeviceSessionEventDispatcher,\n sendCommandFunction: SendCommandFunction,\n ) {\n this._sendCommandFunction = sendCommandFunction;\n this._logger = loggerModuleFactory(\"device-pinger\");\n this._subscription = this._sessionEventDispatcher\n .listen()\n .subscribe(async (event) => await this.mapEventAction(event));\n }\n\n public async ping(): Promise<CommandResult<GetAppAndVersionResponse> | null> {\n try {\n const result = await this.mapDevicePingAction(\n this.connectedDevice.deviceModel.id,\n );\n return result;\n } catch (error) {\n this._logger.error(\"Error while pinging device\", {\n data: {\n error,\n },\n });\n throw error;\n }\n }\n\n private mapEventAction = async (event: NewEvent) => {\n switch (event.eventName) {\n case SessionEvents.REFRESH_NEEDED:\n return await this.ping();\n default:\n return null;\n }\n };\n\n private async mapDevicePingAction(deviceModelId: DeviceModelId) {\n switch (deviceModelId) {\n case DeviceModelId.NANO_S: {\n const chainPromise: Promise
|
5
|
-
"mappings": "AAEA,OAAS,iBAAAA,MAAqB,0BAC9B,OACE,2BAAAC,EAEA,uBAAAC,MAEK,aAMP,OAAS,6CAAAC,MAAiD,4DAC1D,OAGE,iBAAAC,MACK,
|
6
|
-
"names": ["DeviceModelId", "GetAppAndVersionCommand", "GetOsVersionCommand", "DEVICE_SESSION_REFRESHER_POLLING_INTERVAL", "SessionEvents", "DevicePinger", "loggerModuleFactory", "connectedDevice", "_sessionEventDispatcher", "sendCommandFunction", "event", "error", "deviceModelId", "chainPromise", "appVersionResult", "timeoutPromise", "resolve", "resultOrTimeout", "result"]
|
4
|
+
"sourcesContent": ["import { type Subscription } from \"rxjs\";\n\nimport { DeviceModelId } from \"@api/device/DeviceModel\";\nimport {\n GetAppAndVersionCommand,\n type GetAppAndVersionResponse,\n GetOsVersionCommand,\n type TransportConnectedDevice,\n} from \"@api/index\";\nimport {\n type Command,\n type CommandResult,\n type LoggerPublisherService,\n} from \"@api/types\";\nimport { PINGER_TIMEOUT } from \"@internal/device-session/data/ApduResponseConst\";\nimport { DEVICE_SESSION_REFRESHER_POLLING_INTERVAL } from \"@internal/device-session/data/DeviceSessionRefresherConst\";\nimport {\n type DeviceSessionEventDispatcher,\n type NewEvent,\n SessionEvents,\n} from \"@internal/device-session/model/DeviceSessionEventDispatcher\";\n\ntype SendCommandFunction = <Response, Args, ErrorStatusCodes>(\n command: Command<Response, Args, ErrorStatusCodes>,\n abortTimeout?: number,\n) => Promise<CommandResult<Response, ErrorStatusCodes>>;\n\nexport class DevicePinger {\n private readonly _sendCommandFunction: SendCommandFunction;\n private _subscription: Subscription;\n private _logger: LoggerPublisherService;\n\n constructor(\n loggerModuleFactory: (tag: string) => LoggerPublisherService,\n private connectedDevice: TransportConnectedDevice,\n private _sessionEventDispatcher: DeviceSessionEventDispatcher,\n sendCommandFunction: SendCommandFunction,\n ) {\n this._sendCommandFunction = sendCommandFunction;\n this._logger = loggerModuleFactory(\"device-pinger\");\n this._subscription = this._sessionEventDispatcher\n .listen()\n .subscribe(async (event) => await this.mapEventAction(event));\n }\n\n public async ping(): Promise<CommandResult<GetAppAndVersionResponse> | null> {\n try {\n const result = await this.mapDevicePingAction(\n this.connectedDevice.deviceModel.id,\n );\n return result;\n } catch (error) {\n this._logger.error(\"Error while pinging device\", {\n data: {\n error,\n },\n });\n throw error;\n }\n }\n\n private mapEventAction = async (event: NewEvent) => {\n switch (event.eventName) {\n case SessionEvents.REFRESH_NEEDED:\n return await this.ping();\n default:\n return null;\n }\n };\n\n private async mapDevicePingAction(deviceModelId: DeviceModelId) {\n switch (deviceModelId) {\n case DeviceModelId.NANO_S: {\n const chainPromise: () => Promise<\n CommandResult<GetAppAndVersionResponse>\n > = async () => {\n const appVersionResult = await this._sendCommandFunction(\n new GetAppAndVersionCommand(),\n PINGER_TIMEOUT,\n );\n\n this._sendCommandFunction(new GetOsVersionCommand(), PINGER_TIMEOUT);\n return appVersionResult;\n };\n\n const timeoutPromise: Promise<null> = new Promise((resolve) => {\n setTimeout(\n () => resolve(null),\n DEVICE_SESSION_REFRESHER_POLLING_INTERVAL * 2 + 100,\n );\n });\n\n const resultOrTimeout: CommandResult<GetAppAndVersionResponse> | null =\n await Promise.race([chainPromise(), timeoutPromise]);\n\n if (!resultOrTimeout) {\n this._sessionEventDispatcher.dispatch({\n eventName: SessionEvents.DEVICE_STATE_UPDATE_LOCKED,\n });\n } else {\n this._sessionEventDispatcher.dispatch({\n eventName: SessionEvents.COMMAND_SUCCEEDED,\n eventData: resultOrTimeout,\n });\n }\n return resultOrTimeout;\n }\n default: {\n const result = await this._sendCommandFunction(\n new GetAppAndVersionCommand(),\n PINGER_TIMEOUT,\n );\n this._sessionEventDispatcher.dispatch({\n eventName: SessionEvents.COMMAND_SUCCEEDED,\n eventData: result,\n });\n return result;\n }\n }\n }\n\n public unsubscribe(): void {\n this._subscription.unsubscribe();\n }\n}\n"],
|
5
|
+
"mappings": "AAEA,OAAS,iBAAAA,MAAqB,0BAC9B,OACE,2BAAAC,EAEA,uBAAAC,MAEK,aAMP,OAAS,kBAAAC,MAAsB,kDAC/B,OAAS,6CAAAC,MAAiD,4DAC1D,OAGE,iBAAAC,MACK,8DAOA,MAAMC,CAAa,CAKxB,YACEC,EACQC,EACAC,EACRC,EACA,CAHQ,qBAAAF,EACA,6BAAAC,EAGR,KAAK,qBAAuBC,EAC5B,KAAK,QAAUH,EAAoB,eAAe,EAClD,KAAK,cAAgB,KAAK,wBACvB,OAAO,EACP,UAAU,MAAOI,GAAU,MAAM,KAAK,eAAeA,CAAK,CAAC,CAChE,CAfiB,qBACT,cACA,QAeR,MAAa,MAAgE,CAC3E,GAAI,CAIF,OAHe,MAAM,KAAK,oBACxB,KAAK,gBAAgB,YAAY,EACnC,CAEF,OAASC,EAAO,CACd,WAAK,QAAQ,MAAM,6BAA8B,CAC/C,KAAM,CACJ,MAAAA,CACF,CACF,CAAC,EACKA,CACR,CACF,CAEQ,eAAiB,MAAOD,GAAoB,CAClD,OAAQA,EAAM,UAAW,CACvB,KAAKN,EAAc,eACjB,OAAO,MAAM,KAAK,KAAK,EACzB,QACE,OAAO,IACX,CACF,EAEA,MAAc,oBAAoBQ,EAA8B,CAC9D,OAAQA,EAAe,CACrB,KAAKb,EAAc,OAAQ,CACzB,MAAMc,EAEF,SAAY,CACd,MAAMC,EAAmB,MAAM,KAAK,qBAClC,IAAId,EACJE,CACF,EAEA,YAAK,qBAAqB,IAAID,EAAuBC,CAAc,EAC5DY,CACT,EAEMC,EAAgC,IAAI,QAASC,GAAY,CAC7D,WACE,IAAMA,EAAQ,IAAI,EAClBb,EAA4C,EAAI,GAClD,CACF,CAAC,EAEKc,EACJ,MAAM,QAAQ,KAAK,CAACJ,EAAa,EAAGE,CAAc,CAAC,EAErD,OAAKE,EAKH,KAAK,wBAAwB,SAAS,CACpC,UAAWb,EAAc,kBACzB,UAAWa,CACb,CAAC,EAPD,KAAK,wBAAwB,SAAS,CACpC,UAAWb,EAAc,0BAC3B,CAAC,EAOIa,CACT,CACA,QAAS,CACP,MAAMC,EAAS,MAAM,KAAK,qBACxB,IAAIlB,EACJE,CACF,EACA,YAAK,wBAAwB,SAAS,CACpC,UAAWE,EAAc,kBACzB,UAAWc,CACb,CAAC,EACMA,CACT,CACF,CACF,CAEO,aAAoB,CACzB,KAAK,cAAc,YAAY,CACjC,CACF",
|
6
|
+
"names": ["DeviceModelId", "GetAppAndVersionCommand", "GetOsVersionCommand", "PINGER_TIMEOUT", "DEVICE_SESSION_REFRESHER_POLLING_INTERVAL", "SessionEvents", "DevicePinger", "loggerModuleFactory", "connectedDevice", "_sessionEventDispatcher", "sendCommandFunction", "event", "error", "deviceModelId", "chainPromise", "appVersionResult", "timeoutPromise", "resolve", "resultOrTimeout", "result"]
|
7
7
|
}
|
@@ -1,2 +1,2 @@
|
|
1
|
-
import{BehaviorSubject as
|
1
|
+
import{BehaviorSubject as v}from"rxjs";import{v4 as d}from"uuid";import{CommandUtils as h}from"../../../api/command/utils/CommandUtils";import{DeviceStatus as c}from"../../../api/device/DeviceStatus";import{DeviceSessionStateType as S}from"../../../api/device-session/DeviceSessionState";import{DEVICE_SESSION_REFRESHER_DEFAULT_OPTIONS as u}from"../../device-session/data/DeviceSessionRefresherConst";import{MutexService as m}from"../../device-session/service/MutexService";import{RefresherService as D}from"../../device-session/service/RefresherService";import{DevicePinger as l}from"./DevicePinger";import{DeviceSessionEventDispatcher as _,SessionEvents as n}from"./DeviceSessionEventDispatcher";import{DeviceSessionRefresher as f}from"./DeviceSessionRefresher";import{DeviceSessionStateHandler as g}from"./DeviceSessionStateHandler";class V{_id;_connectedDevice;_deviceState;_managerApiService;_secureChannelService;_logger;_refresherOptions;_pinger;_deviceSessionRefresher;_refresherService;_commandMutex=new m;_sessionEventDispatcher=new _;constructor({connectedDevice:e,id:s=d()},t,i,r,a){this._id=s,this._connectedDevice=e,this._logger=t("device-session"),this._managerApiService=i,this._secureChannelService=r,this._refresherOptions={...u,...a},this._deviceState=new v({sessionStateType:S.Connected,deviceStatus:c.CONNECTED,deviceModelId:this._connectedDevice.deviceModel.id}),this._pinger=new l(t,e,this._sessionEventDispatcher,(o,p)=>this.sendCommand(o,p)),this._deviceSessionRefresher=new f(t,this._refresherOptions,this._sessionEventDispatcher,this._connectedDevice),new g(t,this._sessionEventDispatcher,this._connectedDevice,this._deviceState,o=>this.setDeviceSessionState(o)),this._refresherService=new D(t,{start:()=>this._deviceSessionRefresher.restartRefresher(),stop:()=>this._deviceSessionRefresher.stopRefresher()})}async initialiseSession(){try{await this._pinger.ping()}catch(e){throw this._logger.error("Error while initialising session",{data:{error:e}}),e}finally{this._refresherOptions.isRefresherDisabled||this._deviceSessionRefresher.startRefresher()}}get id(){return this._id}get connectedDevice(){return this._connectedDevice}get state(){return this._deviceState.asObservable()}getDeviceSessionState(){return this._deviceState.getValue()}setDeviceSessionState(e){this._deviceState.next(e)}async sendApdu(e,s={isPolling:!1,triggersDisconnection:!1,abortTimeout:void 0}){const t=await this._commandMutex.lock();try{this._sessionEventDispatcher.dispatch({eventName:n.DEVICE_STATE_UPDATE_BUSY});const i=await this._connectedDevice.sendApdu(e,s.triggersDisconnection,s.abortTimeout);return i.ifRight(r=>{h.isLockedDeviceResponse(r)?this._sessionEventDispatcher.dispatch({eventName:n.DEVICE_STATE_UPDATE_LOCKED}):this._sessionEventDispatcher.dispatch({eventName:n.DEVICE_STATE_UPDATE_CONNECTED})}).ifLeft(()=>{this._sessionEventDispatcher.dispatch({eventName:n.DEVICE_STATE_UPDATE_CONNECTED})}),i}finally{t()}}async sendCommand(e,s){const t=e.getApdu();return(await this.sendApdu(t.getRawApdu(),{isPolling:!1,triggersDisconnection:e.triggersDisconnection??!1,abortTimeout:s})).caseOf({Left:r=>{throw r},Right:r=>e.parseResponse(r,this._connectedDevice.deviceModel.id)})}executeDeviceAction(e){const{observable:s,cancel:t}=e._execute({sendApdu:async i=>this.sendApdu(i),sendCommand:async(i,r)=>this.sendCommand(i,r),getDeviceModel:()=>this._connectedDevice.deviceModel,getDeviceSessionState:()=>this._deviceState.getValue(),getDeviceSessionStateObservable:()=>this.state,setDeviceSessionState:i=>(this.setDeviceSessionState(i),this._deviceState.getValue()),disableRefresher:i=>this._refresherService.disableRefresher(i),getManagerApiService:()=>this._managerApiService,getSecureChannelService:()=>this._secureChannelService});return{observable:s,cancel:t}}close(){this._updateDeviceStatus(c.NOT_CONNECTED),this._deviceState.complete(),this._deviceSessionRefresher.stopRefresher()}disableRefresher(e){return this._refresherService.disableRefresher(e)}_updateDeviceStatus(e){const s=this._deviceState.getValue();this._deviceState.next({...s,deviceStatus:e})}}export{V as DeviceSession};
|
2
2
|
//# sourceMappingURL=DeviceSession.js.map
|
@@ -1,7 +1,7 @@
|
|
1
1
|
{
|
2
2
|
"version": 3,
|
3
3
|
"sources": ["../../../../../../src/internal/device-session/model/DeviceSession.ts"],
|
4
|
-
"sourcesContent": ["import { type Either } from \"purify-ts\";\nimport { BehaviorSubject, type Observable } from \"rxjs\";\nimport { v4 as uuidv4 } from \"uuid\";\n\nimport { type Command } from \"@api/command/Command\";\nimport { type CommandResult } from \"@api/command/model/CommandResult\";\nimport { CommandUtils } from \"@api/command/utils/CommandUtils\";\nimport { DeviceStatus } from \"@api/device/DeviceStatus\";\nimport {\n type DeviceAction,\n type DeviceActionIntermediateValue,\n type ExecuteDeviceActionReturnType,\n} from \"@api/device-action/DeviceAction\";\nimport { type ApduResponse } from \"@api/device-session/ApduResponse\";\nimport {\n type DeviceSessionState,\n DeviceSessionStateType,\n} from \"@api/device-session/DeviceSessionState\";\nimport { type DeviceSessionId } from \"@api/device-session/types\";\nimport { type DmkError } from \"@api/Error\";\nimport { type LoggerPublisherService } from \"@api/logger-publisher/service/LoggerPublisherService\";\nimport { type TransportConnectedDevice } from \"@api/transport/model/TransportConnectedDevice\";\nimport { DEVICE_SESSION_REFRESHER_DEFAULT_OPTIONS } from \"@internal/device-session/data/DeviceSessionRefresherConst\";\nimport { MutexService } from \"@internal/device-session/service/MutexService\";\nimport { RefresherService } from \"@internal/device-session/service/RefresherService\";\nimport { type ManagerApiService } from \"@internal/manager-api/service/ManagerApiService\";\nimport { type SecureChannelService } from \"@internal/secure-channel/service/SecureChannelService\";\n\nimport { DevicePinger } from \"./DevicePinger\";\nimport {\n DeviceSessionEventDispatcher,\n SessionEvents,\n} from \"./DeviceSessionEventDispatcher\";\nimport { DeviceSessionRefresher } from \"./DeviceSessionRefresher\";\nimport { DeviceSessionStateHandler } from \"./DeviceSessionStateHandler\";\n\nexport type SessionConstructorArgs = {\n connectedDevice: TransportConnectedDevice;\n id?: DeviceSessionId;\n};\n\nexport type DeviceSessionRefresherOptions = {\n isRefresherDisabled: boolean;\n pollingInterval?: number;\n};\n\ntype SendApduOptions = {\n isPolling?: boolean;\n triggersDisconnection?: boolean;\n};\n\n/**\n * Represents a session with a device.\n */\nexport class DeviceSession {\n private readonly _id: DeviceSessionId;\n private readonly _connectedDevice: TransportConnectedDevice;\n private readonly _deviceState: BehaviorSubject<DeviceSessionState>;\n private readonly _managerApiService: ManagerApiService;\n private readonly _secureChannelService: SecureChannelService;\n private readonly _logger: LoggerPublisherService;\n private readonly _refresherOptions: DeviceSessionRefresherOptions;\n private _pinger: DevicePinger;\n private _deviceSessionRefresher: DeviceSessionRefresher;\n private readonly _refresherService: RefresherService;\n private _commandMutex = new MutexService();\n private _sessionEventDispatcher = new DeviceSessionEventDispatcher();\n\n constructor(\n { connectedDevice, id = uuidv4() }: SessionConstructorArgs,\n loggerModuleFactory: (tag: string) => LoggerPublisherService,\n managerApiService: ManagerApiService,\n secureChannelService: SecureChannelService,\n deviceSessionRefresherOptions: DeviceSessionRefresherOptions | undefined,\n ) {\n this._id = id;\n this._connectedDevice = connectedDevice;\n this._logger = loggerModuleFactory(\"device-session\");\n this._managerApiService = managerApiService;\n this._secureChannelService = secureChannelService;\n this._refresherOptions = {\n ...DEVICE_SESSION_REFRESHER_DEFAULT_OPTIONS,\n ...deviceSessionRefresherOptions,\n };\n this._deviceState = new BehaviorSubject<DeviceSessionState>({\n sessionStateType: DeviceSessionStateType.Connected,\n deviceStatus: DeviceStatus.CONNECTED,\n deviceModelId: this._connectedDevice.deviceModel.id,\n });\n\n this._pinger = new DevicePinger(\n loggerModuleFactory,\n connectedDevice,\n this._sessionEventDispatcher,\n (command) => this.sendCommand(command),\n );\n this._deviceSessionRefresher = new DeviceSessionRefresher(\n loggerModuleFactory,\n this._refresherOptions,\n this._sessionEventDispatcher,\n this._connectedDevice,\n );\n new DeviceSessionStateHandler(\n loggerModuleFactory,\n this._sessionEventDispatcher,\n this._connectedDevice,\n this._deviceState,\n (state) => this.setDeviceSessionState(state),\n );\n\n this._refresherService = new RefresherService(loggerModuleFactory, {\n start: () => this._deviceSessionRefresher.restartRefresher(),\n stop: () => this._deviceSessionRefresher.stopRefresher(),\n });\n }\n\n public async initialiseSession(): Promise<void> {\n try {\n await this._pinger.ping();\n } catch (error) {\n this._logger.error(\"Error while initialising session\", {\n data: { error },\n });\n throw error;\n } finally {\n if (!this._refresherOptions.isRefresherDisabled) {\n this._deviceSessionRefresher.startRefresher();\n }\n }\n }\n\n public get id(): DeviceSessionId {\n return this._id;\n }\n\n public get connectedDevice(): TransportConnectedDevice {\n return this._connectedDevice;\n }\n\n public get state(): Observable<DeviceSessionState> {\n return this._deviceState.asObservable();\n }\n\n public setDeviceSessionState(state: DeviceSessionState): void {\n this._deviceState.next(state);\n }\n\n public async sendApdu(\n rawApdu: Uint8Array,\n options: SendApduOptions = {\n isPolling: false,\n triggersDisconnection: false,\n },\n ): Promise<Either<DmkError, ApduResponse>> {\n const release = await this._commandMutex.lock();\n\n try {\n this._sessionEventDispatcher.dispatch({\n eventName: SessionEvents.DEVICE_STATE_UPDATE_BUSY,\n });\n const result = await this._connectedDevice.sendApdu(\n rawApdu,\n options.triggersDisconnection,\n );\n\n result\n .ifRight((response: ApduResponse) => {\n if (CommandUtils.isLockedDeviceResponse(response)) {\n this._sessionEventDispatcher.dispatch({\n eventName: SessionEvents.DEVICE_STATE_UPDATE_LOCKED,\n });\n } else {\n this._sessionEventDispatcher.dispatch({\n eventName: SessionEvents.DEVICE_STATE_UPDATE_CONNECTED,\n });\n }\n })\n .ifLeft(() => {\n this._sessionEventDispatcher.dispatch({\n eventName: SessionEvents.DEVICE_STATE_UPDATE_CONNECTED,\n });\n });\n return result;\n } finally {\n release();\n }\n }\n\n public async sendCommand<Response, Args, ErrorStatusCodes>(\n command: Command<Response, Args, ErrorStatusCodes>,\n ): Promise<CommandResult<Response, ErrorStatusCodes>> {\n const apdu = command.getApdu();\n\n const response = await this.sendApdu(apdu.getRawApdu(), {\n isPolling: false,\n triggersDisconnection: command.triggersDisconnection ?? false,\n });\n\n return response.caseOf({\n Left: (err) => {\n throw err;\n },\n Right: (r) =>\n command.parseResponse(r, this._connectedDevice.deviceModel.id),\n });\n }\n\n public executeDeviceAction<\n Output,\n Input,\n E extends DmkError,\n IntermediateValue extends DeviceActionIntermediateValue,\n >(\n deviceAction: DeviceAction<Output, Input, E, IntermediateValue>,\n ): ExecuteDeviceActionReturnType<Output, E, IntermediateValue> {\n const { observable, cancel } = deviceAction._execute({\n sendApdu: async (apdu: Uint8Array) => this.sendApdu(apdu),\n sendCommand: async <Response, ErrorStatusCodes, Args>(\n command: Command<Response, ErrorStatusCodes, Args>,\n ) => this.sendCommand(command),\n getDeviceSessionState: () => this._deviceState.getValue(),\n getDeviceSessionStateObservable: () => this.state,\n setDeviceSessionState: (state: DeviceSessionState) => {\n this.setDeviceSessionState(state);\n return this._deviceState.getValue();\n },\n disableRefresher: (blockerId: string) =>\n this._refresherService.disableRefresher(blockerId),\n getManagerApiService: () => this._managerApiService,\n getSecureChannelService: () => this._secureChannelService,\n });\n return { observable, cancel };\n }\n\n public close(): void {\n this._updateDeviceStatus(DeviceStatus.NOT_CONNECTED);\n this._deviceState.complete();\n this._deviceSessionRefresher.stopRefresher();\n }\n\n public disableRefresher(id: string): () => void {\n return this._refresherService.disableRefresher(id);\n }\n\n private _updateDeviceStatus(deviceStatus: DeviceStatus): void {\n const state = this._deviceState.getValue();\n this._deviceState.next({ ...state, deviceStatus });\n }\n}\n"],
|
5
|
-
"mappings": "AACA,OAAS,mBAAAA,MAAwC,OACjD,OAAS,MAAMC,MAAc,OAI7B,OAAS,gBAAAC,MAAoB,kCAC7B,OAAS,gBAAAC,MAAoB,2BAO7B,OAEE,0BAAAC,MACK,yCAKP,OAAS,4CAAAC,MAAgD,4DACzD,OAAS,gBAAAC,MAAoB,gDAC7B,OAAS,oBAAAC,MAAwB,oDAIjC,OAAS,gBAAAC,MAAoB,iBAC7B,OACE,gCAAAC,EACA,iBAAAC,MACK,iCACP,OAAS,0BAAAC,MAA8B,2BACvC,OAAS,6BAAAC,MAAiC,
|
6
|
-
"names": ["BehaviorSubject", "uuidv4", "CommandUtils", "DeviceStatus", "DeviceSessionStateType", "DEVICE_SESSION_REFRESHER_DEFAULT_OPTIONS", "MutexService", "RefresherService", "DevicePinger", "DeviceSessionEventDispatcher", "SessionEvents", "DeviceSessionRefresher", "DeviceSessionStateHandler", "DeviceSession", "connectedDevice", "id", "loggerModuleFactory", "managerApiService", "secureChannelService", "deviceSessionRefresherOptions", "command", "state", "error", "rawApdu", "options", "release", "result", "response", "apdu", "err", "
|
4
|
+
"sourcesContent": ["import { type Either } from \"purify-ts\";\nimport { BehaviorSubject, type Observable } from \"rxjs\";\nimport { v4 as uuidv4 } from \"uuid\";\n\nimport { type Command } from \"@api/command/Command\";\nimport { type CommandResult } from \"@api/command/model/CommandResult\";\nimport { CommandUtils } from \"@api/command/utils/CommandUtils\";\nimport { DeviceStatus } from \"@api/device/DeviceStatus\";\nimport {\n type DeviceAction,\n type DeviceActionIntermediateValue,\n type ExecuteDeviceActionReturnType,\n} from \"@api/device-action/DeviceAction\";\nimport { type ApduResponse } from \"@api/device-session/ApduResponse\";\nimport {\n type DeviceSessionState,\n DeviceSessionStateType,\n} from \"@api/device-session/DeviceSessionState\";\nimport { type DeviceSessionId } from \"@api/device-session/types\";\nimport { type DmkError } from \"@api/Error\";\nimport { type LoggerPublisherService } from \"@api/logger-publisher/service/LoggerPublisherService\";\nimport { type TransportConnectedDevice } from \"@api/transport/model/TransportConnectedDevice\";\nimport { DEVICE_SESSION_REFRESHER_DEFAULT_OPTIONS } from \"@internal/device-session/data/DeviceSessionRefresherConst\";\nimport { MutexService } from \"@internal/device-session/service/MutexService\";\nimport { RefresherService } from \"@internal/device-session/service/RefresherService\";\nimport { type ManagerApiService } from \"@internal/manager-api/service/ManagerApiService\";\nimport { type SecureChannelService } from \"@internal/secure-channel/service/SecureChannelService\";\n\nimport { DevicePinger } from \"./DevicePinger\";\nimport {\n DeviceSessionEventDispatcher,\n SessionEvents,\n} from \"./DeviceSessionEventDispatcher\";\nimport { DeviceSessionRefresher } from \"./DeviceSessionRefresher\";\nimport { DeviceSessionStateHandler } from \"./DeviceSessionStateHandler\";\n\nexport type SessionConstructorArgs = {\n connectedDevice: TransportConnectedDevice;\n id?: DeviceSessionId;\n};\n\nexport type DeviceSessionRefresherOptions = {\n isRefresherDisabled: boolean;\n pollingInterval?: number;\n};\n\ntype SendApduOptions = {\n isPolling?: boolean;\n triggersDisconnection?: boolean;\n abortTimeout?: number;\n};\n\n/**\n * Represents a session with a device.\n */\nexport class DeviceSession {\n private readonly _id: DeviceSessionId;\n private readonly _connectedDevice: TransportConnectedDevice;\n private readonly _deviceState: BehaviorSubject<DeviceSessionState>;\n private readonly _managerApiService: ManagerApiService;\n private readonly _secureChannelService: SecureChannelService;\n private readonly _logger: LoggerPublisherService;\n private readonly _refresherOptions: DeviceSessionRefresherOptions;\n private _pinger: DevicePinger;\n private _deviceSessionRefresher: DeviceSessionRefresher;\n private readonly _refresherService: RefresherService;\n private _commandMutex = new MutexService();\n private _sessionEventDispatcher = new DeviceSessionEventDispatcher();\n\n constructor(\n { connectedDevice, id = uuidv4() }: SessionConstructorArgs,\n loggerModuleFactory: (tag: string) => LoggerPublisherService,\n managerApiService: ManagerApiService,\n secureChannelService: SecureChannelService,\n deviceSessionRefresherOptions: DeviceSessionRefresherOptions | undefined,\n ) {\n this._id = id;\n this._connectedDevice = connectedDevice;\n this._logger = loggerModuleFactory(\"device-session\");\n this._managerApiService = managerApiService;\n this._secureChannelService = secureChannelService;\n this._refresherOptions = {\n ...DEVICE_SESSION_REFRESHER_DEFAULT_OPTIONS,\n ...deviceSessionRefresherOptions,\n };\n this._deviceState = new BehaviorSubject<DeviceSessionState>({\n sessionStateType: DeviceSessionStateType.Connected,\n deviceStatus: DeviceStatus.CONNECTED,\n deviceModelId: this._connectedDevice.deviceModel.id,\n });\n\n this._pinger = new DevicePinger(\n loggerModuleFactory,\n connectedDevice,\n this._sessionEventDispatcher,\n (command, abortTimeout) => this.sendCommand(command, abortTimeout),\n );\n this._deviceSessionRefresher = new DeviceSessionRefresher(\n loggerModuleFactory,\n this._refresherOptions,\n this._sessionEventDispatcher,\n this._connectedDevice,\n );\n new DeviceSessionStateHandler(\n loggerModuleFactory,\n this._sessionEventDispatcher,\n this._connectedDevice,\n this._deviceState,\n (state) => this.setDeviceSessionState(state),\n );\n\n this._refresherService = new RefresherService(loggerModuleFactory, {\n start: () => this._deviceSessionRefresher.restartRefresher(),\n stop: () => this._deviceSessionRefresher.stopRefresher(),\n });\n }\n\n public async initialiseSession(): Promise<void> {\n try {\n await this._pinger.ping();\n } catch (error) {\n this._logger.error(\"Error while initialising session\", {\n data: { error },\n });\n throw error;\n } finally {\n if (!this._refresherOptions.isRefresherDisabled) {\n this._deviceSessionRefresher.startRefresher();\n }\n }\n }\n\n public get id(): DeviceSessionId {\n return this._id;\n }\n\n public get connectedDevice(): TransportConnectedDevice {\n return this._connectedDevice;\n }\n\n public get state(): Observable<DeviceSessionState> {\n return this._deviceState.asObservable();\n }\n\n public getDeviceSessionState(): DeviceSessionState {\n return this._deviceState.getValue();\n }\n\n public setDeviceSessionState(state: DeviceSessionState): void {\n this._deviceState.next(state);\n }\n\n public async sendApdu(\n rawApdu: Uint8Array,\n options: SendApduOptions = {\n isPolling: false,\n triggersDisconnection: false,\n abortTimeout: undefined,\n },\n ): Promise<Either<DmkError, ApduResponse>> {\n const release = await this._commandMutex.lock();\n\n try {\n this._sessionEventDispatcher.dispatch({\n eventName: SessionEvents.DEVICE_STATE_UPDATE_BUSY,\n });\n const result = await this._connectedDevice.sendApdu(\n rawApdu,\n options.triggersDisconnection,\n options.abortTimeout,\n );\n\n result\n .ifRight((response: ApduResponse) => {\n if (CommandUtils.isLockedDeviceResponse(response)) {\n this._sessionEventDispatcher.dispatch({\n eventName: SessionEvents.DEVICE_STATE_UPDATE_LOCKED,\n });\n } else {\n this._sessionEventDispatcher.dispatch({\n eventName: SessionEvents.DEVICE_STATE_UPDATE_CONNECTED,\n });\n }\n })\n .ifLeft(() => {\n this._sessionEventDispatcher.dispatch({\n eventName: SessionEvents.DEVICE_STATE_UPDATE_CONNECTED,\n });\n });\n return result;\n } finally {\n release();\n }\n }\n\n public async sendCommand<Response, Args, ErrorStatusCodes>(\n command: Command<Response, Args, ErrorStatusCodes>,\n abortTimeout?: number,\n ): Promise<CommandResult<Response, ErrorStatusCodes>> {\n const apdu = command.getApdu();\n\n const response = await this.sendApdu(apdu.getRawApdu(), {\n isPolling: false,\n triggersDisconnection: command.triggersDisconnection ?? false,\n abortTimeout,\n });\n\n return response.caseOf({\n Left: (err) => {\n throw err;\n },\n Right: (r) =>\n command.parseResponse(r, this._connectedDevice.deviceModel.id),\n });\n }\n\n public executeDeviceAction<\n Output,\n Input,\n E extends DmkError,\n IntermediateValue extends DeviceActionIntermediateValue,\n >(\n deviceAction: DeviceAction<Output, Input, E, IntermediateValue>,\n ): ExecuteDeviceActionReturnType<Output, E, IntermediateValue> {\n const { observable, cancel } = deviceAction._execute({\n sendApdu: async (apdu: Uint8Array) => this.sendApdu(apdu),\n sendCommand: async <Response, ErrorStatusCodes, Args>(\n command: Command<Response, ErrorStatusCodes, Args>,\n abortTimeout?: number,\n ) => this.sendCommand(command, abortTimeout),\n getDeviceModel: () => this._connectedDevice.deviceModel,\n getDeviceSessionState: () => this._deviceState.getValue(),\n getDeviceSessionStateObservable: () => this.state,\n setDeviceSessionState: (state: DeviceSessionState) => {\n this.setDeviceSessionState(state);\n return this._deviceState.getValue();\n },\n disableRefresher: (blockerId: string) =>\n this._refresherService.disableRefresher(blockerId),\n getManagerApiService: () => this._managerApiService,\n getSecureChannelService: () => this._secureChannelService,\n });\n return { observable, cancel };\n }\n\n public close(): void {\n this._updateDeviceStatus(DeviceStatus.NOT_CONNECTED);\n this._deviceState.complete();\n this._deviceSessionRefresher.stopRefresher();\n }\n\n public disableRefresher(id: string): () => void {\n return this._refresherService.disableRefresher(id);\n }\n\n private _updateDeviceStatus(deviceStatus: DeviceStatus): void {\n const state = this._deviceState.getValue();\n this._deviceState.next({ ...state, deviceStatus });\n }\n}\n"],
|
5
|
+
"mappings": "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",
|
6
|
+
"names": ["BehaviorSubject", "uuidv4", "CommandUtils", "DeviceStatus", "DeviceSessionStateType", "DEVICE_SESSION_REFRESHER_DEFAULT_OPTIONS", "MutexService", "RefresherService", "DevicePinger", "DeviceSessionEventDispatcher", "SessionEvents", "DeviceSessionRefresher", "DeviceSessionStateHandler", "DeviceSession", "connectedDevice", "id", "loggerModuleFactory", "managerApiService", "secureChannelService", "deviceSessionRefresherOptions", "command", "abortTimeout", "state", "error", "rawApdu", "options", "release", "result", "response", "apdu", "err", "deviceAction", "observable", "cancel", "blockerId", "deviceStatus"]
|
7
7
|
}
|