Interface UnixOperatingSystemMXBean
- All Superinterfaces:
OperatingSystemMXBean, OperatingSystemMXBean, OperatingSystemMXBean, PlatformManagedObject, UnixOperatingSystemMXBean
- All Known Implementing Classes:
UnixExtendedOperatingSystem
Interface provides platform-specific management utilities on Unix and Unix-like
operating systems.
- Since:
- 1.8
-
Method Summary
Modifier and TypeMethodDescriptionlongReturns the maximum number of file descriptors that can be opened in a process.longReturns the current number of file descriptors that are in opened state.Methods declared in interface OperatingSystemMXBean
getCommittedVirtualMemorySize, getFreeSwapSpaceSize, getHardwareModel, getProcessCpuLoad, getProcessCpuTime, getProcessingCapacity, getProcessPhysicalMemorySize, getProcessPrivateMemorySize, getTotalSwapSpaceSize, isHardwareEmulated, isProcessRunning, retrieveMemoryUsage, retrieveMemoryUsage, retrieveProcessorUsage, retrieveProcessorUsage, retrieveTotalProcessorUsage, retrieveTotalProcessorUsageModifier and TypeMethodDescriptionlongReturns the amount of virtual memory used by the process in bytes.longReturns the amount of free swap space in bytes.Instantiates and returns an instance of aStringobject containing hardware model informationdoubleReturns the recent CPU usage for the Java Virtual Machine process.longReturns total amount of time the process has been scheduled or executed so far in both kernel and user modes.intReturns the collective capacity of the virtual processors in the partition the VM is running in.longReturns the amount of physical memory being used by the process in bytes.longReturns the amount of private memory used by the process in bytes.longReturns the total amount of swap space in bytes.booleanIdentify whether the underlying hardware is being emulatedbooleanisProcessRunning(long pid) Indicates if the specified process is runningInstantiates and returns an instance ofMemoryUsageobject that represents the current snapshot of Memory usage statistics.retrieveMemoryUsage(MemoryUsage memObj) Returns an updatedMemoryUsageobject that represents the current snapshot of Memory usage statistics.Instantiates and returns an array ofProcessorUsageobjects that represent the current snapshot of individual Processor usage times.retrieveProcessorUsage(ProcessorUsage[] procArray) Returns an updated array ofProcessorUsageobjects that represent the current snapshot of individual Processor usage times.Instantiate and return a newProcessorUsageobject that represents the current snapshot of Processor usage statistics.Returns an updatedProcessorUsageobject that represents the current snapshot of Processor usage statistics.Methods declared in interface OperatingSystemMXBean
getCpuLoad, getFreeMemorySize, getFreePhysicalMemorySize, getSystemCpuLoad, getTotalMemorySize, getTotalPhysicalMemorySizeMethods declared in interface OperatingSystemMXBean
getArch, getAvailableProcessors, getName, getSystemLoadAverage, getVersionMethods declared in interface PlatformManagedObject
getObjectName
-
Method Details
-
getMaxFileDescriptorCount
long getMaxFileDescriptorCount()Returns the maximum number of file descriptors that can be opened in a process.- Specified by:
getMaxFileDescriptorCountin interfaceUnixOperatingSystemMXBean- Returns:
- The maximum number of file descriptors that can be opened in a process or -1, if an error occurred while obtaining this. If the operating system doesn't have any limits configured, Long.MAX_VALUE is returned.
- Since:
- 1.8
-
getOpenFileDescriptorCount
long getOpenFileDescriptorCount()Returns the current number of file descriptors that are in opened state.- Specified by:
getOpenFileDescriptorCountin interfaceUnixOperatingSystemMXBean- Returns:
- The current number of file descriptors that are in opened state or -1, if an error occurred while obtaining this.
- Since:
- 1.8
-