#include <Dm.h>

Public Member Functions | |
| Dm (const PeContainer &c, const string &name, const string &device, const string &tname) | |
| Dm (const PeContainer &c, const string &name, const string &device, const string &tname, SystemInfo &systeminfo) | |
| Dm (const PeContainer &c, const xmlNode *node) | |
| Dm (const PeContainer &c, const Dm &v) | |
| virtual | ~Dm () |
| void | saveData (xmlNode *node) const |
| const string & | getTableName () const |
| const string & | getTargetName () const |
| void | setTableName (const string &name) |
| bool | inactive () const |
| unsigned long long | getLe () const |
| void | setLe (unsigned long long le) |
| void | modifyPeSize (unsigned long long old, unsigned long long neww) |
| bool | removeTable () |
| virtual void | calcSize () |
| const std::map< string, unsigned long > & | getPeMap () const |
| void | setPeMap (const std::map< string, unsigned long > &m) |
| unsigned long long | usingPe (const string &dev) const |
| bool | mapsTo (const string &dev) const |
| void | getTableInfo () |
| virtual bool | checkConsistency () const |
| unsigned | stripes () const |
| unsigned | setStripes (unsigned long val) |
| unsigned long long | stripeSize () const |
| void | setStripeSize (unsigned long long val) |
| virtual string | procName () const |
| virtual string | sysfsPath () const |
| void | updateMajorMinor () |
| virtual void | print (std::ostream &s) const |
| virtual Text | removeText (bool doing) const |
| virtual Text | formatText (bool doing) const |
| void | getInfo (storage::DmInfo &info) const |
| void | changeDeviceName (const string &old, const string &nw) |
| virtual list< string > | getUsing () const |
| bool | equalContent (const Dm &rhs) const |
| void | logDifference (std::ostream &log, const Dm &rhs) const |
Static Public Member Functions | |
| static bool | notDeleted (const Dm &l) |
| static bool | isDeleted (const Dm &l) |
| static void | activate (bool val) |
| static bool | isActive () |
| static string | devToTable (const string &dev) |
| static unsigned | dmMajor () |
| static string | dmDeviceName (unsigned long num) |
Protected Member Functions | |
| void | init () |
| const PeContainer * | pec () const |
| virtual const string | shortPrintedName () const |
Protected Attributes | |
| string | tname |
| string | target |
| unsigned long long | num_le |
| unsigned | stripe |
| unsigned long long | stripe_size |
| bool | inactiv |
| std::map< string, unsigned long > | pe_map |
| storage::DmInfo | info |
Static Protected Attributes | |
| static bool | active = false |
| static unsigned | dm_major = 0 |
| static const list< string > | known_types |
Private Member Functions | |
| Dm (const Dm &) | |
| Dm & | operator= (const Dm &) |
Friends | |
| std::ostream & | operator<< (std::ostream &s, const Dm &p) |
| storage::Dm::Dm | ( | const PeContainer & | c, | |
| const string & | name, | |||
| const string & | device, | |||
| const string & | tname | |||
| ) |
References y2mil.
| storage::Dm::Dm | ( | const PeContainer & | c, | |
| const string & | name, | |||
| const string & | device, | |||
| const string & | tname, | |||
| SystemInfo & | systeminfo | |||
| ) |
| storage::Dm::Dm | ( | const PeContainer & | c, | |
| const xmlNode * | node | |||
| ) |
References storage::Device::dev, storage::getChildValue(), stripe, stripe_size, tname, and y2deb.
| storage::Dm::Dm | ( | const PeContainer & | c, | |
| const Dm & | v | |||
| ) |
References storage::Device::dev, and y2deb.
| storage::Dm::~Dm | ( | ) | [virtual] |
References storage::Device::dev, and y2deb.
| storage::Dm::Dm | ( | const Dm & | ) | [private] |
| void storage::Dm::saveData | ( | xmlNode * | node | ) | const |
Reimplemented from storage::Volume.
Reimplemented in storage::LvmLv.
References storage::Volume::saveData(), storage::setChildValue(), stripe, stripe_size, and tname.
Referenced by storage::LvmLv::saveData().
| const string& storage::Dm::getTableName | ( | ) | const [inline] |
Referenced by storage::LvmLv::LvmLv().
| const string& storage::Dm::getTargetName | ( | ) | const [inline] |
| void storage::Dm::setTableName | ( | const string & | name | ) | [inline] |
| bool storage::Dm::inactive | ( | ) | const [inline] |
| unsigned long long storage::Dm::getLe | ( | ) | const [inline] |
| void storage::Dm::setLe | ( | unsigned long long | le | ) |
| void storage::Dm::modifyPeSize | ( | unsigned long long | old, | |
| unsigned long long | neww | |||
| ) |
References calcSize(), num_le, and pe_map.
| bool storage::Dm::removeTable | ( | ) |
References storage::Volume::getStorage(), storage::Storage::removeDmTable(), and tname.
Referenced by storage::Storage::removeDmMapsTo().
| void storage::Dm::calcSize | ( | ) | [virtual] |
Reimplemented in storage::LvmLv.
References num_le, pec(), and storage::Volume::setSize().
Referenced by storage::LvmLv::calcSize(), and modifyPeSize().
| const std::map<string,unsigned long>& storage::Dm::getPeMap | ( | ) | const [inline] |
References pe_map.
Referenced by storage::DmCo::getDmData(), storage::LvmVg::resizeVolume(), and storage::Storage::updateDmEmptyPeMap().
| void storage::Dm::setPeMap | ( | const std::map< string, unsigned long > & | m | ) |
References storage::Device::device(), pe_map, and y2mil.
Referenced by storage::LvmVg::createLv(), storage::LvmVg::createLvSnapshot(), and storage::LvmVg::resizeVolume().
| unsigned long long storage::Dm::usingPe | ( | const string & | dev | ) | const |
References pe_map.
| bool storage::Dm::mapsTo | ( | const string & | dev | ) | const |
References storage::PeContainer::addedPv(), storage::Regex::match(), pe_map, pec(), tname, and y2mil.
Referenced by storage::Storage::checkDmMapsTo(), and storage::Storage::removeDmMapsTo().
| void storage::Dm::getTableInfo | ( | ) |
References storage::Device::dev, DMSETUPBIN, storage::extractNthWord(), storage::PeContainer::getDeviceByNumber(), storage::SystemCmd::getLine(), inactiv, known_types, storage::Regex::match(), storage::SystemCmd::numLines(), pe_map, pec(), storage::PeContainer::peSize(), storage::quote(), storage::SystemCmd::retcode(), storage::splitString(), str, stripe, stripe_size, target, tname, y2mil, and y2war.
Referenced by Dm(), storage::DmPart::DmPart(), storage::LvmLv::LvmLv(), storage::Storage::updateDmEmptyPeMap(), and storage::DmPart::updateMinor().
| bool storage::Dm::checkConsistency | ( | ) | const [virtual] |
References storage::Device::dev, num_le, pe_map, and y2war.
| unsigned storage::Dm::stripes | ( | ) | const [inline] |
| unsigned storage::Dm::setStripes | ( | unsigned long | val | ) | [inline] |
References stripe.
| unsigned long long storage::Dm::stripeSize | ( | ) | const [inline] |
References stripe_size.
| void storage::Dm::setStripeSize | ( | unsigned long long | val | ) | [inline] |
References stripe_size.
| virtual string storage::Dm::procName | ( | ) | const [inline, virtual] |
Reimplemented from storage::Device.
References storage::decString(), and storage::Device::mnr.
Referenced by sysfsPath().
| string storage::Dm::sysfsPath | ( | ) | const [virtual] |
| void storage::Dm::updateMajorMinor | ( | ) |
References storage::decString(), storage::Device::dev, dmMajor(), storage::Device::getMajorMinor(), storage::Device::majorNr(), storage::Device::minorNr(), storage::Device::mnr, storage::Volume::num, and storage::Volume::replaceAltName().
Referenced by Dm(), init(), and storage::Storage::updateDmEmptyPeMap().
| virtual void storage::Dm::print | ( | std::ostream & | s | ) | const [inline, virtual] |
Reimplemented from storage::Volume.
Reimplemented in storage::Dmmultipath, storage::DmPart, storage::Dmraid, and storage::LvmLv.
| Text storage::Dm::removeText | ( | bool | doing | ) | const [virtual] |
Reimplemented from storage::Volume.
Reimplemented in storage::Dmmultipath, storage::Dmraid, and storage::LvmLv.
References storage::_(), storage::Device::dev, storage::sformat(), and storage::Device::sizeString().
| Text storage::Dm::formatText | ( | bool | doing | ) | const [virtual] |
Reimplemented from storage::Volume.
Reimplemented in storage::Dmmultipath, storage::Dmraid, and storage::LvmLv.
References storage::_(), storage::Device::dev, storage::ENC_NONE, storage::Volume::encryption, storage::Volume::fsTypeString(), storage::Volume::mp, storage::sformat(), and storage::Device::sizeString().
| void storage::Dm::getInfo | ( | storage::DmInfo & | info | ) | const |
| void storage::Dm::changeDeviceName | ( | const string & | old, | |
| const string & | nw | |||
| ) |
References pe_map.
| static bool storage::Dm::notDeleted | ( | const Dm & | l | ) | [inline, static] |
References storage::Device::deleted().
Referenced by storage::PeContainer::checkConsistency(), storage::DmCo::findDm(), storage::Storage::getDmInfo(), and storage::PeContainer::tryUnusePe().
| static bool storage::Dm::isDeleted | ( | const Dm & | l | ) | [inline, static] |
| void storage::Dm::activate | ( | bool | val | ) | [static] |
References active, DMSETUPBIN, storage::SystemCmd::execute(), storage::extractNthWord(), storage::SystemCmd::getLine(), MODPROBEBIN, storage::SystemCmd::numLines(), storage::SystemCmd::retcode(), and y2mil.
Referenced by storage::LvmVg::activate(), storage::DmraidCo::activate(), storage::DmmultipathCo::activate(), storage::Storage::activateHld(), and storage::Storage::rescanEverything().
| static bool storage::Dm::isActive | ( | ) | [inline, static] |
References active.
| string storage::Dm::devToTable | ( | const string & | dev | ) | [static] |
| list< string > storage::Dm::getUsing | ( | ) | const [virtual] |
Reimplemented from storage::Device.
Reimplemented in storage::DmPart, and storage::LvmLv.
References pe_map.
| bool storage::Dm::equalContent | ( | const Dm & | rhs | ) | const |
References storage::Volume::equalContent(), inactiv, num_le, pe_map, stripe, and stripe_size.
Referenced by storage::LvmLv::equalContent(), and storage::DmPart::equalContent().
| void storage::Dm::logDifference | ( | std::ostream & | log, | |
| const Dm & | rhs | |||
| ) | const |
References storage::logDiff(), storage::Volume::logDifference(), num_le, pe_map, stripe, and stripe_size.
Referenced by storage::LvmLv::logDifference(), and storage::DmPart::logDifference().
| unsigned storage::Dm::dmMajor | ( | ) | [static] |
References dm_major, storage::getMajorDevices(), and y2mil.
Referenced by storage::LvmVg::normalizeDmDevices(), and updateMajorMinor().
| string storage::Dm::dmDeviceName | ( | unsigned long | num | ) | [static] |
References storage::decString().
Referenced by storage::Volume::doCryptsetup(), and storage::Storage::setDmcryptData().
| void storage::Dm::init | ( | ) | [protected] |
Reimplemented from storage::Volume.
References storage::Device::alt_names, storage::Device::dev, storage::Volume::getStorage(), tname, and updateMajorMinor().
Referenced by storage::DmPart::DmPart(), and storage::LvmLv::LvmLv().
| const PeContainer * storage::Dm::pec | ( | ) | const [protected] |
References storage::Volume::cont.
Referenced by calcSize(), storage::LvmLv::getInfo(), getTableInfo(), and mapsTo().
| virtual const string storage::Dm::shortPrintedName | ( | ) | const [inline, protected, virtual] |
Reimplemented in storage::Dmmultipath, storage::DmPart, storage::Dmraid, and storage::LvmLv.
Referenced by storage::operator<<().
| std::ostream& operator<< | ( | std::ostream & | s, | |
| const Dm & | p | |||
| ) | [friend] |
string storage::Dm::tname [protected] |
Referenced by Dm(), storage::LvmLv::getInfo(), storage::DmPart::getInfo(), getInfo(), getTableInfo(), init(), mapsTo(), storage::operator<<(), removeTable(), and saveData().
string storage::Dm::target [protected] |
Referenced by storage::LvmLv::getInfo(), storage::DmPart::getInfo(), getInfo(), getTableInfo(), getTargetName(), and storage::operator<<().
unsigned long long storage::Dm::num_le [protected] |
Referenced by calcSize(), checkConsistency(), equalContent(), storage::LvmLv::getInfo(), getLe(), logDifference(), modifyPeSize(), storage::operator<<(), and setLe().
unsigned storage::Dm::stripe [protected] |
Referenced by Dm(), equalContent(), storage::LvmLv::getInfo(), getTableInfo(), logDifference(), storage::LvmLv::LvmLv(), storage::operator<<(), saveData(), setStripes(), and stripes().
unsigned long long storage::Dm::stripe_size [protected] |
Referenced by Dm(), equalContent(), storage::LvmLv::getInfo(), getTableInfo(), logDifference(), storage::operator<<(), saveData(), setStripeSize(), and stripeSize().
bool storage::Dm::inactiv [protected] |
Referenced by equalContent(), getTableInfo(), inactive(), and storage::operator<<().
std::map<string,unsigned long> storage::Dm::pe_map [protected] |
Referenced by changeDeviceName(), checkConsistency(), equalContent(), getPeMap(), getTableInfo(), getUsing(), logDifference(), mapsTo(), modifyPeSize(), storage::operator<<(), setPeMap(), and usingPe().
bool storage::Dm::active = false [static, protected] |
Referenced by activate(), and isActive().
unsigned storage::Dm::dm_major = 0 [static, protected] |
Referenced by dmMajor().
const list< string > storage::Dm::known_types [static, protected] |
Referenced by getTableInfo().
storage::DmInfo storage::Dm::info [mutable, protected] |
Reimplemented from storage::Volume.
Reimplemented in storage::DmPart, and storage::LvmLv.
Referenced by getInfo().
1.5.6