decord/source/modules/device/DeviceState.tsx
2026-09-01 10:26:29 +00:00

37 lines
1.3 KiB
TypeScript

// Module ID: 7494
// Function ID: 7495
// Name: DeviceState
// Dependencies: [7495, 2, 7496]
// Exports: logDeviceState
// Module 7494 (DeviceState)
import set from "set" /* 2 */;
import _getDeviceState from "_getDeviceState" /* 7495 */;
import ThermalState from "ThermalState" /* 7496 */;
const result = set.fileFinishedImporting("modules/device/DeviceState.tsx");
export const DeviceState = ThermalState.DeviceState;
export const ThermalState = ThermalState.ThermalState;
export const getDeviceState = _getDeviceState.getDeviceState;
export const logDeviceState = function logDeviceState(thermalState) {
if (null !== thermalState) {
const logger2 = _getDeviceState.logger;
logger2.info("Device State Information:");
const logger3 = _getDeviceState.logger;
const _HermesInternal = HermesInternal;
logger3.info("- Thermal State: " + thermalState.thermalState);
const logger4 = _getDeviceState.logger;
const _HermesInternal2 = HermesInternal;
logger4.info("- Battery Level: " + 100 * thermalState.batteryLevel + "%");
const logger5 = _getDeviceState.logger;
let str6 = "Disabled";
if (thermalState.isLowPowerMode) {
str6 = "Enabled";
}
logger5.info(`- Low Power Mode: ${str6}`);
} else {
const logger = _getDeviceState.logger;
logger.info("Device state not available");
}
};