Class OhmSensor

java.lang.Object
oshi.driver.common.windows.wmi.OhmSensor

@ThreadSafe public class OhmSensor extends Object
Constants, property enum, and WHERE clause builder for Open Hardware Monitor WMI Sensor data.
  • Field Details

  • Constructor Details

    • OhmSensor

      protected OhmSensor()
      Constructor.
  • Method Details

    • buildSensorWmiClassNameWithWhere

      public static String buildSensorWmiClassNameWithWhere(String identifier, String sensorType)
      Builds the WMI class name with WHERE clause for sensor value queries.
      Parameters:
      identifier - The identifier whose value to query
      sensorType - The type of sensor to query
      Returns:
      the WMI class name with WHERE clause
    • querySensorValue

      public static WmiResult<OhmSensor.ValueProperty> querySensorValue(WmiQueryExecutor h, String identifier, String sensorType)
      Queries the sensor value of a hardware identifier and sensor type.
      Parameters:
      h - An instantiated WmiQueryExecutor. User should have already initialized COM.
      identifier - The identifier whose value to query.
      sensorType - The type of sensor to query.
      Returns:
      The sensor value.