Class LinuxPowerSource

java.lang.Object
oshi.hardware.common.AbstractPowerSource
oshi.hardware.platform.linux.LinuxPowerSource
All Implemented Interfaces:
PowerSource

@ThreadSafe
public final class LinuxPowerSource
extends AbstractPowerSource
A Power Source
  • Constructor Details

    • LinuxPowerSource

      public LinuxPowerSource​(java.lang.String psName, java.lang.String psDeviceName, double psRemainingCapacityPercent, double psTimeRemainingEstimated, double psTimeRemainingInstant, double psPowerUsageRate, double psVoltage, double psAmperage, boolean psPowerOnLine, boolean psCharging, boolean psDischarging, PowerSource.CapacityUnits psCapacityUnits, int psCurrentCapacity, int psMaxCapacity, int psDesignCapacity, int psCycleCount, java.lang.String psChemistry, java.time.LocalDate psManufactureDate, java.lang.String psManufacturer, java.lang.String psSerialNumber, double psTemperature)
  • Method Details

    • getPowerSources

      public static PowerSource[] getPowerSources()
      Gets Battery Information
      Returns:
      An array of PowerSource objects representing batteries, etc.