java.lang.Object
com.aoindustries.noc.monitor.common.Result
com.aoindustries.noc.monitor.common.TableMultiResult
com.aoindustries.noc.monitor.common.UpsResult
- All Implemented Interfaces:
Serializable
Field descriptions copied from http://www.apcupsd.com/manual/manual.html#status-report-fields.
- Author:
- AO Industries, Inc.
- See Also:
-
Field Summary
-
Constructor Summary
ConstructorsConstructorDescriptionUpsResult(long time, long latency, AlertLevel alertLevel, String error) UpsResult(long time, long latency, AlertLevel alertLevel, String upsname, String status, float linev, float lotrans, float hitrans, float linefreq, float outputv, float nomoutv, float loadpct, float bcharge, float battv, float nombattv, int extbatts, int badbatts, MilliInterval tonbatt, MilliInterval cumonbatt, MilliInterval timeleft, float itemp) -
Method Summary
Modifier and TypeMethodDescriptionintGets the number of bad battery packs.floatgetBattv()Gets the battery voltage as supplied by the UPS.floatGets the percentage charge on the batteries.Gets the cumulative time on batteries since apcupsd started.intGets the number of external batteries as defined by the user.floatGets the line voltage above which the UPS will switch to batteries.floatgetItemp()Gets the internal UPS temperature as supplied by the UPS.floatGets the line frequency in hertz as given by the UPS.floatgetLinev()Gets the current line voltage as returned by the UPS.floatGets the percentage of load capacity as estimated by the UPS.floatGets the line voltage below which the UPS will switch to batteries.floatGets the nominal battery voltage.floatGets the output voltage that the UPS will attempt to supply when on battery power.floatGets the voltage the UPS is supplying to your equipment.getRowData(int index) Gets the data for one row.intGets the number of data elements for this result.Gets the current status of the UPS (ONLINE, CHARGING, ONBATT, etc.).Gets the remaining runtime left on batteries as estimated by the UPS.Gets the time currently on batteries.Gets the name of the UPS as stored in the EEPROM or in the UPSNAME directive in the configuration file.Methods inherited from class com.aoindustries.noc.monitor.common.TableMultiResult
getAlertLevel, getErrorMethods inherited from class com.aoindustries.noc.monitor.common.Result
getLatency, getTime
-
Constructor Details
-
UpsResult
-
UpsResult
public UpsResult(long time, long latency, AlertLevel alertLevel, String upsname, String status, float linev, float lotrans, float hitrans, float linefreq, float outputv, float nomoutv, float loadpct, float bcharge, float battv, float nombattv, int extbatts, int badbatts, MilliInterval tonbatt, MilliInterval cumonbatt, MilliInterval timeleft, float itemp)
-
-
Method Details
-
getRowDataSize
public int getRowDataSize()Description copied from class:TableMultiResultGets the number of data elements for this result.- Specified by:
getRowDataSizein classTableMultiResult
-
getRowData
Description copied from class:TableMultiResultGets the data for one row. This should not include the time and latency, they are implied. When there is an error, getRowData will not be checked and should return null.- Specified by:
getRowDatain classTableMultiResult
-
getUpsname
Gets the name of the UPS as stored in the EEPROM or in the UPSNAME directive in the configuration file.- Returns:
- the UPSNAME or
nullif unavailable.
-
getStatus
Gets the current status of the UPS (ONLINE, CHARGING, ONBATT, etc.).- Returns:
- the STATUS or
nullif unavailable.
-
getLinev
public float getLinev()Gets the current line voltage as returned by the UPS.- Returns:
- the LINEV or
Float.NaNif unavailable.
-
getLotrans
public float getLotrans()Gets the line voltage below which the UPS will switch to batteries.- Returns:
- the LOTRANS or
Float.NaNif unavailable.
-
getHitrans
public float getHitrans()Gets the line voltage above which the UPS will switch to batteries.- Returns:
- the HITRANS or
Float.NaNif unavailable.
-
getLinefreq
public float getLinefreq()Gets the line frequency in hertz as given by the UPS.- Returns:
- the LINEFREQ or
Float.NaNif unavailable.
-
getOutputv
public float getOutputv()Gets the voltage the UPS is supplying to your equipment.- Returns:
- the OUTPUTV or
Float.NaNif unavailable.
-
getNomoutv
public float getNomoutv()Gets the output voltage that the UPS will attempt to supply when on battery power.- Returns:
- the NOMOUTV or
Float.NaNif unavailable.
-
getLoadpct
public float getLoadpct()Gets the percentage of load capacity as estimated by the UPS.- Returns:
- the LOADPCT or
Float.NaNif unavailable.
-
getBcharge
public float getBcharge()Gets the percentage charge on the batteries.- Returns:
- the BCHARGE or
Float.NaNif unavailable.
-
getBattv
public float getBattv()Gets the battery voltage as supplied by the UPS.- Returns:
- the BATTV or
Float.NaNif unavailable.
-
getNombattv
public float getNombattv()Gets the nominal battery voltage.- Returns:
- the NOMBATTV or
Float.NaNif unavailable.
-
getExtbatts
public int getExtbatts()Gets the number of external batteries as defined by the user. A correct number here helps the UPS compute the remaining runtime more accurately.- Returns:
- the EXTBATTS or
-1if unavailable.
-
getBadbatts
public int getBadbatts()Gets the number of bad battery packs.- Returns:
- the BADBATTS or
-1if unavailable.
-
getTonbatt
Gets the time currently on batteries.- Returns:
- the TONBATT or
nullif unavailable.
-
getCumonbatt
Gets the cumulative time on batteries since apcupsd started.- Returns:
- the CUMONBATT or
nullif unavailable.
-
getTimeleft
Gets the remaining runtime left on batteries as estimated by the UPS.- Returns:
- the TIMELEFT or
nullif unavailable.
-
getItemp
public float getItemp()Gets the internal UPS temperature as supplied by the UPS.- Returns:
- the ITEMP or
Float.NaNif unavailable.
-
