Package oshi.driver.windows.registry
Class ProcessPerformanceData
- java.lang.Object
-
- oshi.driver.windows.registry.ProcessPerformanceData
-
@ThreadSafe public final class ProcessPerformanceData extends java.lang.Object
Utility to read process data from HKEY_PERFORMANCE_DATA information with backup from Performance Counters or WMI
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
ProcessPerformanceData.PerfCounterBlock
Class to encapsulate data from the registry performance counter block
-
Constructor Summary
Constructors Modifier Constructor Description private
ProcessPerformanceData()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static java.util.Map<java.lang.Integer,ProcessPerformanceData.PerfCounterBlock>
buildProcessMapFromPerfCounters(java.util.Collection<java.lang.Integer> pids)
Query PerfMon for process performance countersstatic java.util.Map<java.lang.Integer,ProcessPerformanceData.PerfCounterBlock>
buildProcessMapFromPerfCounters(java.util.Collection<java.lang.Integer> pids, java.lang.String procName)
Query PerfMon for process performance countersstatic java.util.Map<java.lang.Integer,ProcessPerformanceData.PerfCounterBlock>
buildProcessMapFromRegistry(java.util.Collection<java.lang.Integer> pids)
Query the registry for process performance counters
-
-
-
Field Detail
-
PROCESS
private static final java.lang.String PROCESS
- See Also:
- Constant Field Values
-
PERFDATA
private static final boolean PERFDATA
-
-
Method Detail
-
buildProcessMapFromRegistry
public static java.util.Map<java.lang.Integer,ProcessPerformanceData.PerfCounterBlock> buildProcessMapFromRegistry(java.util.Collection<java.lang.Integer> pids)
Query the registry for process performance counters- Parameters:
pids
- An optional collection of process IDs to filter the list to. May be null for no filtering.- Returns:
- A map with Process ID as the key and a
ProcessPerformanceData.PerfCounterBlock
object populated with performance counter information if successful, or null otherwise.
-
buildProcessMapFromPerfCounters
public static java.util.Map<java.lang.Integer,ProcessPerformanceData.PerfCounterBlock> buildProcessMapFromPerfCounters(java.util.Collection<java.lang.Integer> pids)
Query PerfMon for process performance counters- Parameters:
pids
- An optional collection of process IDs to filter the list to. May be null for no filtering.- Returns:
- A map with Process ID as the key and a
ProcessPerformanceData.PerfCounterBlock
object populated with performance counter information.
-
buildProcessMapFromPerfCounters
public static java.util.Map<java.lang.Integer,ProcessPerformanceData.PerfCounterBlock> buildProcessMapFromPerfCounters(java.util.Collection<java.lang.Integer> pids, java.lang.String procName)
Query PerfMon for process performance counters- Parameters:
pids
- An optional collection of process IDs to filter the list to. May be null for no filtering.procName
- Filter by this process name.- Returns:
- A map with Process ID as the key and a
ProcessPerformanceData.PerfCounterBlock
object populated with performance counter information.
-
-