27 #include "storage/Devices/Partitionable.h" 37 UNKNOWN, RAID0, RAID1, RAID5, RAID6, RAID10
41 DEFAULT, LEFT_ASYMMETRIC, LEFT_SYMMETRIC, RIGHT_ASYMMETRIC,
42 RIGHT_SYMMETRIC, FIRST, LAST, LEFT_ASYMMETRIC_6, LEFT_SYMMETRIC_6,
43 RIGHT_ASYMMETRIC_6, RIGHT_SYMMETRIC_6, FIRST_6, NEAR_2, OFFSET_2,
44 FAR_2, NEAR_3, OFFSET_3, FAR_3
48 std::string get_md_level_name(MdLevel md_level);
50 std::string get_md_parity_name(MdParity md_parity);
60 static Md* create(
Devicegraph* devicegraph,
const std::string& name);
61 static Md* load(
Devicegraph* devicegraph,
const xmlNode* node);
64 void remove_device(
BlkDevice* blk_device);
66 std::vector<BlkDevice*> get_devices();
67 std::vector<const BlkDevice*> get_devices()
const;
69 unsigned int get_number()
const;
71 MdLevel get_md_level()
const;
72 void set_md_level(MdLevel md_level);
74 MdParity get_md_parity()
const;
75 void set_md_parity(MdParity md_parity);
77 unsigned long get_chunk_size()
const;
78 void set_chunk_size(
unsigned long chunk_size);
90 static Md* find_by_name(
Devicegraph* devicegraph,
const std::string& name);
91 static const Md* find_by_name(
const Devicegraph* devicegraph,
const std::string& name);
98 const Impl& get_impl()
const;
100 virtual Md* clone()
const override;
109 bool is_md(
const Device* device);
static std::vector< Md * > get_all(Devicegraph *devicegraph)
Sorted by number.
A MD device.
Definition: Md.h:56
The master container of the libstorage.
Definition: Devicegraph.h:133
An abstract Block Device.
Definition: BlkDevice.h:40
An abstract base class of storage devices, and a vertex in the Devicegraph.
Definition: Device.h:73
Definition: Partitionable.h:40
The storage namespace.
Definition: Actiongraph.h:36
Md * to_md(Device *device)
Converts pointer to Device to pointer to Md.