storage::Dm Class Reference

#include <Dm.h>

Inheritance diagram for storage::Dm:

storage::Volume storage::Device storage::DmPart storage::LvmLv storage::Dmmultipath storage::Dmraid

List of all members.

Public Types

typedef std::map< string,
unsigned long > 
PeMap

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
void setTableName (const string &name)
const string & getTargetName () const
void setTargetName (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 PeMapgetPeMap () const
void setPeMap (const PeMap &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 setUdevData (SystemInfo &systeminfo)
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 string lvmTableToDev (const string &table)
static unsigned dmMajor ()
static string dmDeviceName (unsigned long num)

Protected Member Functions

void init ()
const PeContainerpec () const
virtual const string shortPrintedName () const
unsigned long computeLe (const string &lestr)
void computePe (const SystemCmd &cmd, PeMap &pe)
void accumulatePe (const string &majmin, unsigned long le, PeMap &pe)
void getMapRecursive (unsigned long mi, PeMap &pe)

Static Protected Member Functions

static list< string > extractMajMin (const string &s)

Protected Attributes

string tname
string target
unsigned long long num_le
unsigned stripe
unsigned long long stripe_size
bool inactiv
bool pe_larger
PeMap 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 &)
Dmoperator= (const Dm &)

Friends

std::ostream & operator<< (std::ostream &s, const Dm &p)


Member Typedef Documentation

typedef std::map<string,unsigned long> storage::Dm::PeMap


Constructor & Destructor Documentation

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 
)

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]


Member Function Documentation

void storage::Dm::saveData ( xmlNode *  node  )  const

const string& storage::Dm::getTableName (  )  const [inline]

void storage::Dm::setTableName ( const string &  name  )  [inline]

const string& storage::Dm::getTargetName (  )  const [inline]

void storage::Dm::setTargetName ( const string &  name  )  [inline]

References target.

Referenced by storage::LvmVg::createThin().

bool storage::Dm::inactive (  )  const [inline]

References inactiv.

Referenced by storage::LvmVg::addLv().

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 (  ) 

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 PeMap& storage::Dm::getPeMap (  )  const [inline]

void storage::Dm::setPeMap ( const PeMap m  ) 

unsigned long long storage::Dm::usingPe ( const string &  dev  )  const

References pe_map.

bool storage::Dm::mapsTo ( const string &  dev  )  const

void storage::Dm::getTableInfo (  ) 

bool storage::Dm::checkConsistency (  )  const [virtual]

unsigned storage::Dm::stripes (  )  const [inline]

unsigned storage::Dm::setStripes ( unsigned long  val  )  [inline]

References stripe.

Referenced by storage::LvmVg::changeStripe().

unsigned long long storage::Dm::stripeSize (  )  const [inline]

References stripe_size.

void storage::Dm::setStripeSize ( unsigned long long  val  )  [inline]

References stripe_size.

Referenced by storage::LvmVg::changeStripeSize().

virtual string storage::Dm::procName (  )  const [inline, virtual]

Reimplemented from storage::Device.

References storage::decString(), and storage::Device::mnr.

Referenced by setUdevData(), and sysfsPath().

string storage::Dm::sysfsPath (  )  const [virtual]

Reimplemented from storage::Device.

References procName(), and SYSFSDIR.

void storage::Dm::setUdevData ( SystemInfo systeminfo  ) 

void storage::Dm::updateMajorMinor (  ) 

virtual void storage::Dm::print ( std::ostream &  s  )  const [inline, virtual]

Text storage::Dm::removeText ( bool  doing  )  const [virtual]

Text storage::Dm::formatText ( bool  doing  )  const [virtual]

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]

static bool storage::Dm::isDeleted ( const Dm l  )  [inline, static]

void storage::Dm::activate ( bool  val  )  [static]

static bool storage::Dm::isActive (  )  [inline, static]

References active.

string storage::Dm::devToTable ( const string &  dev  )  [static]

string storage::Dm::lvmTableToDev ( const string &  table  )  [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

void storage::Dm::logDifference ( std::ostream &  log,
const Dm rhs 
) const

unsigned storage::Dm::dmMajor (  )  [static]

string storage::Dm::dmDeviceName ( unsigned long  num  )  [static]

void storage::Dm::init (  )  [protected]

const PeContainer * storage::Dm::pec (  )  const [protected]

virtual const string storage::Dm::shortPrintedName (  )  const [inline, protected, virtual]

unsigned long storage::Dm::computeLe ( const string &  lestr  )  [protected]

References pec(), storage::PeContainer::peSize(), and y2mil.

Referenced by computePe().

void storage::Dm::computePe ( const SystemCmd cmd,
PeMap pe 
) [protected]

void storage::Dm::accumulatePe ( const string &  majmin,
unsigned long  le,
PeMap pe 
) [protected]

void storage::Dm::getMapRecursive ( unsigned long  mi,
PeMap pe 
) [protected]

list< string > storage::Dm::extractMajMin ( const string &  s  )  [static, protected]

Dm& storage::Dm::operator= ( const Dm  )  [private]


Friends And Related Function Documentation

std::ostream& operator<< ( std::ostream &  s,
const Dm p 
) [friend]


Member Data Documentation

string storage::Dm::tname [protected]

string storage::Dm::target [protected]

unsigned long long storage::Dm::num_le [protected]

unsigned storage::Dm::stripe [protected]

unsigned long long storage::Dm::stripe_size [protected]

bool storage::Dm::inactiv [protected]

bool storage::Dm::pe_larger [protected]

Referenced by checkConsistency(), computePe(), and init().

bool storage::Dm::active = false [static, protected]

Referenced by activate(), and isActive().

unsigned storage::Dm::dm_major = 0 [static, protected]

const list< string > storage::Dm::known_types [static, protected]

Referenced by computePe().

storage::DmInfo storage::Dm::info [mutable, protected]

Reimplemented from storage::Volume.

Reimplemented in storage::DmPart, and storage::LvmLv.

Referenced by getInfo().


The documentation for this class was generated from the following files:

Generated on Mon Jun 15 08:15:59 2015 for yast2-storage by  doxygen 1.5.6