Class LinuxOSFileStore
java.lang.Object
oshi.software.common.AbstractOSFileStore
oshi.software.common.os.linux.LinuxOSFileStore
- All Implemented Interfaces:
OSFileStore
OSFileStore implementation
-
Constructor Summary
ConstructorsConstructorDescriptionLinuxOSFileStore(String name, String volume, String label, String mount, String options, String uuid, boolean local, String logicalVolume, String description, String fsType, long freeSpace, long usableSpace, long totalSpace, long freeInodes, long totalInodes, LinuxFileSystem fs) Creates a LinuxOSFileStore. -
Method Summary
Modifier and TypeMethodDescriptionbooleanMake a best effort to update all the statistics about the file store without needing to recreate the file store list.Methods inherited from class AbstractOSFileStore
getDescription, getFreeInodes, getFreeSpace, getLabel, getLogicalVolume, getMount, getName, getOptions, getTotalInodes, getTotalSpace, getType, getUsableSpace, getUUID, getVolume, isLocal, toString, updateFrom, updateSpace, updateSpaceAndInodesModifier and TypeMethodDescriptionDescription of the File System.longUsable / free inodes on the drive.longFree space on the drive.getLabel()Label of the File System.Logical volume of the File System.getMount()Mount point of the File System.getName()Name of the File System.Filesystem options.longTotal / maximum number of inodes of the filesystem.longTotal space/capacity of the drive.getType()Type of the File System (FAT, NTFS, etx2, ext4, etc.)longUsable space on the drive.getUUID()UUID/GUID of the File System.Volume name of the File System.booleanisLocal()Indicates whether this file store is local, providing low-latency access.toString()protected voidupdateFrom(OSFileStore fileStore) Copies mutable attributes from another file store into this one.protected voidupdateSpace(long freeSpace, long usableSpace, long totalSpace) Updates only the space fields (no inodes).protected voidupdateSpaceAndInodes(long freeSpace, long usableSpace, long totalSpace, long freeInodes, long totalInodes) Updates only the space and inode fields.
-
Constructor Details
-
LinuxOSFileStore
public LinuxOSFileStore(String name, String volume, String label, String mount, String options, String uuid, boolean local, String logicalVolume, String description, String fsType, long freeSpace, long usableSpace, long totalSpace, long freeInodes, long totalInodes, LinuxFileSystem fs) Creates a LinuxOSFileStore.- Parameters:
name- the namevolume- the volumelabel- the labelmount- the mount pointoptions- the mount optionsuuid- the UUIDlocal- whether locallogicalVolume- the logical volumedescription- the descriptionfsType- the filesystem typefreeSpace- free space in bytesusableSpace- usable space in bytestotalSpace- total space in bytesfreeInodes- free inodestotalInodes- total inodesfs- the parent filesystem
-
-
Method Details
-
updateAttributes
public boolean updateAttributes()Description copied from interface:OSFileStoreMake a best effort to update all the statistics about the file store without needing to recreate the file store list. This method provides for more frequent periodic updates of file store statistics.- Returns:
- True if the update was (probably) successful, false if the disk was not found
-