libstorage-ng
Loading...
Searching...
No Matches
storage Namespace Reference

The storage namespace. More...

Classes

class  Aborted
class  Actiongraph
 The actiongraph has all actions including the dependencies among them to get from one devicegraph to another. More...
class  ActivateCallbacks
 Other storage subsystems are activated automatically, e.g. More...
class  ActivateCallbacksLuks
 Specialized callbacks with a more generic parameter for LUKS activation. More...
class  ActivateCallbacksV3
 Specialized callbacks with a more generic parameter for Bitlocker activation. More...
class  AlignError
class  Alignment
 A class to calculate partition alignment based on hardware topology. More...
class  Arch
class  Bcache
 A bcache device. More...
class  BcacheCset
 A bcache cache set. More...
class  Bcachefs
 Class to represent a Bcachefs filesystem https://en.wikipedia.org/wiki/Bcachefs in the devicegraph. More...
class  Bitlocker
 Class for BitLocker filesystem. More...
class  BitlockerInfo
 Stores information about a Bitlocker device. More...
class  BitlockerV2
 A BitLocker layer on a block device. More...
class  BlkDevice
 An abstract Block Device. More...
class  BlkFilesystem
class  Btrfs
 Class to represent a btrfs filesystem https://en.wikipedia.org/wiki/Btrfs in the devicegraph. More...
class  BtrfsQgroup
 Class to represent a qgroup of a btrfs filesystem. More...
class  BtrfsQgroupNotFoundById
class  BtrfsQgroupRelation
 Relation between btrfs quota groups. More...
class  BtrfsSubvolume
 Class to represent a btrfs subvolume in the devicegraph. More...
class  BtrfsSubvolumeNotFoundByPath
class  Callbacks
class  CheckCallbacks
class  CodeLocation
 Helper class for UI exceptions: Store BASE_FILE, FUNCTION and LINE. More...
class  CommitCallbacks
class  CommitCallbacksV2
class  CommitOptions
class  CompoundAction
 A Compound Action groups several related actions from an actiongraph. More...
class  ContentInfo
class  Dasd
 A physical DASD device. More...
class  DasdPt
struct  DeactivateStatus
class  DeactivateStatusV2
 Provides information whether deactivate_v2() was able to deactivate subsystems. More...
class  Device
 An abstract base class for storage devices. More...
class  Devicegraph
 The main container of the libstorage-ng. More...
class  DevicegraphStyleCallbacks
 Style callbacks used by Devicegraph::write_graphviz(). More...
class  DeviceHasWrongType
class  DeviceNotFound
class  DeviceNotFoundByName
class  DeviceNotFoundBySid
class  DeviceNotFoundByUuid
class  DifferentBlockSizes
class  Disk
 A physical disk device. More...
class  DmRaid
 A DM RAID device. More...
class  Encryption
 An encryption layer on a blk device. More...
class  Environment
class  Exception
 Base class for storage exceptions. More...
class  Exfat
 Class to represent an exFAT filesystem https://en.wikipedia.org/wiki/ExFAT in the devicegraph. More...
class  Ext
 Abstract base class for Ext2, Ext3 and Ext4. More...
class  Ext2
 Class to represent an Ext2 filesystem https://en.wikipedia.org/wiki/Ext2 in the devicegraph. More...
class  Ext3
 Class to represent an Ext3 filesystem https://en.wikipedia.org/wiki/Ext3 in the devicegraph. More...
class  Ext4
 Class to represent an Ext4 filesystem https://en.wikipedia.org/wiki/Ext4 in the devicegraph. More...
class  F2fs
 Class to represent a F2FS (https://en.wikipedia.org/wiki/F2FS) in the devicegraph. More...
class  Filesystem
class  FilesystemUser
 Holder from BlkDevice to a BlkFilesystem. More...
class  Gpt
class  GraphStyleCallbacks
 Base class for DevicegraphStyleCallbacks and ActiongraphStyleCallbacks. More...
class  Holder
 An abstract base class for storage holders. More...
class  HolderAlreadyExists
class  HolderHasWrongType
class  HolderNotFound
class  HolderNotFoundBySids
class  ImplicitPt
 Class to represent implicit partition table. More...
class  IndexOutOfRangeException
 Exception class for "index out of range". More...
class  InvalidBlockSize
class  InvalidChunkSize
class  InvalidExtentSize
class  InvalidMountPointPath
class  InvalidStripeSize
class  IOException
 Exception class for IO errors. More...
class  Iso9660
 Class for ISO9660 filesystem. More...
class  Jfs
 Class to represent a JFS filesystem https://en.wikipedia.org/wiki/JFS_(file_system) in the devicegraph. More...
class  LockException
 Exception indicating that getting the lock failed. More...
class  Logger
 The Logger class. More...
class  LogicException
 Exception class for faulty logic within the program. More...
class  Luks
 An LUKS encryption layer on a block device. More...
class  LuksInfo
 Stores information about a LUKS device. More...
class  LvmDevicesFile
class  LvmLv
 A Logical Volume of the Logical Volume Manager (LVM). More...
class  LvmLvNotFoundByLvName
class  LvmPv
class  LvmVg
 A Volume Group of the Logical Volume Manager (LVM). More...
class  LvmVgNotFoundByVgName
class  Md
 A MD device. More...
class  MdContainer
 A MD Container. More...
class  MdMember
 A MD member. More...
class  MdSubdevice
 Holder from a MdContainer to a MdMember. More...
class  MdUser
 Holder from a BlkDevice to an Md. More...
class  Mountable
class  MountPoint
 Class to represent a mount point. More...
class  Msdos
class  Multipath
 A multipath device. More...
class  Nfs
 Class to represent a NFS mount. More...
class  NfsNotFoundByServerAndPath
class  Nilfs2
 Class to represent a NILFS2 (https://en.wikipedia.org/wiki/NILFS2) in the devicegraph. More...
class  NoIntersection
class  NotInside
class  Ntfs
 Class to represent an NTFS filesystem https://en.wikipedia.org/wiki/NTFS in the devicegraph. More...
class  NullPointerException
 Exception class for generic null pointer exceptions. More...
class  OutOfMemoryException
 Exception class for "out of memory". More...
class  OverflowException
 Exception class for "overflow". More...
class  ParseException
 Exception class for parse errors, e.g. More...
class  Partition
 A partition of a Partitionable, e.g. More...
class  Partitionable
class  PartitionSlot
 Number and name are only valid if one of the possible flags is true. More...
class  PartitionTable
class  PlainEncryption
 An plain encryption layer on a block device. More...
class  Pool
 A pool represents a collection of devices. More...
class  PoolOutOfSpace
 Exception to report that the pool is out of space to fulfill the request. More...
class  ProbeCallbacks
class  ProbeCallbacksV2
class  ProbeCallbacksV3
class  ProbeCallbacksV4
class  Region
 A start/length pair with a block size. More...
class  Reiserfs
 Class to represent a ReiserFS filesystem https://en.wikipedia.org/wiki/ReiserFS in the devicegraph. More...
class  RemoteCallbacks
class  RemoteCallbacksV2
struct  RemoteCommand
 A result of an unnamed command: stdout + stderr + exit_code. More...
struct  RemoteFile
 Contents of an unnamed file (vector of lines) More...
class  RemoveInfo
class  ResizeInfo
class  Silencer
 Class to make some exceptions log-level DEBUG instead of WARNING. More...
struct  SimpleEtcCrypttabEntry
 A simple struct to hold the information from one line in crypttab. More...
struct  SimpleEtcFstabEntry
 A simple struct to hold the information from one line in fstab. More...
class  Snapshot
 Relationship between origin and snapshot. More...
class  SpaceInfo
class  Storage
 The main entry point to libstorage. More...
class  StrayBlkDevice
 This class represents stray block devices. More...
class  Subdevice
 Generic holder from one device to a subdevice, e.g. More...
class  Swap
 Class to represent a swap filesystem in the devicegraph. More...
class  SystemInfo
 The SystemInfo class keeps various system information. More...
class  Tmpfs
 Class to represent a tmpfs. More...
class  Topology
 A class to represent hardware alignment information. More...
class  Udf
 Class for UDF filesystem. More...
class  UnsupportedException
 Exception class for unsupported features and operations. More...
class  User
 Generic holder from one device to another device, e.g. More...
class  Vfat
 Class to represent an VFAT filesystem https://en.wikipedia.org/wiki/Vfat in the devicegraph. More...
class  WrongNumberOfChildren
class  WrongNumberOfHolders
class  WrongNumberOfParents
class  Xfs
 Class to represent an XFS filesystem https://en.wikipedia.org/wiki/Xfs in the devicegraph. More...

Typedefs

using uf_t = uint64_t
 Type for used features.
typedef unsigned int sid_t

Enumerations

enum  Side { LHS , RHS }
enum class  ProbeMode {
  STANDARD , STANDARD_WRITE_DEVICEGRAPH , STANDARD_WRITE_MOCKUP , NONE ,
  READ_DEVICEGRAPH , READ_MOCKUP
}
 How to probe the system.
enum class  TargetMode { DIRECT , CHROOT , IMAGE }
 Enum with target modes. More...
enum  : uint32_t {
  RB_RESIZE_NOT_SUPPORTED_BY_DEVICE = 1 << 0 , RB_MIN_MAX_ERROR = 1 << 1 , RB_SHRINK_NOT_SUPPORTED_BY_FILESYSTEM = 1 << 2 , RB_GROW_NOT_SUPPORTED_BY_FILESYSTEM = 1 << 3 ,
  RB_FILESYSTEM_INCONSISTENT = 1 << 4 , RB_MIN_SIZE_FOR_FILESYSTEM = 1 << 5 , RB_MAX_SIZE_FOR_FILESYSTEM = 1 << 6 , RB_FILESYSTEM_FULL = 1 << 7 ,
  RB_NO_SPACE_BEHIND_PARTITION = 1 << 8 , RB_MIN_SIZE_FOR_PARTITION = 1 << 9 , RB_EXTENDED_PARTITION = 1 << 10 , RB_ON_IMPLICIT_PARTITION_TABLE = 1 << 11 ,
  RB_SHRINK_NOT_SUPPORTED_FOR_LVM_LV_TYPE = 1 << 12 , RB_RESIZE_NOT_SUPPORTED_FOR_LVM_LV_TYPE = 1 << 13 , RB_NO_SPACE_IN_LVM_VG = 1 << 14 , RB_MIN_SIZE_FOR_LVM_LV = 1 << 15 ,
  RB_MAX_SIZE_FOR_LVM_LV_THIN = 1 << 16 , RB_SHRINK_NOT_SUPPORTED_BY_MULTIDEVICE_FILESYSTEM = 1 << 17 , RB_PASSWORD_REQUIRED = 1 << 18 , RB_RESIZE_NOT_SUPPORTED_DUE_TO_SNAPSHOTS = 1 << 19 ,
  RB_FILESYSTEM_MOUNT_READ_ONLY = 1 << 20
}
 Resize blockers. More...
enum  : uint32_t { RMB_HARDWARE = 1 << 0 , RMB_RENUMBER_ACTIVE_PARTITIONS = 1 << 1 , RMB_ON_IMPLICIT_PARTITION_TABLE = 1 << 2 }
 Remove blockers. More...
enum class  GraphvizFlags : unsigned int {
  NONE = 0 , CLASSNAME = 1 << 0 , PRETTY_CLASSNAME = 1 << 1 , NAME = 1 << 2 ,
  SID = 1 << 3 , SIZE = 1 << 4 , ACTIVE = 1 << 5 , IN_ETC = 1 << 6 ,
  DISPLAYNAME = 1 << 7
}
 Bitfield to control graphviz output. More...
enum class  UsedFeaturesDependencyType { REQUIRED , SUGGESTED }
 Enum specifying the dependency type of used features. More...
enum  : uint64_t {
  UF_EXT2 = 1 << 0 , UF_EXT3 = 1 << 1 , UF_EXT4 = 1 << 2 , UF_BTRFS = 1 << 3 ,
  UF_XFS = 1 << 4 , UF_REISERFS = 1 << 5 , UF_SWAP = 1 << 6 , UF_NTFS = 1 << 7 ,
  UF_VFAT = 1 << 8 , UF_NFS = 1 << 9 , UF_JFS = 1 << 10 , UF_F2FS = 1 << 23 ,
  UF_NILFS2 = 1 << 30 , UF_EXFAT = 1 << 24 , UF_UDF = 1 << 25 , UF_BITLOCKER = 1 << 27 ,
  UF_BCACHEFS = 1ULL << 31 , UF_PLAIN_ENCRYPTION = 1 << 26 , UF_LUKS = 1 << 11 , UF_LVM = 1 << 12 ,
  UF_MDRAID = 1 << 13 , UF_DMRAID = 1 << 14 , UF_MULTIPATH = 1 << 15 , UF_BCACHE = 1 << 16 ,
  UF_ISCSI = 1 << 17 , UF_FCOE = 1 << 18 , UF_FC = 1 << 19 , UF_DASD = 1 << 20 ,
  UF_PMEM = 1 << 29 , UF_NVME = 1 << 28 , UF_QUOTA = 1 << 21 , UF_SNAPSHOTS = 1 << 22
}
enum class  View { ALL , CLASSIC , REMOVE }
 Enum with possible views on the devicegraph. More...
enum class  BcacheType { BACKED , FLASH_ONLY }
 Bcache types.
enum class  CacheMode { WRITETHROUGH , WRITEBACK , WRITEAROUND , NONE }
 The Cache mode attribute.
enum class  DasdType { UNKNOWN , ECKD , FBA }
 The DASD type.
enum class  DasdFormat { NONE , LDL , CDL }
 The layout with which the ECKD DASD was formatted.
enum class  Transport {
  UNKNOWN , SBP , ATA , FC ,
  ISCSI , SAS , SATA , SPI ,
  USB , FCOE , PCIE , TCP ,
  RDMA , LOOP
}
 Data Transport Layer.
enum class  ZoneModel { NONE , HOST_AWARE , HOST_MANAGED }
 Zone model as read from /sys. More...
enum class  EncryptionType {
  NONE , TWOFISH , TWOFISH_OLD , TWOFISH256_OLD ,
  LUKS , LUKS1 = LUKS , UNKNOWN , LUKS2 ,
  PLAIN , BITLOCKER
}
enum class  LvType {
  UNKNOWN , NORMAL , THIN_POOL , THIN ,
  RAID , CACHE_POOL , CACHE , WRITECACHE ,
  SNAPSHOT , MIRROR
}
 LVM logical volume types, see lvs(8). More...
enum class  MdLevel {
  UNKNOWN , RAID0 , RAID1 , RAID4 ,
  RAID5 , RAID6 , RAID10 , CONTAINER ,
  LINEAR
}
 MD RAID levels.
enum class  MdParity {
  DEFAULT , LEFT_ASYMMETRIC , LEFT_SYMMETRIC , RIGHT_ASYMMETRIC ,
  RIGHT_SYMMETRIC , FIRST , LAST , LEFT_ASYMMETRIC_6 ,
  LEFT_SYMMETRIC_6 , RIGHT_ASYMMETRIC_6 , RIGHT_SYMMETRIC_6 , FIRST_6 ,
  NEAR_2 , OFFSET_2 , FAR_2 , NEAR_3 ,
  OFFSET_3 , FAR_3
}
 MD parity algorithms for RAID5, RAID6 and RAID10.
enum class  PartitionType { PRIMARY , EXTENDED , LOGICAL }
 Enum with partition types. More...
enum  IdNum : unsigned int {
  ID_DOS12 = 0x01 , ID_DOS16 = 0x06 , ID_NTFS = 0x07 , ID_DOS32 = 0x0c ,
  ID_EXTENDED = 0x0f , ID_DIAG = 0x12 , ID_PREP = 0x41 , ID_SWAP = 0x82 ,
  ID_LINUX = 0x83 , ID_IRST = 0x84 , ID_LVM = 0x8e , ID_RAID = 0xfd ,
  ID_ESP = 0xef , ID_UNKNOWN = 0x100 , ID_BIOS_BOOT , ID_WINDOWS_BASIC_DATA ,
  ID_MICROSOFT_RESERVED , ID_LINUX_HOME , ID_LINUX_SERVER_DATA , ID_LINUX_ROOT_ARM ,
  ID_LINUX_ROOT_AARCH64 , ID_LINUX_ROOT_PPC32 , ID_LINUX_ROOT_PPC64BE , ID_LINUX_ROOT_PPC64LE ,
  ID_LINUX_ROOT_RISCV32 , ID_LINUX_ROOT_RISCV64 , ID_LINUX_ROOT_S390 , ID_LINUX_ROOT_S390X ,
  ID_LINUX_ROOT_X86 , ID_LINUX_ROOT_X86_64 , ID_LINUX_USR_ARM , ID_LINUX_USR_AARCH64 ,
  ID_LINUX_USR_PPC32 , ID_LINUX_USR_PPC64BE , ID_LINUX_USR_PPC64LE , ID_LINUX_USR_RISCV32 ,
  ID_LINUX_USR_RISCV64 , ID_LINUX_USR_S390 , ID_LINUX_USR_S390X , ID_LINUX_USR_X86 ,
  ID_LINUX_USR_X86_64
}
 Enum with values used as partition ids. More...
enum class  LinuxPartitionIdCategory { ROOT , USR }
 Enum with categories for Linux partitions.
enum class  PtType {
  UNKNOWN , LOOP , MSDOS , GPT ,
  DASD , MAC , IMPLICIT , AIX ,
  SUN , ATARI , BSD , AMIGA ,
  DVH
}
 Partition Table Type.
enum class  BtrfsRaidLevel {
  UNKNOWN , DEFAULT , SINGLE , DUP ,
  RAID0 , RAID1 , RAID5 , RAID6 ,
  RAID10 , RAID1C3 , RAID1C4
}
 Btrfs RAID levels (aka profiles) used for metadata and data. More...
enum class  FsType {
  UNKNOWN , AUTO , REISERFS , EXT2 ,
  EXT3 , EXT4 , BTRFS , VFAT ,
  XFS , JFS , HFS , NTFS ,
  SWAP , HFSPLUS , NFS , NFS4 ,
  TMPFS , ISO9660 , UDF , NILFS2 ,
  MINIX , NTFS3G , F2FS , EXFAT ,
  BITLOCKER , VBOXSF , BCACHEFS
}
enum class  MountByType {
  DEVICE , UUID , LABEL , ID ,
  PATH , PARTUUID , PARTLABEL
}
 The key by which the mount program identifies a mountable. More...
enum class  Color { GREEN , BLACK , RED }
 A color suggestion for commit messages. More...
enum class  AlignType { REQUIRED , OPTIMAL }
enum class  AlignPolicy {
  ALIGN_START_AND_END = 0 , ST_DEPRECATED = 0 , ALIGN_START_KEEP_END = 1 , ST_DEPRECATED = 1 ,
  ALIGN_START_KEEP_SIZE = 2 , ST_DEPRECATED = 2 , KEEP_START_ALIGN_END = 3
}
enum class  LogLevel { DEBUG = 0 , MILESTONE = 1 , WARNING = 2 , ERROR = 3 }
 Enum with log levels.
enum  ull_hack_t { ULL_HACK }

Functions

GraphvizFlags operator| (GraphvizFlags a, GraphvizFlags b)
GraphvizFlags operator& (GraphvizFlags a, GraphvizFlags b)
bool operator&& (GraphvizFlags a, GraphvizFlags b)
DevicegraphStyleCallbacksget_debug_devicegraph_style_callbacks ()
 Get a DevicegraphStyleCallbacks object for debugging.
ActiongraphStyleCallbacks * get_debug_actiongraph_style_callbacks ()
 Get a ActiongraphStyleCallbacks object for debugging.
std::vector< SimpleEtcCrypttabEntryread_simple_etc_crypttab (const std::string &filename)
 Read a crypttab file.
std::vector< SimpleEtcFstabEntryread_simple_etc_fstab (const std::string &filename)
 Read a fstab file.
std::string get_used_features_dependency_type_name (UsedFeaturesDependencyType used_features_dependency_type)
 Convert the UsedFeaturesDependencyType used_features_dependency_type to a string.
std::string get_used_features_names (uf_t used_features)
 Return a string with the names of the used features.
const char * get_libversion_string ()
 Return LIBSTORAGE_NG_VERSION_STRING libstorage-ng was compiled with.
const char * get_version_string () ST_DEPRECATED
std::string get_bcache_type_name (BcacheType bcache_type)
 Convert the BcacheType bcache_type to a string.
std::string get_cache_mode_name (CacheMode cache_mode)
 Convert the CacheMode cache_mode to a string.
bool is_bcache (const Device *device)
 Checks whether device points to a Bcache.
Bcacheto_bcache (Device *device)
 Converts pointer to Device to pointer to Bcache.
const Bcacheto_bcache (const Device *device)
 Converts pointer to Device to pointer to Bcache.
bool is_bcache_cset (const Device *device)
 Checks whether device points to a BcacheCset.
BcacheCsetto_bcache_cset (Device *device)
 Converts pointer to Device to pointer to BcacheCset.
const BcacheCsetto_bcache_cset (const Device *device)
 Converts pointer to Device to pointer to BcacheCset.
bool is_bitlocker_v2 (const Device *device)
 Checks whether device points to a BitlockerV2.
BitlockerV2to_bitlocker_v2 (Device *device)
 Converts pointer to Device to pointer to BitlockerV2.
const BitlockerV2to_bitlocker_v2 (const Device *device)
 Converts pointer to Device to pointer to BitlockerV2.
bool is_blk_device (const Device *device)
 Checks whether device points to an BlkDevice.
BlkDeviceto_blk_device (Device *device)
 Converts pointer to Device to pointer to BlkDevice.
const BlkDeviceto_blk_device (const Device *device)
 Converts pointer to Device to pointer to BlkDevice.
std::string get_dasd_type_name (DasdType dasd_type)
 Convert the DASD type dasd_type to a string.
std::string get_dasd_format_name (DasdFormat dasd_format)
 Convert the DASD format dasd_format to a string.
bool is_dasd (const Device *device)
 Checks whether device points to a Dasd.
Dasdto_dasd (Device *device)
 Converts pointer to Device to pointer to Dasd.
const Dasdto_dasd (const Device *device)
 Converts pointer to Device to pointer to Dasd.
bool is_dasd_pt (const Device *device)
 Checks whether device points to a DasdPt.
DasdPtto_dasd_pt (Device *device)
 Converts pointer to Device to pointer to DasdPt.
const DasdPtto_dasd_pt (const Device *device)
 Converts pointer to Device to pointer to DasdPt.
std::string get_transport_name (Transport transport)
 Convert the Transport transport to a string.
std::string get_zone_model_name (ZoneModel zone_model)
 Convert the ZoneModel zone_model to a string.
bool is_disk (const Device *device)
 Checks whether device points to a Disk.
Diskto_disk (Device *device)
 Converts pointer to Device to pointer to Disk.
const Diskto_disk (const Device *device)
 Converts pointer to Device to pointer to Disk.
bool is_dm_raid (const Device *device)
 Checks whether device points to a DmRaid.
DmRaidto_dm_raid (Device *device)
 Converts pointer to Device to pointer to DmRaid.
const DmRaidto_dm_raid (const Device *device)
 Converts pointer to Device to pointer to DmRaid.
std::string get_encryption_type_name (EncryptionType encryption_type)
 Convert the EncryptionType encryption_type to a string.
bool is_encryption (const Device *device)
 Checks whether device points to an Encryption.
Encryptionto_encryption (Device *device)
 Converts pointer to Device to pointer to Encryption.
const Encryptionto_encryption (const Device *device)
 Converts pointer to Device to pointer to Encryption.
bool is_gpt (const Device *device)
 Checks whether device points to a Gpt.
Gptto_gpt (Device *device)
 Converts pointer to Device to pointer to Gpt.
const Gptto_gpt (const Device *device)
 Converts pointer to Device to pointer to Gpt.
bool is_implicit_pt (const Device *device)
 Checks whether device points to a ImplicitPt.
ImplicitPtto_implicit_pt (Device *device)
 Converts pointer to Device to pointer to ImplicitPt.
const ImplicitPtto_implicit_pt (const Device *device)
 Converts pointer to Device to pointer to ImplicitPt.
bool is_luks (const Device *device)
 Checks whether device points to a Luks.
Luksto_luks (Device *device)
 Converts pointer to Device to pointer to Luks.
const Luksto_luks (const Device *device)
 Converts pointer to Device to pointer to Luks.
std::string get_lv_type_name (LvType lv_type)
 Convert LvType to string.
bool is_lvm_lv (const Device *device)
 Checks whether device points to a LvmLv.
LvmLvto_lvm_lv (Device *device)
 Converts pointer to Device to pointer to LvmLv.
const LvmLvto_lvm_lv (const Device *device)
 Converts pointer to Device to pointer to LvmLv.
bool is_lvm_pv (const Device *device)
 Checks whether device points to a LvmPv.
LvmPvto_lvm_pv (Device *device)
 Converts pointer to Device to pointer to LvmPv.
const LvmPvto_lvm_pv (const Device *device)
 Converts pointer to Device to pointer to LvmPv.
bool is_lvm_vg (const Device *device)
 Checks whether device points to a LvmVg.
LvmVgto_lvm_vg (Device *device)
 Converts pointer to Device to pointer to LvmVg.
const LvmVgto_lvm_vg (const Device *device)
 Converts pointer to Device to pointer to LvmVg.
std::string get_md_level_name (MdLevel md_level)
 Convert the MD RAID level md_level to a string.
std::string get_md_parity_name (MdParity md_parity)
 Convert the MD parity algorithm md_parity to a string.
bool is_md (const Device *device)
 Checks whether device points to a Md.
Mdto_md (Device *device)
 Converts pointer to Device to pointer to Md.
const Mdto_md (const Device *device)
 Converts pointer to Device to pointer to Md.
bool is_md_container (const Device *device)
 Checks whether device points to an MdContainer.
MdContainerto_md_container (Device *device)
 Converts pointer to Device to pointer to MdContainer.
const MdContainerto_md_container (const Device *device)
 Converts pointer to Device to pointer to MdContainer.
bool is_md_member (const Device *device)
 Checks whether device points to a MdMember.
MdMemberto_md_member (Device *device)
 Converts pointer to Device to pointer to MdMember.
const MdMemberto_md_member (const Device *device)
 Converts pointer to Device to pointer to MdMember.
bool is_msdos (const Device *device)
 Checks whether device points to an Msdos.
Msdosto_msdos (Device *device)
 Converts pointer to Device to pointer to Msdos.
const Msdosto_msdos (const Device *device)
 Converts pointer to Device to pointer to Msdos.
bool is_multipath (const Device *device)
 Checks whether device points to a Multipath.
Multipathto_multipath (Device *device)
 Converts pointer to Device to pointer to Multipath.
const Multipathto_multipath (const Device *device)
 Converts pointer to Device to pointer to Multipath.
std::string get_partition_type_name (PartitionType partition_type)
 Convert the PartitionType partition_type to a string.
std::string get_partition_id_name (IdNum partition_id)
 Convert the IdNum partition_id to a string.
bool is_linux_partition_id (IdNum id)
 Check whether the id is a Linux partition id.
bool is_linux_partition_id (IdNum id, LinuxPartitionIdCategory linux_partition_id_category)
 Check whether the id is a Linux partition id of the specified category.
IdNum get_linux_partition_id (LinuxPartitionIdCategory linux_partition_id_category, const Arch &arch)
 Get the partition id for the Linux partition of the given category (root, usr, ...) depending on the architecture.
IdNum get_linux_partition_id (LinuxPartitionIdCategory linux_partition_id_category, SystemInfo &system_info)
 Get the partition id for the Linux partition of the given category (root, usr, ...) depending on the architecture.
bool is_partition (const Device *device)
 Checks whether device points to a Partition.
Partitionto_partition (Device *device)
 Converts pointer to Device to pointer to Partition.
const Partitionto_partition (const Device *device)
 Converts pointer to Device to pointer to Partition.
bool is_partitionable (const Device *device)
 Checks whether device points to a Partitionable.
Partitionableto_partitionable (Device *device)
 Converts pointer to Device to pointer to Partitionable.
const Partitionableto_partitionable (const Device *device)
 Converts pointer to Device to pointer to Partitionable.
std::string get_pt_type_name (PtType pt_type)
 Convert the PtType pt_type to a string.
bool is_partition_table (const Device *device)
 Checks whether device points to a PartitionTable.
PartitionTableto_partition_table (Device *device)
 Converts pointer to Device to pointer to PartitionTable.
const PartitionTableto_partition_table (const Device *device)
 Converts pointer to Device to pointer to PartitionTable.
bool is_plain_encryption (const Device *device)
 Checks whether device points to a PlainEncryption.
PlainEncryptionto_plain_encryption (Device *device)
 Converts pointer to Device to pointer to PlainEncryption.
const PlainEncryptionto_plain_encryption (const Device *device)
 Converts pointer to Device to pointer to PlainEncryption.
bool is_stray_blk_device (const Device *device)
 Checks whether device points to a StrayBlkDevice.
StrayBlkDeviceto_stray_blk_device (Device *device)
 Converts pointer to Device to pointer to StrayBlkDevice.
const StrayBlkDeviceto_stray_blk_device (const Device *device)
 Converts pointer to Device to pointer to StrayBlkDevice.
bool is_bcachefs (const Device *device)
 Checks whether device points to an Bcachefs.
Bcachefsto_bcachefs (Device *device)
 Converts pointer to Device to pointer to Bcachefs.
const Bcachefsto_bcachefs (const Device *device)
 Converts pointer to Device to pointer to Bcachefs.
bool is_bitlocker (const Device *device)
 Checks whether device points to an Bitlocker.
Bitlockerto_bitlocker (Device *device)
 Converts pointer to Device to pointer to Bitlocker.
const Bitlockerto_bitlocker (const Device *device)
 Converts pointer to Device to pointer to Bitlocker.
bool is_blk_filesystem (const Device *device)
 Checks whether device points to a BlkFilesystem.
BlkFilesystemto_blk_filesystem (Device *device)
 Converts pointer to Device to pointer to BlkFilesystem.
const BlkFilesystemto_blk_filesystem (const Device *device)
 Converts pointer to Device to pointer to BlkFilesystem.
std::string get_btrfs_raid_level_name (BtrfsRaidLevel btrfs_raid_level)
 Convert the btrfs RAID level btrfs_raid_level to a string.
bool is_btrfs (const Device *device)
 Checks whether device points to a Btrfs.
Btrfsto_btrfs (Device *device)
 Converts pointer to Device to pointer to Btrfs.
const Btrfsto_btrfs (const Device *device)
 Converts pointer to Device to pointer to Btrfs.
bool is_btrfs_qgroup (const Device *device)
 Checks whether device points to a Btrfs.
BtrfsQgroupto_btrfs_qgroup (Device *device)
 Converts pointer to Device to pointer to Btrfs.
const BtrfsQgroupto_btrfs_qgroup (const Device *device)
 Converts pointer to Device to pointer to Btrfs.
bool is_btrfs_subvolume (const Device *device)
 Checks whether device points to a BtrfsSubvolume.
BtrfsSubvolumeto_btrfs_subvolume (Device *device)
 Converts pointer to Device to pointer to BtrfsSubvolume.
const BtrfsSubvolumeto_btrfs_subvolume (const Device *device)
 Converts pointer to Device to pointer to BtrfsSubvolume.
bool is_exfat (const Device *device)
 Checks whether device points to an Exfat.
Exfatto_exfat (Device *device)
 Converts pointer to Device to pointer to Exfat.
const Exfatto_exfat (const Device *device)
 Converts pointer to Device to pointer to Exfat.
bool is_ext (const Device *device)
 Checks whether device points to an Ext.
Extto_ext (Device *device)
 Converts pointer to Device to pointer to Ext.
const Extto_ext (const Device *device)
 Converts pointer to Device to pointer to Ext.
bool is_ext2 (const Device *device)
 Checks whether device points to an Ext2.
Ext2to_ext2 (Device *device)
 Converts pointer to Device to pointer to Ext2.
const Ext2to_ext2 (const Device *device)
 Converts pointer to Device to pointer to Ext2.
bool is_ext3 (const Device *device)
 Checks whether device points to an Ext3.
Ext3to_ext3 (Device *device)
 Converts pointer to Device to pointer to Ext3.
const Ext3to_ext3 (const Device *device)
 Converts pointer to Device to pointer to Ext3.
bool is_ext4 (const Device *device)
 Checks whether device points to an Ext4.
Ext4to_ext4 (Device *device)
 Converts pointer to Device to pointer to Ext4.
const Ext4to_ext4 (const Device *device)
 Converts pointer to Device to pointer to Ext4.
bool is_f2fs (const Device *device)
 Checks whether device points to a F2fs.
F2fsto_f2fs (Device *device)
 Converts pointer to Device to pointer to F2fs.
const F2fsto_f2fs (const Device *device)
 Converts pointer to Device to pointer to F2fs.
bool is_filesystem (const Device *device)
 Checks whether device points to a Filesystem.
Filesystemto_filesystem (Device *device)
 Converts pointer to Device to pointer to Filesystem.
const Filesystemto_filesystem (const Device *device)
 Converts pointer to Device to pointer to Filesystem.
bool is_iso9660 (const Device *device)
 Checks whether device points to a Iso9660.
Iso9660to_iso9660 (Device *device)
 Converts pointer to Device to pointer to Iso9660.
const Iso9660to_iso9660 (const Device *device)
 Converts pointer to Device to pointer to Iso9660.
bool is_jfs (const Device *device)
 Checks whether device points to a Jfs.
Jfsto_jfs (Device *device)
 Converts pointer to Device to pointer to Jfs.
const Jfsto_jfs (const Device *device)
 Converts pointer to Device to pointer to Jfs.
std::string get_fs_type_name (FsType fs_type)
 Convert the FsType fs_type to a string.
std::string get_mount_by_name (MountByType mount_by_type)
 Convert the MountByType mount_by_type to a string.
bool is_mountable (const Device *device)
 Checks whether device points to a Mountable.
Mountableto_mountable (Device *device)
 Converts pointer to Device to pointer to Mountable.
const Mountableto_mountable (const Device *device)
 Converts pointer to Device to pointer to Mountable.
bool is_mount_point (const Device *device)
 Checks whether device points to a MountPoint.
MountPointto_mount_point (Device *device)
 Converts pointer to Device to pointer to Mountpoint.
const MountPointto_mount_point (const Device *device)
 Converts pointer to Device to pointer to Mountpoint.
bool is_nfs (const Device *device)
 Checks whether device points to a Nfs.
Nfsto_nfs (Device *device)
 Converts pointer to Device to pointer to Nfs.
const Nfsto_nfs (const Device *device)
 Converts pointer to Device to pointer to Nfs.
bool is_nilfs2 (const Device *device)
 Checks whether device points to a Nilfs2.
Nilfs2to_nilfs2 (Device *device)
 Converts pointer to Device to pointer to Nilfs2.
const Nilfs2to_nilfs2 (const Device *device)
 Converts pointer to Device to pointer to Nilfs2.
bool is_ntfs (const Device *device)
 Checks whether device points to a Ntfs.
Ntfsto_ntfs (Device *device)
 Converts pointer to Device to pointer to Ntfs.
const Ntfsto_ntfs (const Device *device)
 Converts pointer to Device to pointer to Ntfs.
bool is_reiserfs (const Device *device)
 Checks whether device points to an Reiserfs.
Reiserfsto_reiserfs (Device *device)
 Converts pointer to Device to pointer to Reiserfs.
const Reiserfsto_reiserfs (const Device *device)
 Converts pointer to Device to pointer to Reiserfs.
bool is_swap (const Device *device)
 Checks whether device points to an Swap.
Swapto_swap (Device *device)
 Converts pointer to Device to pointer to Swap.
const Swapto_swap (const Device *device)
 Converts pointer to Device to pointer to Swap.
bool is_tmpfs (const Device *device)
 Checks whether device points to a Tmpfs.
Tmpfsto_tmpfs (Device *device)
 Converts pointer to Device to pointer to Tmpfs.
const Tmpfsto_tmpfs (const Device *device)
 Converts pointer to Device to pointer to Tmpfs.
bool is_udf (const Device *device)
 Checks whether device points to an Udf.
Udfto_udf (Device *device)
 Converts pointer to Device to pointer to Udf.
const Udfto_udf (const Device *device)
 Converts pointer to Device to pointer to Udf.
bool is_vfat (const Device *device)
 Checks whether device points to a Vfat.
Vfatto_vfat (Device *device)
 Converts pointer to Device to pointer to Vfat.
const Vfatto_vfat (const Device *device)
 Converts pointer to Device to pointer to Vfat.
bool is_xfs (const Device *device)
 Checks whether device points to a Xfs.
Xfsto_xfs (Device *device)
 Converts pointer to Device to pointer to Xfs.
const Xfsto_xfs (const Device *device)
 Converts pointer to Device to pointer to Xfs.
bool is_btrfs_qgroup_relation (const Holder *holder)
 Checks whether holder points to a BtrfsQgroupRelation.
BtrfsQgroupRelationto_btrfs_qgroup_relation (Holder *holder)
 Converts pointer to Holder to pointer to BtrfsQgroupRelation.
const BtrfsQgroupRelationto_btrfs_qgroup_relation (const Holder *holder)
 Converts pointer to Holder to pointer to BtrfsQgroupRelation.
bool is_filesystem_user (const Holder *holder)
 Checks whether holder points to a FilesystemUser.
FilesystemUserto_filesystem_user (Holder *holder)
 Converts pointer to Holder to pointer to FilesystemUser.
const FilesystemUserto_filesystem_user (const Holder *holder)
 Converts pointer to Holder to pointer to FilesystemUser.
bool is_md_subdevice (const Holder *holder)
 Checks whether holder points to an MdSubdevice.
MdSubdeviceto_md_subdevice (Holder *holder)
 Converts pointer to Holder to pointer to MdSubdevice.
const MdSubdeviceto_md_subdevice (const Holder *holder)
 Converts pointer to Holder to pointer to MdSubdevice.
bool is_md_user (const Holder *holder)
 Checks whether holder points to a MdUser.
MdUserto_md_user (Holder *holder)
 Converts pointer to Holder to pointer to MdUser.
const MdUserto_md_user (const Holder *holder)
 Converts pointer to Holder to pointer to MdUser.
bool is_snapshot (const Holder *holder)
 Checks whether holder points to a Snapshot.
Snapshotto_snapshot (Holder *holder)
 Converts pointer to Holder to pointer to Snapshot.
const Snapshotto_snapshot (const Holder *holder)
 Converts pointer to Holder to pointer to Snapshot.
bool is_subdevice (const Holder *holder)
 Checks whether holder points to a Subdevice.
Subdeviceto_subdevice (Holder *holder)
 Converts pointer to Holder to pointer to Subdevice.
const Subdeviceto_subdevice (const Holder *holder)
 Converts pointer to Holder to pointer to User.
bool is_user (const Holder *holder)
 Checks whether holder points to an User.
Userto_user (Holder *holder)
 Converts pointer to Holder to pointer to User.
const Userto_user (const Holder *holder)
 Converts pointer to Holder to pointer to User.
std::string get_string (const Actiongraph *actiongraph, const Action::Base *action)
 Get the commit message of an action.
Color get_color (const Actiongraph *actiongraph, const Action::Base *action)
 Get the color for the commit message of an action.
bool is_create (const Action::Base *action)
 Checks whether action points to an Action::Create.
bool is_delete (const Action::Base *action)
 Checks whether action points to an Action::Delete.
bool is_modify (const Action::Base *action)
 Checks whether action points to an Action::Modify.
std::ostream & operator<< (std::ostream &str, const CodeLocation &obj)
 CodeLocation stream output.
std::ostream & operator<< (std::ostream &str, const Exception &obj)
 Exception stream output.
int num_suffixes ()
 Return number of suffixes.
std::string get_suffix (int i, bool classic)
 Return a suffix.
std::string byte_to_humanstring (unsigned long long size, bool classic, int precision, bool omit_zeroes)
 Return a pretty description of a size with required precision and using B, KiB, MiB, GiB, TiB, PiB or EiB as unit as appropriate.
unsigned long long humanstring_to_byte (const std::string &str, bool classic)
 Converts a size description using B, KiB, KB, MiB, MB, GiB, GB, TiB, TB, PiB, PB, EiB or EB into an integer.
bool light_probe ()
 This function does some very light probing and returns true iff some disks or DASDs were found in the system.
bool light_probe (SystemInfo &system_info)
 Same as light_probe() except for the SystemInfo parameter.
Loggerget_logger ()
 Get the current logger object.
void set_logger (Logger *logger)
 Set the current logger object.
Loggerget_stdout_logger ()
 Returns a Logger that logs to stdout.
Loggerget_logfile_logger (const std::string &filename="/var/log/libstorage.log")
 Returns a Logger that logs to the standard libstorage log file ("/var/log/libstorage.log") or to a given file.
const RemoteCallbacksget_remote_callbacks ()
void set_remote_callbacks (const RemoteCallbacks *remote_callbacks)
std::ostream & operator<< (std::ostream &s, const Arch &arch)

Variables

const unsigned long long B = 1
 Abbreviation for byte.
const unsigned long long KiB = 1024 * B
 Abbreviation for kibibyte.
const unsigned long long MiB = 1024 * KiB
 Abbreviation for mebibyte.
const unsigned long long GiB = 1024 * MiB
 Abbreviation for gibibyte.
const unsigned long long TiB = 1024 * GiB
 Abbreviation for tebibyte.
const unsigned long long PiB = 1024 * TiB
 Abbreviation for pebibyte.
const unsigned long long EiB = 1024 * PiB
 Abbreviation for exbibyte.

Detailed Description

The storage namespace.

Typedef Documentation

◆ sid_t

typedef unsigned int storage::sid_t

An integer storage ID. The storage id (sid) is used to identify devices. The sid is copied when copying the device graph. When adding a device it gets a unique sid (across all device graphs). By using the storage id instead of a device name we can easily identify devices where the device name changed, e.g. renumbered logical partitions or renamed logical volumes. Also some devices do not have a intrinsic device name, e.g. btrfs. We could even have objects for unused space, e.g. space between partitions or unallocated space of a volume group.

Whenever possible use the storage id to find objects instead of e.g. the name since only the storage id guarantees uniqueness.

Enumeration Type Documentation

◆ anonymous enum

anonymous enum : uint32_t

Resize blockers.

Some resize operations are not supported by the system (e.g. shrink LVM thin pool) while others are not supported by the library (e.g. resize extended partition).

Enumerator
RB_RESIZE_NOT_SUPPORTED_BY_DEVICE 

The device or one of its descendants that also needs resizing does not support resizing.

This is the case for Disks, Dasds, Mds, DmRaids, Multipaths, PartitionTables, LvmVgs, Bcaches, BcacheCsets, BtrfsSubvolumes, Nfses MountPoints, so basically everything except Partitions, LvmLvs and Lukses.

Blocks shrink and grow.

RB_MIN_MAX_ERROR 

Several limitations were combined, e.g.

limitations from partition and filesystem, and the result does not allow any resize.

Blocks shrink and grow.

RB_SHRINK_NOT_SUPPORTED_BY_FILESYSTEM 

The filesystem does not support shrink.

Blocks shrink.

RB_GROW_NOT_SUPPORTED_BY_FILESYSTEM 

The filesystem does not support grow.

Blocks grow.

RB_FILESYSTEM_INCONSISTENT 

The filesystem seems to be inconsistent or checking filesystem consistency failed.

Blocks shrink and grow.

RB_MIN_SIZE_FOR_FILESYSTEM 

The filesystem has already the minimal possible size.

Blocks shrink.

RB_MAX_SIZE_FOR_FILESYSTEM 

The filesystem has already the maximal possible size.

Blocks grow.

RB_FILESYSTEM_FULL 

The filesystem is full and cannot be shrunk.

Blocks shrink.

RB_NO_SPACE_BEHIND_PARTITION 

No space behind partition.

There can be several reasons: 1. other partition, 2. end of disk, 3. end of extended partition, 4. space not addressable by partition table.

Blocks grow.

RB_MIN_SIZE_FOR_PARTITION 

The partition has already the minimal possible size.

Blocks shrink.

RB_EXTENDED_PARTITION 

Extended partitions cannot be resized.

Blocks shrink and grow.

RB_ON_IMPLICIT_PARTITION_TABLE 

Partition on an implicit partition table cannot be resized.

Blocks shrink and grow.

RB_SHRINK_NOT_SUPPORTED_FOR_LVM_LV_TYPE 

Shrink of LVM logical volume of this type not supported, e.g.

thin pools and RAIDs.

Blocks shrink.

RB_RESIZE_NOT_SUPPORTED_FOR_LVM_LV_TYPE 

Resize of LVM logical volume of this type not supported, e.g.

RAIDs.

Blocks shrink and grow.

RB_NO_SPACE_IN_LVM_VG 

No space left in LVM volume group.

Blocks grow.

RB_MIN_SIZE_FOR_LVM_LV 

The LVM logical volume has already the minimal possible size.

Blocks shrink.

RB_MAX_SIZE_FOR_LVM_LV_THIN 

LVM thin logical volume has already maximal size.

Blocks grow.

RB_SHRINK_NOT_SUPPORTED_BY_MULTIDEVICE_FILESYSTEM 

Multi-device filesystems (i.e., Btrfs) do not support shrink.

Blocks shrink.

RB_PASSWORD_REQUIRED 

The encryption password is required.

RB_RESIZE_NOT_SUPPORTED_DUE_TO_SNAPSHOTS 

Resize of LVM logical volume is not supported since it has snapshots.

Blocks shrink and grow.

RB_FILESYSTEM_MOUNT_READ_ONLY 

The filesystem is mounted read-only.

Blocks shrink and grow.

◆ anonymous enum

anonymous enum : uint64_t
Enumerator
UF_QUOTA 

Quota for ext4 or xfs.

Not for btrfs.

◆ anonymous enum

anonymous enum : uint32_t

Remove blockers.

Some remove operations are not supported (e.g. remove a disk or DASD). Some are not supported by the library (e.g. remove a partition if that causes renumbering of active partition).

Be careful: Temporarily deactivating e.g. a mount point with the aim of getting rid of the blocker will result in failures later on.

Enumerator
RMB_HARDWARE 

The device corresponds to hardware, e.g.

a disks, DASDs, multipath devices or BIOS RAIDs.

RMB_RENUMBER_ACTIVE_PARTITIONS 

Removing the partition would result in renumbering of partitions with active stuff on them.

RMB_ON_IMPLICIT_PARTITION_TABLE 

Partition on an implicit partition table cannot be removed - at least not without creating a partition table.

◆ AlignPolicy

enum class storage::AlignPolicy
strong
Enumerator
ALIGN_START_AND_END 

Align start and end.

ALIGN_START_KEEP_END 

Align start and keep end.

ALIGN_START_KEEP_SIZE 

Align start and keep size.

KEEP_START_ALIGN_END 

Keep start and align end.

◆ AlignType

enum class storage::AlignType
strong
Enumerator
REQUIRED 

Only align to hard requirements.

OPTIMAL 

Align to topology information.

◆ BtrfsRaidLevel

enum class storage::BtrfsRaidLevel
strong

Btrfs RAID levels (aka profiles) used for metadata and data.

See also
https://btrfs.wiki.kernel.org/index.php/Using_Btrfs_with_Multiple_Devices

◆ Color

enum class storage::Color
strong

A color suggestion for commit messages.

In general the color is green for action that create, mount or activate something, red for action that delete, unmount or deactivate something and black otherwise.

The color of an action is not set in stone and may change in the future. It must only be used to displaying messages. Not for any other logic!

See also
get_color()

◆ GraphvizFlags

enum class storage::GraphvizFlags : unsigned int
strong

Bitfield to control graphviz output.

Not all flags apply to all graphs or all objects (devices, holders and actions).

◆ IdNum

enum storage::IdNum : unsigned int

Enum with values used as partition ids.

For MS-DOS the value of the enum is equal to the partition type byte. For GPT, DASD and Implicit the value has no special meaning.

For MS-DOS any value between 0 and 255 is possible, while for the other partition tables only those specified are possible.

For details about the ids see e.g. https://en.wikipedia.org/wiki/Partition_type, https://en.wikipedia.org/wiki/GUID_Partition_Table and https://uapi-group.org/specifications/specs/discoverable_partitions_specification/.

Enumerator
ID_DOS12 

Only for MS-DOS.

ID_DOS16 

Only for MS-DOS.

ID_NTFS 

Only for MS-DOS.

ID_DOS32 

Only for MS-DOS.

ID_EXTENDED 

Only for MS-DOS.

ID_DIAG 

For MS-DOS and GPT.

ID_PREP 

PPC PReP Boot partition, for MS-DOS and GPT.

ID_SWAP 

Swap partition, for MS-DOS, GPT and DASD.

ID_LINUX 

For MS-DOS, GPT, DASD and implicit.

Unfortunately with old parted versions this is the fallback for unknown ids on GPT.

ID_IRST 

Intel Rapid Start Technology, for MS-DOS and GPT.

ID_LVM 

LVM partition, for MS-DOS, GPT and DASD.

ID_RAID 

RAID partition, for MS-DOS, GPT and DASD.

ID_ESP 

EFI System Partition, for MS-DOS and GPT.

ID_UNKNOWN 

Only set during probing.

For MS-DOS, GPT, DASD and implicit.

ID_BIOS_BOOT 

BIOS boot partition (https://en.wikipedia.org/wiki/BIOS_boot_partition), only for GPT.

ID_WINDOWS_BASIC_DATA 

Windows basic data partition, only for GPT.

ID_MICROSOFT_RESERVED 

Microsoft reserved partition, only for GPT.

ID_LINUX_HOME 

Linux Home, only for GPT.

Requires parted 3.5 or higher.

ID_LINUX_SERVER_DATA 

Linux Server Data, only for GPT.

Requires SUSE parted 3.5 or higher.

ID_LINUX_ROOT_ARM 

Linux Root Partition (arm), only for GPT.

Requires SUSE parted 3.5 or higher.

ID_LINUX_ROOT_AARCH64 

Linux Root Partition (aarch64), only for GPT.

Requires SUSE parted 3.5 or higher.

ID_LINUX_ROOT_PPC32 

Linux Root Partition (ppc), only for GPT.

Requires SUSE parted 3.5 or higher.

ID_LINUX_ROOT_PPC64BE 

Linux Root Partition (ppc64be), only for GPT.

Requires SUSE parted 3.5 or higher.

ID_LINUX_ROOT_PPC64LE 

Linux Root Partition (ppc64le), only for GPT.

Requires SUSE parted 3.5 or higher.

ID_LINUX_ROOT_RISCV32 

Linux Root Partition (riscv32, only for GPT.

Requires SUSE parted 3.5 or higher.

ID_LINUX_ROOT_RISCV64 

Linux Root Partition (riscv64), only for GPT.

Requires SUSE parted 3.5 or higher.

ID_LINUX_ROOT_S390 

Linux Root Partition (s390), only for GPT.

Requires SUSE parted 3.5 or higher.

ID_LINUX_ROOT_S390X 

Linux Root Partition (s390x), only for GPT.

Requires SUSE parted 3.5 or higher.

ID_LINUX_ROOT_X86 

Linux Root Partition (x86), only for GPT.

Requires SUSE parted 3.5 or higher.

ID_LINUX_ROOT_X86_64 

Linux Root Partition (x86_64), only for GPT.

Requires SUSE parted 3.5 or higher.

ID_LINUX_USR_ARM 

Linux USR Partition (arm), only for GPT.

Requires SUSE parted 3.5 or higher.

ID_LINUX_USR_AARCH64 

Linux USR Partition (aarch64), only for GPT.

Requires SUSE parted 3.5 or higher.

ID_LINUX_USR_PPC32 

Linux USR Partition (ppc), only for GPT.

Requires SUSE parted 3.5 or higher.

ID_LINUX_USR_PPC64BE 

Linux USR Partition (ppc64be), only for GPT.

Requires SUSE parted 3.5 or higher.

ID_LINUX_USR_PPC64LE 

Linux USR Partition (ppc64le), only for GPT.

Requires SUSE parted 3.5 or higher.

ID_LINUX_USR_RISCV32 

Linux USR Partition (riscv32), only for GPT.

Requires SUSE parted 3.5 or higher.

ID_LINUX_USR_RISCV64 

Linux USR Partition (riscv64), only for GPT.

Requires SUSE parted 3.5 or higher.

ID_LINUX_USR_S390 

Linux USR Partition (s390), only for GPT.

Requires SUSE parted 3.5 or higher.

ID_LINUX_USR_S390X 

Linux USR Partition (s390x), only for GPT.

Requires SUSE parted 3.5 or higher.

ID_LINUX_USR_X86 

Linux USR Partition (x86), only for GPT.

Requires SUSE parted 3.5 or higher.

ID_LINUX_USR_X86_64 

Linux USR Partition (x86_64), only for GPT.

Requires SUSE parted 3.5 or higher.

◆ LvType

enum class storage::LvType
strong

LVM logical volume types, see lvs(8).

Enumerator
UNKNOWN 

A logical volume of unknown type.

Cannot be used as a blk device. Cannot be created by the library.

NORMAL 

A linear or striped logical volume.

THIN_POOL 

A thin-pool logical volume.

Cannot be used as a blk device.

THIN 

A thin logical volume.

RAID 

A raid logical volume.

Cannot be created by the library.

CACHE_POOL 

A cache-pool logical volume.

Cannot be used as a blk device. Cannot be created by the library.

CACHE 

A cache logical volume.

Cannot be created by the library.

WRITECACHE 

A writecache logical volume.

Cannot be created by the library.

SNAPSHOT 

A thick snapshot.

Thin snapshots have the type THIN.

Cannot be created by the library.

MIRROR 

A mirror volume.

This is different from RAID1 in that it has the mirror log on a separate device.

Cannot be created by the library.

◆ MountByType

enum class storage::MountByType
strong

The key by which the mount program identifies a mountable.

Some types address the filesystem while others address the underlying device.

Enumerator
DEVICE 

The kernel device name or a link in /dev (but not in /dev/disk).

For NFS the server and path.

UUID 

Filesystem UUID.

LABEL 

Filesystem label.

ID 

One of the links in /dev/disk/by-id.

PATH 

One of the links in /dev/disk/by-path.

PARTUUID 

Partition UUID, only for partitions on GPT.

Experimental.

PARTLABEL 

Partition label, only for partitions on GPT.

Experimental.

◆ PartitionType

enum class storage::PartitionType
strong

Enum with partition types.

Enumerator
PRIMARY 

Primary partition.

For all partition table types.

The type PRIMARY is also used for partitions on partition tables that have no partition type.

EXTENDED 

Extended partition.

Only for MS-DOS.

LOGICAL 

Logical partition.

Only for MS-DOS.

◆ TargetMode

enum class storage::TargetMode
strong

Enum with target modes.

Enumerator
DIRECT 

Direct target.

CHROOT 

The target is chrooted, e.g.

inst-sys.

IMAGE 

The target is image based.

Experimental.

◆ UsedFeaturesDependencyType

Enum specifying the dependency type of used features.

Enumerator
REQUIRED 

Required used features only include the minimal set of used features.

SUGGESTED 

Suggested used features include compared to the required used features also filesystems that have no mount point.

◆ View

enum class storage::View
strong

Enum with possible views on the devicegraph.

Enumerator
ALL 

All devices and holders are visible.

The resulting devicegraph is a directed graph.

CLASSIC 

The classical view.

Devices of type BtrfsQgroup and holders of type Snapshot and BtrfsQgroupRelation are not visible.

The resulting devicegraph is a directed acyclic graph.

REMOVE 

A special view for removing devices.

This view is useful when removing descendants. When removing a normal logical volume with snapshots the snapshots must also be removed. When removing a thin logical volume the snapshots can stay. This view implements this behaviour.

The resulting devicegraph is a directed acyclic graph.

◆ ZoneModel

Function Documentation

◆ byte_to_humanstring()

std::string storage::byte_to_humanstring ( unsigned long long size,
bool classic,
int precision,
bool omit_zeroes )

Return a pretty description of a size with required precision and using B, KiB, MiB, GiB, TiB, PiB or EiB as unit as appropriate.

Supported range is 0 B to (16 EiB - 1 B).

Parameters
sizesize in bytes
classicuse classic locale instead of global C++ locale
precisionnumber of fraction digits in output
omit_zeroesif true omit trailing zeroes for exact values
Returns
formatted string

◆ get_bcache_type_name()

std::string storage::get_bcache_type_name ( BcacheType bcache_type)

Convert the BcacheType bcache_type to a string.

See also
BcacheType

◆ get_btrfs_raid_level_name()

std::string storage::get_btrfs_raid_level_name ( BtrfsRaidLevel btrfs_raid_level)

Convert the btrfs RAID level btrfs_raid_level to a string.

See also
BtrfsRaidLevel

◆ get_cache_mode_name()

std::string storage::get_cache_mode_name ( CacheMode cache_mode)

Convert the CacheMode cache_mode to a string.

See also
CacheMode

◆ get_color()

Color storage::get_color ( const Actiongraph * actiongraph,
const Action::Base * action )

Get the color for the commit message of an action.

See also
Color

◆ get_dasd_format_name()

std::string storage::get_dasd_format_name ( DasdFormat dasd_format)

Convert the DASD format dasd_format to a string.

See also
DasdFormat

◆ get_dasd_type_name()

std::string storage::get_dasd_type_name ( DasdType dasd_type)

Convert the DASD type dasd_type to a string.

See also
DasdType

◆ get_debug_actiongraph_style_callbacks()

ActiongraphStyleCallbacks * storage::get_debug_actiongraph_style_callbacks ( )

Get a ActiongraphStyleCallbacks object for debugging.

Attributes are likely colorful and include information like the action text and the storage id. The attributes may change any time.

◆ get_debug_devicegraph_style_callbacks()

DevicegraphStyleCallbacks * storage::get_debug_devicegraph_style_callbacks ( )

Get a DevicegraphStyleCallbacks object for debugging.

Attributes are likely colorful and include information like the class name and the storage id. The attributes may change any time.

◆ get_encryption_type_name()

std::string storage::get_encryption_type_name ( EncryptionType encryption_type)

Convert the EncryptionType encryption_type to a string.

See also
EncryptionType

◆ get_fs_type_name()

std::string storage::get_fs_type_name ( FsType fs_type)

Convert the FsType fs_type to a string.

See also
FsType

◆ get_libversion_string()

const char * storage::get_libversion_string ( )

Return LIBSTORAGE_NG_VERSION_STRING libstorage-ng was compiled with.

May differ from the define (compile time vs. link time).

◆ get_linux_partition_id() [1/2]

IdNum storage::get_linux_partition_id ( LinuxPartitionIdCategory linux_partition_id_category,
const Arch & arch )

Get the partition id for the Linux partition of the given category (root, usr, ...) depending on the architecture.

See also
IdNum, LinuxPartitionIdCategory
Exceptions
Exception

◆ get_linux_partition_id() [2/2]

IdNum storage::get_linux_partition_id ( LinuxPartitionIdCategory linux_partition_id_category,
SystemInfo & system_info )

Get the partition id for the Linux partition of the given category (root, usr, ...) depending on the architecture.

See also
IdNum, LinuxPartitionIdCategory
Exceptions
Exception

◆ get_logfile_logger()

Logger * storage::get_logfile_logger ( const std::string & filename = "/var/log/libstorage.log")

Returns a Logger that logs to the standard libstorage log file ("/var/log/libstorage.log") or to a given file.

Do not use this function for production code but only for examples and test-cases.

Note that this method only uses the given filename the first time it is called.

◆ get_lv_type_name()

std::string storage::get_lv_type_name ( LvType lv_type)

Convert LvType to string.

See also
LvType

◆ get_md_level_name()

std::string storage::get_md_level_name ( MdLevel md_level)

Convert the MD RAID level md_level to a string.

See also
MdLevel

◆ get_md_parity_name()

std::string storage::get_md_parity_name ( MdParity md_parity)

Convert the MD parity algorithm md_parity to a string.

See also
MdParity

◆ get_mount_by_name()

std::string storage::get_mount_by_name ( MountByType mount_by_type)

Convert the MountByType mount_by_type to a string.

See also
MountByType

◆ get_partition_id_name()

std::string storage::get_partition_id_name ( IdNum partition_id)

Convert the IdNum partition_id to a string.

Note
An empty string could be returned (e.g., when the given partition id is unknown).
See also
IdNum

◆ get_partition_type_name()

std::string storage::get_partition_type_name ( PartitionType partition_type)

Convert the PartitionType partition_type to a string.

See also
PartitionType

◆ get_pt_type_name()

std::string storage::get_pt_type_name ( PtType pt_type)

Convert the PtType pt_type to a string.

See also
PtType

◆ get_stdout_logger()

Logger * storage::get_stdout_logger ( )

Returns a Logger that logs to stdout.

Do not use this function for production code but only for examples and test-cases.

◆ get_string()

std::string storage::get_string ( const Actiongraph * actiongraph,
const Action::Base * action )

Get the commit message of an action.

TODO: This should be a member function of Action::Base but that is not available in the API in all details.

◆ get_suffix()

std::string storage::get_suffix ( int i,
bool classic )

Return a suffix.

Parameters
iindex of suffix
classicuse classic locale instead of global C++ locale
Returns
suffix

◆ get_transport_name()

std::string storage::get_transport_name ( Transport transport)

Convert the Transport transport to a string.

See also
Transport

◆ get_used_features_dependency_type_name()

std::string storage::get_used_features_dependency_type_name ( UsedFeaturesDependencyType used_features_dependency_type)

Convert the UsedFeaturesDependencyType used_features_dependency_type to a string.

See also
UsedFeaturesDependencyType

◆ get_used_features_names()

std::string storage::get_used_features_names ( uf_t used_features)

Return a string with the names of the used features.

Not for production code.

◆ get_zone_model_name()

std::string storage::get_zone_model_name ( ZoneModel zone_model)

Convert the ZoneModel zone_model to a string.

See also
ZoneModel

◆ humanstring_to_byte()

unsigned long long storage::humanstring_to_byte ( const std::string & str,
bool classic )

Converts a size description using B, KiB, KB, MiB, MB, GiB, GB, TiB, TB, PiB, PB, EiB or EB into an integer.

Decimal suffixes are treated as binary. Supported range is 0 B to (16 EiB - 1 B).

Parameters
strsize string
classicuse classic locale instead of global C++ locale
Returns
bytes

The conversion is always case-insensitive. With classic set to false the conversion is also sloppy concerning omission of 'B'.

Exceptions
ParseException,OverflowException

◆ is_bcache()

bool storage::is_bcache ( const Device * device)

Checks whether device points to a Bcache.

Exceptions
NullPointerException

◆ is_bcache_cset()

bool storage::is_bcache_cset ( const Device * device)

Checks whether device points to a BcacheCset.

Exceptions
NullPointerException

◆ is_bcachefs()

bool storage::is_bcachefs ( const Device * device)

Checks whether device points to an Bcachefs.

Exceptions
NullPointerException

◆ is_bitlocker()

bool storage::is_bitlocker ( const Device * device)

Checks whether device points to an Bitlocker.

Exceptions
NullPointerException

◆ is_bitlocker_v2()

bool storage::is_bitlocker_v2 ( const Device * device)

Checks whether device points to a BitlockerV2.

Exceptions
NullPointerException

◆ is_blk_device()

bool storage::is_blk_device ( const Device * device)

Checks whether device points to an BlkDevice.

Exceptions
NullPointerException

◆ is_blk_filesystem()

bool storage::is_blk_filesystem ( const Device * device)

Checks whether device points to a BlkFilesystem.

Exceptions
NullPointerException

◆ is_btrfs()

bool storage::is_btrfs ( const Device * device)

Checks whether device points to a Btrfs.

Exceptions
NullPointerException

◆ is_btrfs_qgroup()

bool storage::is_btrfs_qgroup ( const Device * device)

Checks whether device points to a Btrfs.

Exceptions
NullPointerException

◆ is_btrfs_qgroup_relation()

bool storage::is_btrfs_qgroup_relation ( const Holder * holder)

Checks whether holder points to a BtrfsQgroupRelation.

Exceptions
NullPointerException

◆ is_btrfs_subvolume()

bool storage::is_btrfs_subvolume ( const Device * device)

Checks whether device points to a BtrfsSubvolume.

Exceptions
NullPointerException

◆ is_create()

bool storage::is_create ( const Action::Base * action)

Checks whether action points to an Action::Create.

Exceptions
NullPointerException

◆ is_dasd()

bool storage::is_dasd ( const Device * device)

Checks whether device points to a Dasd.

Exceptions
NullPointerException

◆ is_dasd_pt()

bool storage::is_dasd_pt ( const Device * device)

Checks whether device points to a DasdPt.

Exceptions
NullPointerException

◆ is_delete()

bool storage::is_delete ( const Action::Base * action)

Checks whether action points to an Action::Delete.

Exceptions
NullPointerException

◆ is_disk()

bool storage::is_disk ( const Device * device)

Checks whether device points to a Disk.

Exceptions
NullPointerException

◆ is_dm_raid()

bool storage::is_dm_raid ( const Device * device)

Checks whether device points to a DmRaid.

Exceptions
NullPointerException

◆ is_encryption()

bool storage::is_encryption ( const Device * device)

Checks whether device points to an Encryption.

Exceptions
NullPointerException

◆ is_exfat()

bool storage::is_exfat ( const Device * device)

Checks whether device points to an Exfat.

Exceptions
NullPointerException

◆ is_ext()

bool storage::is_ext ( const Device * device)

Checks whether device points to an Ext.

Exceptions
NullPointerException

◆ is_ext2()

bool storage::is_ext2 ( const Device * device)

Checks whether device points to an Ext2.

Exceptions
NullPointerException

◆ is_ext3()

bool storage::is_ext3 ( const Device * device)

Checks whether device points to an Ext3.

Exceptions
NullPointerException

◆ is_ext4()

bool storage::is_ext4 ( const Device * device)

Checks whether device points to an Ext4.

Exceptions
NullPointerException

◆ is_f2fs()

bool storage::is_f2fs ( const Device * device)

Checks whether device points to a F2fs.

Exceptions
NullPointerException

◆ is_filesystem()

bool storage::is_filesystem ( const Device * device)

Checks whether device points to a Filesystem.

Exceptions
NullPointerException

◆ is_filesystem_user()

bool storage::is_filesystem_user ( const Holder * holder)

Checks whether holder points to a FilesystemUser.

Exceptions
NullPointerException

◆ is_gpt()

bool storage::is_gpt ( const Device * device)

Checks whether device points to a Gpt.

Exceptions
NullPointerException

◆ is_implicit_pt()

bool storage::is_implicit_pt ( const Device * device)

Checks whether device points to a ImplicitPt.

Exceptions
NullPointerException

◆ is_iso9660()

bool storage::is_iso9660 ( const Device * device)

Checks whether device points to a Iso9660.

Exceptions
NullPointerException

◆ is_jfs()

bool storage::is_jfs ( const Device * device)

Checks whether device points to a Jfs.

Exceptions
NullPointerException

◆ is_linux_partition_id() [1/2]

bool storage::is_linux_partition_id ( IdNum id)

Check whether the id is a Linux partition id.

Thus true for e.g. ID_LINUX, ID_LINUX_HOME, ID_LINUX_ROOT_X86_64 and ID_RAID and false for e.g. ID_ESP and ID_PREP.

See also
IdNum

◆ is_linux_partition_id() [2/2]

bool storage::is_linux_partition_id ( IdNum id,
LinuxPartitionIdCategory linux_partition_id_category )

Check whether the id is a Linux partition id of the specified category.

See also
IdNum, LinuxPartitionIdCategory

◆ is_luks()

bool storage::is_luks ( const Device * device)

Checks whether device points to a Luks.

Exceptions
NullPointerException

◆ is_lvm_lv()

bool storage::is_lvm_lv ( const Device * device)

Checks whether device points to a LvmLv.

Exceptions
NullPointerException

◆ is_lvm_pv()

bool storage::is_lvm_pv ( const Device * device)

Checks whether device points to a LvmPv.

Exceptions
NullPointerException

◆ is_lvm_vg()

bool storage::is_lvm_vg ( const Device * device)

Checks whether device points to a LvmVg.

Exceptions
NullPointerException

◆ is_md()

bool storage::is_md ( const Device * device)

Checks whether device points to a Md.

Exceptions
NullPointerException

◆ is_md_container()

bool storage::is_md_container ( const Device * device)

Checks whether device points to an MdContainer.

Exceptions
NullPointerException

◆ is_md_member()

bool storage::is_md_member ( const Device * device)

Checks whether device points to a MdMember.

Exceptions
NullPointerException

◆ is_md_subdevice()

bool storage::is_md_subdevice ( const Holder * holder)

Checks whether holder points to an MdSubdevice.

Exceptions
NullPointerException

◆ is_md_user()

bool storage::is_md_user ( const Holder * holder)

Checks whether holder points to a MdUser.

Exceptions
NullPointerException

◆ is_modify()

bool storage::is_modify ( const Action::Base * action)

Checks whether action points to an Action::Modify.

Exceptions
NullPointerException

◆ is_mount_point()

bool storage::is_mount_point ( const Device * device)

Checks whether device points to a MountPoint.

Exceptions
NullPointerException

◆ is_mountable()

bool storage::is_mountable ( const Device * device)

Checks whether device points to a Mountable.

Exceptions
NullPointerException

◆ is_msdos()

bool storage::is_msdos ( const Device * device)

Checks whether device points to an Msdos.

Exceptions
NullPointerException

◆ is_multipath()

bool storage::is_multipath ( const Device * device)

Checks whether device points to a Multipath.

Exceptions
NullPointerException

◆ is_nfs()

bool storage::is_nfs ( const Device * device)

Checks whether device points to a Nfs.

Exceptions
NullPointerException

◆ is_nilfs2()

bool storage::is_nilfs2 ( const Device * device)

Checks whether device points to a Nilfs2.

Exceptions
NullPointerException

◆ is_ntfs()

bool storage::is_ntfs ( const Device * device)

Checks whether device points to a Ntfs.

Exceptions
NullPointerException

◆ is_partition()

bool storage::is_partition ( const Device * device)

Checks whether device points to a Partition.

Exceptions
NullPointerException

◆ is_partition_table()

bool storage::is_partition_table ( const Device * device)

Checks whether device points to a PartitionTable.

Exceptions
NullPointerException

◆ is_partitionable()

bool storage::is_partitionable ( const Device * device)

Checks whether device points to a Partitionable.

Exceptions
NullPointerException

◆ is_plain_encryption()

bool storage::is_plain_encryption ( const Device * device)

Checks whether device points to a PlainEncryption.

Exceptions
NullPointerException

◆ is_reiserfs()

bool storage::is_reiserfs ( const Device * device)

Checks whether device points to an Reiserfs.

Exceptions
NullPointerException

◆ is_snapshot()

bool storage::is_snapshot ( const Holder * holder)

Checks whether holder points to a Snapshot.

Exceptions
NullPointerException

◆ is_stray_blk_device()

bool storage::is_stray_blk_device ( const Device * device)

Checks whether device points to a StrayBlkDevice.

Exceptions
NullPointerException

◆ is_subdevice()

bool storage::is_subdevice ( const Holder * holder)

Checks whether holder points to a Subdevice.

Exceptions
NullPointerException

◆ is_swap()

bool storage::is_swap ( const Device * device)

Checks whether device points to an Swap.

Exceptions
NullPointerException

◆ is_tmpfs()

bool storage::is_tmpfs ( const Device * device)

Checks whether device points to a Tmpfs.

Exceptions
NullPointerException

◆ is_udf()

bool storage::is_udf ( const Device * device)

Checks whether device points to an Udf.

Exceptions
NullPointerException

◆ is_user()

bool storage::is_user ( const Holder * holder)

Checks whether holder points to an User.

Exceptions
NullPointerException

◆ is_vfat()

bool storage::is_vfat ( const Device * device)

Checks whether device points to a Vfat.

Exceptions
NullPointerException

◆ is_xfs()

bool storage::is_xfs ( const Device * device)

Checks whether device points to a Xfs.

Exceptions
NullPointerException

◆ light_probe() [1/2]

bool storage::light_probe ( )

This function does some very light probing and returns true iff some disks or DASDs were found in the system.

No devicegraph is generated. The exact type of devices probed may change.

Exceptions
Exception

◆ light_probe() [2/2]

bool storage::light_probe ( SystemInfo & system_info)

Same as light_probe() except for the SystemInfo parameter.

See also
light_probe()
Exceptions
Exception

◆ num_suffixes()

int storage::num_suffixes ( )

Return number of suffixes.

Returns
number of suffixes

◆ operator<<()

std::ostream & storage::operator<< ( std::ostream & str,
const CodeLocation & obj )

CodeLocation stream output.

Stream output.

◆ read_simple_etc_crypttab()

std::vector< SimpleEtcCrypttabEntry > storage::read_simple_etc_crypttab ( const std::string & filename)

Read a crypttab file.

Whether the function returns an empty vector or throws an exception if reading or parsing fails is undefined.

Exceptions
Exception

◆ read_simple_etc_fstab()

std::vector< SimpleEtcFstabEntry > storage::read_simple_etc_fstab ( const std::string & filename)

Read a fstab file.

Whether the function returns an empty vector or throws an exception if reading or parsing fails is undefined.

Exceptions
Exception

◆ set_logger()

void storage::set_logger ( Logger * logger)

Set the current logger object.

The logger object must be valid until replaced by another logger object.

◆ to_bcache() [1/2]

const Bcache * storage::to_bcache ( const Device * device)

Converts pointer to Device to pointer to Bcache.

Returns
Pointer to Bcache.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_bcache() [2/2]

Bcache * storage::to_bcache ( Device * device)

Converts pointer to Device to pointer to Bcache.

Returns
Pointer to Bcache.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_bcache_cset() [1/2]

const BcacheCset * storage::to_bcache_cset ( const Device * device)

Converts pointer to Device to pointer to BcacheCset.

Returns
Pointer to BcacheCset.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_bcache_cset() [2/2]

BcacheCset * storage::to_bcache_cset ( Device * device)

Converts pointer to Device to pointer to BcacheCset.

Returns
Pointer to BcacheCset.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_bcachefs() [1/2]

const Bcachefs * storage::to_bcachefs ( const Device * device)

Converts pointer to Device to pointer to Bcachefs.

Returns
Pointer to Bcachefs.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_bcachefs() [2/2]

Bcachefs * storage::to_bcachefs ( Device * device)

Converts pointer to Device to pointer to Bcachefs.

Returns
Pointer to Bcachefs.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_bitlocker() [1/2]

const Bitlocker * storage::to_bitlocker ( const Device * device)

Converts pointer to Device to pointer to Bitlocker.

Returns
Pointer to Bitlocker.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_bitlocker() [2/2]

Bitlocker * storage::to_bitlocker ( Device * device)

Converts pointer to Device to pointer to Bitlocker.

Returns
Pointer to Bitlocker.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_bitlocker_v2() [1/2]

const BitlockerV2 * storage::to_bitlocker_v2 ( const Device * device)

Converts pointer to Device to pointer to BitlockerV2.

Returns
Pointer to BitlockerV2.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_bitlocker_v2() [2/2]

BitlockerV2 * storage::to_bitlocker_v2 ( Device * device)

Converts pointer to Device to pointer to BitlockerV2.

Returns
Pointer to BitlockerV2.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_blk_device() [1/2]

const BlkDevice * storage::to_blk_device ( const Device * device)

Converts pointer to Device to pointer to BlkDevice.

Returns
Pointer to BlkDevice.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_blk_device() [2/2]

BlkDevice * storage::to_blk_device ( Device * device)

Converts pointer to Device to pointer to BlkDevice.

Returns
Pointer to BlkDevice.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_blk_filesystem() [1/2]

const BlkFilesystem * storage::to_blk_filesystem ( const Device * device)

Converts pointer to Device to pointer to BlkFilesystem.

Returns
Pointer to BlkFilesystem.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_blk_filesystem() [2/2]

BlkFilesystem * storage::to_blk_filesystem ( Device * device)

Converts pointer to Device to pointer to BlkFilesystem.

Returns
Pointer to BlkFilesystem.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_btrfs() [1/2]

const Btrfs * storage::to_btrfs ( const Device * device)

Converts pointer to Device to pointer to Btrfs.

Returns
Pointer to Btrfs.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_btrfs() [2/2]

Btrfs * storage::to_btrfs ( Device * device)

Converts pointer to Device to pointer to Btrfs.

Returns
Pointer to Btrfs.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_btrfs_qgroup() [1/2]

const BtrfsQgroup * storage::to_btrfs_qgroup ( const Device * device)

Converts pointer to Device to pointer to Btrfs.

Returns
Pointer to Btrfs.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_btrfs_qgroup() [2/2]

BtrfsQgroup * storage::to_btrfs_qgroup ( Device * device)

Converts pointer to Device to pointer to Btrfs.

Returns
Pointer to Btrfs.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_btrfs_qgroup_relation() [1/2]

const BtrfsQgroupRelation * storage::to_btrfs_qgroup_relation ( const Holder * holder)

Converts pointer to Holder to pointer to BtrfsQgroupRelation.

Returns
Pointer to BtrfsQgroupRelation.
Exceptions
HolderHasWrongType,NullPointerException

◆ to_btrfs_qgroup_relation() [2/2]

BtrfsQgroupRelation * storage::to_btrfs_qgroup_relation ( Holder * holder)

Converts pointer to Holder to pointer to BtrfsQgroupRelation.

Returns
Pointer to BtrfsQgroupRelation.
Exceptions
HolderHasWrongType,NullPointerException

◆ to_btrfs_subvolume() [1/2]

const BtrfsSubvolume * storage::to_btrfs_subvolume ( const Device * device)

Converts pointer to Device to pointer to BtrfsSubvolume.

Returns
Pointer to BtrfsSubvolume.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_btrfs_subvolume() [2/2]

BtrfsSubvolume * storage::to_btrfs_subvolume ( Device * device)

Converts pointer to Device to pointer to BtrfsSubvolume.

Returns
Pointer to BtrfsSubvolume.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_dasd() [1/2]

const Dasd * storage::to_dasd ( const Device * device)

Converts pointer to Device to pointer to Dasd.

Returns
Pointer to Dasd.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_dasd() [2/2]

Dasd * storage::to_dasd ( Device * device)

Converts pointer to Device to pointer to Dasd.

Returns
Pointer to Dasd.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_dasd_pt() [1/2]

const DasdPt * storage::to_dasd_pt ( const Device * device)

Converts pointer to Device to pointer to DasdPt.

Returns
Pointer to DasdPt.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_dasd_pt() [2/2]

DasdPt * storage::to_dasd_pt ( Device * device)

Converts pointer to Device to pointer to DasdPt.

Returns
Pointer to DasdPt.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_disk() [1/2]

const Disk * storage::to_disk ( const Device * device)

Converts pointer to Device to pointer to Disk.

Returns
Pointer to Disk.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_disk() [2/2]

Disk * storage::to_disk ( Device * device)

Converts pointer to Device to pointer to Disk.

Returns
Pointer to Disk.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_dm_raid() [1/2]

const DmRaid * storage::to_dm_raid ( const Device * device)

Converts pointer to Device to pointer to DmRaid.

Returns
Pointer to Dmraid.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_dm_raid() [2/2]

DmRaid * storage::to_dm_raid ( Device * device)

Converts pointer to Device to pointer to DmRaid.

Returns
Pointer to Dmraid.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_encryption() [1/2]

const Encryption * storage::to_encryption ( const Device * device)

Converts pointer to Device to pointer to Encryption.

Returns
Pointer to Encryption.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_encryption() [2/2]

Encryption * storage::to_encryption ( Device * device)

Converts pointer to Device to pointer to Encryption.

Returns
Pointer to Encryption.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_exfat() [1/2]

const Exfat * storage::to_exfat ( const Device * device)

Converts pointer to Device to pointer to Exfat.

Returns
Pointer to Exfat.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_exfat() [2/2]

Exfat * storage::to_exfat ( Device * device)

Converts pointer to Device to pointer to Exfat.

Returns
Pointer to Exfat.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_ext() [1/2]

const Ext * storage::to_ext ( const Device * device)

Converts pointer to Device to pointer to Ext.

Returns
Pointer to Ext.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_ext() [2/2]

Ext * storage::to_ext ( Device * device)

Converts pointer to Device to pointer to Ext.

Returns
Pointer to Ext.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_ext2() [1/2]

const Ext2 * storage::to_ext2 ( const Device * device)

Converts pointer to Device to pointer to Ext2.

Returns
Pointer to Ext2.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_ext2() [2/2]

Ext2 * storage::to_ext2 ( Device * device)

Converts pointer to Device to pointer to Ext2.

Returns
Pointer to Ext2.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_ext3() [1/2]

const Ext3 * storage::to_ext3 ( const Device * device)

Converts pointer to Device to pointer to Ext3.

Returns
Pointer to Ext3.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_ext3() [2/2]

Ext3 * storage::to_ext3 ( Device * device)

Converts pointer to Device to pointer to Ext3.

Returns
Pointer to Ext3.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_ext4() [1/2]

const Ext4 * storage::to_ext4 ( const Device * device)

Converts pointer to Device to pointer to Ext4.

Returns
Pointer to Ext4.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_ext4() [2/2]

Ext4 * storage::to_ext4 ( Device * device)

Converts pointer to Device to pointer to Ext4.

Returns
Pointer to Ext4.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_f2fs() [1/2]

const F2fs * storage::to_f2fs ( const Device * device)

Converts pointer to Device to pointer to F2fs.

Returns
Pointer to F2fs.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_f2fs() [2/2]

F2fs * storage::to_f2fs ( Device * device)

Converts pointer to Device to pointer to F2fs.

Returns
Pointer to F2fs.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_filesystem() [1/2]

const Filesystem * storage::to_filesystem ( const Device * device)

Converts pointer to Device to pointer to Filesystem.

Returns
Pointer to Filesystem.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_filesystem() [2/2]

Filesystem * storage::to_filesystem ( Device * device)

Converts pointer to Device to pointer to Filesystem.

Returns
Pointer to Filesystem.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_filesystem_user() [1/2]

const FilesystemUser * storage::to_filesystem_user ( const Holder * holder)

Converts pointer to Holder to pointer to FilesystemUser.

Returns
Pointer to FilesystemUser.
Exceptions
HolderHasWrongType,NullPointerException

◆ to_filesystem_user() [2/2]

FilesystemUser * storage::to_filesystem_user ( Holder * holder)

Converts pointer to Holder to pointer to FilesystemUser.

Returns
Pointer to FilesystemUser.
Exceptions
HolderHasWrongType,NullPointerException

◆ to_gpt() [1/2]

const Gpt * storage::to_gpt ( const Device * device)

Converts pointer to Device to pointer to Gpt.

Returns
Pointer to Gpt.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_gpt() [2/2]

Gpt * storage::to_gpt ( Device * device)

Converts pointer to Device to pointer to Gpt.

Returns
Pointer to Gpt.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_implicit_pt() [1/2]

const ImplicitPt * storage::to_implicit_pt ( const Device * device)

Converts pointer to Device to pointer to ImplicitPt.

Returns
Pointer to ImplicitPt.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_implicit_pt() [2/2]

ImplicitPt * storage::to_implicit_pt ( Device * device)

Converts pointer to Device to pointer to ImplicitPt.

Returns
Pointer to ImplicitPt.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_iso9660() [1/2]

const Iso9660 * storage::to_iso9660 ( const Device * device)

Converts pointer to Device to pointer to Iso9660.

Returns
Pointer to Iso9660.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_iso9660() [2/2]

Iso9660 * storage::to_iso9660 ( Device * device)

Converts pointer to Device to pointer to Iso9660.

Returns
Pointer to Iso9660.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_jfs() [1/2]

const Jfs * storage::to_jfs ( const Device * device)

Converts pointer to Device to pointer to Jfs.

Returns
Pointer to Jfs.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_jfs() [2/2]

Jfs * storage::to_jfs ( Device * device)

Converts pointer to Device to pointer to Jfs.

Returns
Pointer to Jfs.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_luks() [1/2]

const Luks * storage::to_luks ( const Device * device)

Converts pointer to Device to pointer to Luks.

Returns
Pointer to Luks.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_luks() [2/2]

Luks * storage::to_luks ( Device * device)

Converts pointer to Device to pointer to Luks.

Returns
Pointer to Luks.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_lvm_lv() [1/2]

const LvmLv * storage::to_lvm_lv ( const Device * device)

Converts pointer to Device to pointer to LvmLv.

Returns
Pointer to LvmLv.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_lvm_lv() [2/2]

LvmLv * storage::to_lvm_lv ( Device * device)

Converts pointer to Device to pointer to LvmLv.

Returns
Pointer to LvmLv.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_lvm_pv() [1/2]

const LvmPv * storage::to_lvm_pv ( const Device * device)

Converts pointer to Device to pointer to LvmPv.

Returns
Pointer to LvmPv.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_lvm_pv() [2/2]

LvmPv * storage::to_lvm_pv ( Device * device)

Converts pointer to Device to pointer to LvmPv.

Returns
Pointer to LvmPv.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_lvm_vg() [1/2]

const LvmVg * storage::to_lvm_vg ( const Device * device)

Converts pointer to Device to pointer to LvmVg.

Returns
Pointer to LvmVg.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_lvm_vg() [2/2]

LvmVg * storage::to_lvm_vg ( Device * device)

Converts pointer to Device to pointer to LvmVg.

Returns
Pointer to LvmVg.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_md() [1/2]

const Md * storage::to_md ( const Device * device)

Converts pointer to Device to pointer to Md.

Returns
Pointer to Md.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_md() [2/2]

Md * storage::to_md ( Device * device)

Converts pointer to Device to pointer to Md.

Returns
Pointer to Md.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_md_container() [1/2]

const MdContainer * storage::to_md_container ( const Device * device)

Converts pointer to Device to pointer to MdContainer.

Returns
Pointer to MdContainer.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_md_container() [2/2]

MdContainer * storage::to_md_container ( Device * device)

Converts pointer to Device to pointer to MdContainer.

Returns
Pointer to MdContainer.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_md_member() [1/2]

const MdMember * storage::to_md_member ( const Device * device)

Converts pointer to Device to pointer to MdMember.

Returns
Pointer to MdMember.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_md_member() [2/2]

MdMember * storage::to_md_member ( Device * device)

Converts pointer to Device to pointer to MdMember.

Returns
Pointer to MdMember.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_md_subdevice() [1/2]

const MdSubdevice * storage::to_md_subdevice ( const Holder * holder)

Converts pointer to Holder to pointer to MdSubdevice.

Returns
Pointer to MdSubdevice.
Exceptions
HolderHasWrongType,NullPointerException

◆ to_md_subdevice() [2/2]

MdSubdevice * storage::to_md_subdevice ( Holder * holder)

Converts pointer to Holder to pointer to MdSubdevice.

Returns
Pointer to MdSubdevice.
Exceptions
HolderHasWrongType,NullPointerException

◆ to_md_user() [1/2]

const MdUser * storage::to_md_user ( const Holder * holder)

Converts pointer to Holder to pointer to MdUser.

Returns
Pointer to MdUser.
Exceptions
HolderHasWrongType,NullPointerException

◆ to_md_user() [2/2]

MdUser * storage::to_md_user ( Holder * holder)

Converts pointer to Holder to pointer to MdUser.

Returns
Pointer to MdUser.
Exceptions
HolderHasWrongType,NullPointerException

◆ to_mount_point() [1/2]

const MountPoint * storage::to_mount_point ( const Device * device)

Converts pointer to Device to pointer to Mountpoint.

Returns
Pointer to Mountpoint.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_mount_point() [2/2]

MountPoint * storage::to_mount_point ( Device * device)

Converts pointer to Device to pointer to Mountpoint.

Returns
Pointer to Mountpoint.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_mountable() [1/2]

const Mountable * storage::to_mountable ( const Device * device)

Converts pointer to Device to pointer to Mountable.

Returns
Pointer to Mountable.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_mountable() [2/2]

Mountable * storage::to_mountable ( Device * device)

Converts pointer to Device to pointer to Mountable.

Returns
Pointer to Mountable.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_msdos() [1/2]

const Msdos * storage::to_msdos ( const Device * device)

Converts pointer to Device to pointer to Msdos.

Returns
Pointer to Msdos.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_msdos() [2/2]

Msdos * storage::to_msdos ( Device * device)

Converts pointer to Device to pointer to Msdos.

Returns
Pointer to Msdos.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_multipath() [1/2]

const Multipath * storage::to_multipath ( const Device * device)

Converts pointer to Device to pointer to Multipath.

Returns
Pointer to Multipath.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_multipath() [2/2]

Multipath * storage::to_multipath ( Device * device)

Converts pointer to Device to pointer to Multipath.

Returns
Pointer to Multipath.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_nfs() [1/2]

const Nfs * storage::to_nfs ( const Device * device)

Converts pointer to Device to pointer to Nfs.

Returns
Pointer to Nfs.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_nfs() [2/2]

Nfs * storage::to_nfs ( Device * device)

Converts pointer to Device to pointer to Nfs.

Returns
Pointer to Nfs.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_nilfs2() [1/2]

const Nilfs2 * storage::to_nilfs2 ( const Device * device)

Converts pointer to Device to pointer to Nilfs2.

Returns
Pointer to Nilfs2.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_nilfs2() [2/2]

Nilfs2 * storage::to_nilfs2 ( Device * device)

Converts pointer to Device to pointer to Nilfs2.

Returns
Pointer to Nilfs2.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_ntfs() [1/2]

const Ntfs * storage::to_ntfs ( const Device * device)

Converts pointer to Device to pointer to Ntfs.

Returns
Pointer to Ntfs.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_ntfs() [2/2]

Ntfs * storage::to_ntfs ( Device * device)

Converts pointer to Device to pointer to Ntfs.

Returns
Pointer to Ntfs.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_partition() [1/2]

const Partition * storage::to_partition ( const Device * device)

Converts pointer to Device to pointer to Partition.

Returns
Pointer to Partition.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_partition() [2/2]

Partition * storage::to_partition ( Device * device)

Converts pointer to Device to pointer to Partition.

Returns
Pointer to Partition.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_partition_table() [1/2]

const PartitionTable * storage::to_partition_table ( const Device * device)

Converts pointer to Device to pointer to PartitionTable.

Returns
Pointer to PartitionTable.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_partition_table() [2/2]

PartitionTable * storage::to_partition_table ( Device * device)

Converts pointer to Device to pointer to PartitionTable.

Returns
Pointer to PartitionTable.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_partitionable() [1/2]

const Partitionable * storage::to_partitionable ( const Device * device)

Converts pointer to Device to pointer to Partitionable.

Returns
Pointer to Partitionable.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_partitionable() [2/2]

Partitionable * storage::to_partitionable ( Device * device)

Converts pointer to Device to pointer to Partitionable.

Returns
Pointer to Partitionable.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_plain_encryption() [1/2]

const PlainEncryption * storage::to_plain_encryption ( const Device * device)

Converts pointer to Device to pointer to PlainEncryption.

Returns
Pointer to PlainEncryption.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_plain_encryption() [2/2]

PlainEncryption * storage::to_plain_encryption ( Device * device)

Converts pointer to Device to pointer to PlainEncryption.

Returns
Pointer to PlainEncryption.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_reiserfs() [1/2]

const Reiserfs * storage::to_reiserfs ( const Device * device)

Converts pointer to Device to pointer to Reiserfs.

Returns
Pointer to Reiserfs.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_reiserfs() [2/2]

Reiserfs * storage::to_reiserfs ( Device * device)

Converts pointer to Device to pointer to Reiserfs.

Returns
Pointer to Reiserfs.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_snapshot() [1/2]

const Snapshot * storage::to_snapshot ( const Holder * holder)

Converts pointer to Holder to pointer to Snapshot.

Returns
Pointer to Snapshot.
Exceptions
HolderHasWrongType,NullPointerException

◆ to_snapshot() [2/2]

Snapshot * storage::to_snapshot ( Holder * holder)

Converts pointer to Holder to pointer to Snapshot.

Returns
Pointer to Snapshot.
Exceptions
HolderHasWrongType,NullPointerException

◆ to_stray_blk_device() [1/2]

const StrayBlkDevice * storage::to_stray_blk_device ( const Device * device)

Converts pointer to Device to pointer to StrayBlkDevice.

Returns
Pointer to StrayBlkDevice.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_stray_blk_device() [2/2]

StrayBlkDevice * storage::to_stray_blk_device ( Device * device)

Converts pointer to Device to pointer to StrayBlkDevice.

Returns
Pointer to StrayBlkDevice.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_subdevice() [1/2]

const Subdevice * storage::to_subdevice ( const Holder * holder)

Converts pointer to Holder to pointer to User.

Returns
Pointer to User.
Exceptions
HolderHasWrongType,NullPointerException

◆ to_subdevice() [2/2]

Subdevice * storage::to_subdevice ( Holder * holder)

Converts pointer to Holder to pointer to Subdevice.

Returns
Pointer to Subdevice.
Exceptions
HolderHasWrongType,NullPointerException

◆ to_swap() [1/2]

const Swap * storage::to_swap ( const Device * device)

Converts pointer to Device to pointer to Swap.

Returns
Pointer to Swap.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_swap() [2/2]

Swap * storage::to_swap ( Device * device)

Converts pointer to Device to pointer to Swap.

Returns
Pointer to Swap.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_tmpfs() [1/2]

const Tmpfs * storage::to_tmpfs ( const Device * device)

Converts pointer to Device to pointer to Tmpfs.

Returns
Pointer to Tmpfs.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_tmpfs() [2/2]

Tmpfs * storage::to_tmpfs ( Device * device)

Converts pointer to Device to pointer to Tmpfs.

Returns
Pointer to Tmpfs.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_udf() [1/2]

const Udf * storage::to_udf ( const Device * device)

Converts pointer to Device to pointer to Udf.

Returns
Pointer to Udf.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_udf() [2/2]

Udf * storage::to_udf ( Device * device)

Converts pointer to Device to pointer to Udf.

Returns
Pointer to Udf.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_user() [1/2]

const User * storage::to_user ( const Holder * holder)

Converts pointer to Holder to pointer to User.

Returns
Pointer to User.
Exceptions
HolderHasWrongType,NullPointerException

◆ to_user() [2/2]

User * storage::to_user ( Holder * holder)

Converts pointer to Holder to pointer to User.

Returns
Pointer to User.
Exceptions
HolderHasWrongType,NullPointerException

◆ to_vfat() [1/2]

const Vfat * storage::to_vfat ( const Device * device)

Converts pointer to Device to pointer to Vfat.

Returns
Pointer to Vfat.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_vfat() [2/2]

Vfat * storage::to_vfat ( Device * device)

Converts pointer to Device to pointer to Vfat.

Returns
Pointer to Vfat.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_xfs() [1/2]

const Xfs * storage::to_xfs ( const Device * device)

Converts pointer to Device to pointer to Xfs.

Returns
Pointer to Xfs.
Exceptions
DeviceHasWrongType,NullPointerException

◆ to_xfs() [2/2]

Xfs * storage::to_xfs ( Device * device)

Converts pointer to Device to pointer to Xfs.

Returns
Pointer to Xfs.
Exceptions
DeviceHasWrongType,NullPointerException

Variable Documentation

◆ B

const unsigned long long storage::B = 1

Abbreviation for byte.

See also
https://en.wikipedia.org/wiki/Byte

◆ EiB

const unsigned long long storage::EiB = 1024 * PiB

Abbreviation for exbibyte.

See also
https://en.wikipedia.org/wiki/Exbibyte

◆ GiB

const unsigned long long storage::GiB = 1024 * MiB

Abbreviation for gibibyte.

See also
https://en.wikipedia.org/wiki/Gibibyte

◆ KiB

const unsigned long long storage::KiB = 1024 * B

Abbreviation for kibibyte.

See also
https://en.wikipedia.org/wiki/Kibibyte

◆ MiB

const unsigned long long storage::MiB = 1024 * KiB

Abbreviation for mebibyte.

See also
https://en.wikipedia.org/wiki/Mebibyte

◆ PiB

const unsigned long long storage::PiB = 1024 * TiB

Abbreviation for pebibyte.

See also
https://en.wikipedia.org/wiki/Pebibyte

◆ TiB

const unsigned long long storage::TiB = 1024 * GiB

Abbreviation for tebibyte.

See also
https://en.wikipedia.org/wiki/Tebibyte