Class LinuxHWDiskStoreJNA
java.lang.Object
oshi.hardware.common.AbstractHWDiskStore
oshi.hardware.common.platform.linux.LinuxHWDiskStore
oshi.hardware.platform.linux.LinuxHWDiskStoreJNA
- All Implemented Interfaces:
HWDiskStore
JNA-based Linux hard disk implementation.
-
Nested Class Summary
Nested classes/interfaces inherited from class LinuxHWDiskStore
LinuxHWDiskStore.UdevStat -
Field Summary
Fields inherited from class LinuxHWDiskStore
BLOCK, DISK, DM_LV_NAME, DM_UUID, DM_VG_NAME, ID_FS_LABEL, ID_FS_TYPE, ID_FS_UUID, ID_MODEL, ID_SERIAL_SHORT, LOGICAL_VOLUME_GROUP, MAJOR, MINOR, PARTITION, SECTORSIZE, SIZE, STAT, UDEV_STAT_LENGTH, UDEV_STAT_ORDERS -
Method Summary
Modifier and TypeMethodDescriptionstatic List<HWDiskStore> getDisks()Gets the disks on this machinebooleanMake a best effort to update all the statistics about the drive without needing to recreate the drive list.Methods inherited from class LinuxHWDiskStore
computeDiskStats, finalizePartitions, getCurrentQueueLength, getDependentNamesFromHoldersDirectory, getMountPointOfDmDevice, getMutablePartitionList, getPartitionNameForDmDevice, getPartitions, getReadBytes, getReads, getTimeStamp, getTransferTime, getWriteBytes, getWrites, readMountsMap, setDiskStats, setPartitionList
-
Method Details
-
getDisks
Gets the disks on this machine- Returns:
- a list of
HWDiskStoreobjects representing the disks
-
updateAttributes
public boolean updateAttributes()Description copied from interface:HWDiskStoreMake a best effort to update all the statistics about the drive without needing to recreate the drive list. This method provides for more frequent periodic updates of individual drive statistics but may be less efficient to use if updating all drives. It will not detect if a removable drive has been removed and replaced by a different drive in between method calls.- Returns:
- True if the update was (probably) successful, false if the disk was not found
-