Solid::Ifaces::StorageVolume Class
class Solid::Ifaces::StorageVolumeHeader: | #include <StorageVolume> |
CMake: | find_package(KF6 REQUIRED COMPONENTS Solid) target_link_libraries(mytarget PRIVATE KF6::Solid) |
Inherits: | Solid::Ifaces::Block |
Inherited By: |
Public Functions
virtual | ~StorageVolume() override |
virtual QString | encryptedContainerUdi() const = 0 |
virtual QString | fsType() const = 0 |
virtual bool | isIgnored() const = 0 |
virtual QString | label() const = 0 |
virtual qulonglong | size() const = 0 |
virtual Solid::StorageVolume::UsageType | usage() const = 0 |
virtual QString | uuid() const = 0 |
Detailed Description
This device interface is available on volume devices.
A volume is anything that can contain data (partition, optical disc, memory card). It's a particular kind of block device.
Member Function Documentation
[override virtual noexcept]
StorageVolume::~StorageVolume()
Destroys a StorageVolume object.
[pure virtual]
QString StorageVolume::encryptedContainerUdi() const
Retrieves the crypto container UDI of this volume.
@return the encrypted volume UDI containing the current volume if applicable, an empty string otherwise
[pure virtual]
QString StorageVolume::fsType() const
Retrieves the filesystem type of this volume.
@return the filesystem type if applicable, QString() otherwise
[pure virtual]
bool StorageVolume::isIgnored() const
Indicates if this volume should be ignored by applications.
If it should be ignored, it generally means that it should be invisible to the user. It's useful for firmware partitions or OS reinstall partitions on some systems.
@return true if the volume should be ignored
[pure virtual]
QString StorageVolume::label() const
Retrieves this volume label.
@return the volume level if available, QString() otherwise
[pure virtual]
qulonglong StorageVolume::size() const
Retrieves this volume size in bytes.
@return the size of this volume
[pure virtual]
Solid::StorageVolume::UsageType StorageVolume::usage() const
Retrieves the type of use for this volume (for example filesystem).
@return the usage type @see Solid::StorageVolume::UsageType
[pure virtual]
QString StorageVolume::uuid() const
Retrieves this volume Universal Unique IDentifier (UUID).
You can generally assume that this identifier is unique with reasonable confidence. Except if the volume UUID has been forged to intentionally provoke a collision, the probability to have two volumes having the same UUID is low.
@return the Universal Unique IDentifier if available, QString() otherwise