Class LinuxOperatingSystemFFM
java.lang.Object
oshi.software.common.AbstractOperatingSystem
oshi.software.common.os.linux.LinuxOperatingSystem
oshi.software.os.linux.LinuxOperatingSystemFFM
- All Implemented Interfaces:
oshi.software.os.OperatingSystem
@ThreadSafe
public class LinuxOperatingSystemFFM
extends oshi.software.common.os.linux.LinuxOperatingSystem
FFM-based Linux operating system implementation.
Extends LinuxOperatingSystem, overriding methods to use FFM implementations as they become available.
Udev availability is determined by UdevFunctions.isAvailable(), which checks both the
oshi.os.linux.allowudev configuration property and whether libudev could be loaded and all symbols bound. FFM
consumer classes should import HAS_UDEV from this class rather than from LinuxOperatingSystemJNA.
-
Nested Class Summary
Nested classes/interfaces inherited from interface oshi.software.os.OperatingSystem
oshi.software.os.OperatingSystem.OSVersionInfo, oshi.software.os.OperatingSystem.ProcessFiltering, oshi.software.os.OperatingSystem.ProcessSorting -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final booleanIdentifies if the udev library was successfully loaded and all symbols bound via FFM.Fields inherited from class oshi.software.common.AbstractOperatingSystem
USE_WHO_COMMAND -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected oshi.software.os.OSProcesscreateOSProcess(int pid) oshi.software.os.FileSystemlonggetHz()oshi.software.os.NetworkParamslongoshi.software.os.OSProcessgetProcess(int pid) intList<oshi.software.os.OSSession> intintstatic longhz()Gets Jiffies per second, useful for converting ticks to milliseconds and vice versa.static longpageSize()Gets Page Size, for converting memory stats from pages to bytes.Methods inherited from class oshi.software.common.os.linux.LinuxOperatingSystem
getBootTime, getCurrentThread, getInstalledApplications, getInternetProtocolStats, getParentPidsFromProcFiles, getProcessCount, getReleaseFilename, getServices, getSystemBootTime, getSystemUptime, queryAllProcesses, queryBitness, queryChildProcesses, queryDescendantProcesses, queryFamilyVersionInfo, queryManufacturerMethods inherited from class oshi.software.common.AbstractOperatingSystem
getBitness, getChildProcesses, getChildrenOrDescendants, getChildrenOrDescendants, getDescendantProcesses, getDesktopWindows, getFamily, getManufacturer, getProcesses, getVersionInfo, isElevated, toStringMethods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface oshi.software.os.OperatingSystem
getCurrentProcess, getProcesses, getProcesses
-
Field Details
-
HAS_UDEV
public static final boolean HAS_UDEVIdentifies if the udev library was successfully loaded and all symbols bound via FFM. Also respects theoshi.os.linux.allowudevconfiguration property, consistent with the JNA-basedLinuxOperatingSystemJNA#HAS_UDEV.
-
-
Constructor Details
-
LinuxOperatingSystemFFM
public LinuxOperatingSystemFFM()
-
-
Method Details
-
hz
public static long hz()Gets Jiffies per second, useful for converting ticks to milliseconds and vice versa.- Returns:
- Jiffies per second.
-
pageSize
public static long pageSize()Gets Page Size, for converting memory stats from pages to bytes.- Returns:
- Page Size in bytes.
-
getHz
public long getHz()- Specified by:
getHzin classoshi.software.common.os.linux.LinuxOperatingSystem
-
getPageSize
public long getPageSize()- Specified by:
getPageSizein classoshi.software.common.os.linux.LinuxOperatingSystem
-
getSessions
- Specified by:
getSessionsin interfaceoshi.software.os.OperatingSystem- Overrides:
getSessionsin classoshi.software.common.AbstractOperatingSystem
-
getFileSystem
public oshi.software.os.FileSystem getFileSystem() -
getNetworkParams
public oshi.software.os.NetworkParams getNetworkParams() -
getProcess
public oshi.software.os.OSProcess getProcess(int pid) -
createOSProcess
protected oshi.software.os.OSProcess createOSProcess(int pid) - Specified by:
createOSProcessin classoshi.software.common.os.linux.LinuxOperatingSystem
-
getProcessId
public int getProcessId() -
getThreadId
public int getThreadId() -
getThreadCount
public int getThreadCount()
-