storage::LvmVg Class Reference

#include <LvmVg.h>

Inheritance diagram for storage::LvmVg:

storage::PeContainer storage::Container

List of all members.

Public Member Functions

 LvmVg (Storage *const s, const string &Name)
 LvmVg (Storage *const s, const string &Name, bool lvm1)
 LvmVg (const LvmVg &c)
virtual ~LvmVg ()
unsigned numLv () const
bool lvm2 () const
bool inactive () const
int removeVg ()
int extendVg (const std::list< string > &dl)
int extendVg (const string &device)
int reduceVg (const std::list< string > &dl)
int reduceVg (const string &device)
int createLv (const string &name, unsigned long long sizeK, unsigned stripe, string &device)
int removeLv (const string &name)
int changeStripe (const string &name, unsigned long stripe)
int changeStripeSize (const string &name, unsigned long long stripeSize)
int setPeSize (long long unsigned peSizeK)
void normalizeDmDevices ()
void getCommitActions (std::list< storage::commitAction * > &l) const
int commitChanges (storage::CommitStage stage)
int getToCommit (storage::CommitStage stage, std::list< Container * > &col, std::list< Volume * > &vol)
int resizeVolume (Volume *v, unsigned long long newSize)
int removeVolume (Volume *v)
void getInfo (storage::LvmVgInfo &info) const
bool equalContent (const Container &rhs) const
void logDifference (const Container &rhs) const

Static Public Member Functions

static storage::CType staticType ()
static void activate (bool val=true)
static void getVgs (std::list< string > &l)
static bool lvNotDeleted (const LvmLv &l)

Protected Types

typedef CastIterator< VIter,
LvmLv * > 
LvmLvInter
typedef CastIterator< CVIter,
const LvmLv * > 
LvmLvCInter
typedef CheckFnc< const LvmLvCheckFncLvmLv
typedef CheckerIterator
< CheckFncLvmLv, LvmLvPI
< CheckFncLvmLv >::type,
LvmLvInter, LvmLv
LvmLvPIterator
typedef CheckerIterator
< CheckFncLvmLv, LvmLvCPI
< CheckFncLvmLv >::type,
LvmLvCInter, const LvmLv
LvmLvCPIterator
typedef DerefIterator
< LvmLvPIterator, LvmLv
LvmLvIter
typedef DerefIterator
< LvmLvCPIterator, const LvmLv
ConstLvmLvIter
typedef IterPair< LvmLvIterLvmLvPair
typedef IterPair< ConstLvmLvIterConstLvmLvPair

Protected Member Functions

LvmLvPair lvmLvPair (bool(*Check)(const LvmLv &)=NULL)
LvmLvIter lvmLvBegin (bool(*Check)(const LvmLv &)=NULL)
LvmLvIter lvmLvEnd (bool(*Check)(const LvmLv &)=NULL)
ConstLvmLvPair lvmLvPair (bool(*Check)(const LvmLv &)=NULL) const
ConstLvmLvIter lvmLvBegin (bool(*Check)(const LvmLv &)=NULL) const
ConstLvmLvIter lvmLvEnd (bool(*Check)(const LvmLv &)=NULL) const
 LvmVg (Storage *const s, const string &File, int)
void getVgData (const string &name, bool exists=true)
void init ()
virtual void print (std::ostream &s) const
virtual ContainergetCopy () const
string createVgText (bool doing) const
string removeVgText (bool doing) const
string extendVgText (bool doing, const string &dev) const
string reduceVgText (bool doing, const string &dev) const
int doCreateVg ()
int doRemoveVg ()
int doExtendVg ()
int doReduceVg ()
int doCreate (Volume *v)
int doRemove (Volume *v)
int doResize (Volume *v)
int doCreatePv (const string &device)
string metaString ()
string instSysString ()
void logData (const string &Dir)
void addLv (unsigned long &le, string &name, string &uuid, string &status, string &alloc, bool &ro)
void addPv (Pv *&p)

Protected Attributes

string status
string uuid
bool lvm1
bool inactiv
unsigned num_lv
storage::LvmVgInfo info

Static Protected Attributes

static bool active = false

Friends

class Storage
std::ostream & operator<< (std::ostream &, const LvmVg &)

Classes

struct  LvmLvCPI
struct  LvmLvPI


Member Typedef Documentation

typedef CastIterator<CVIter, const LvmLv *> storage::LvmVg::LvmLvCInter [protected]

typedef CheckFnc<const LvmLv> storage::LvmVg::CheckFncLvmLv [protected]


Constructor & Destructor Documentation

LvmVg::LvmVg ( Storage *const   s,
const string &  Name 
)

LvmVg::LvmVg ( Storage *const   s,
const string &  Name,
bool  lvm1 
)

LvmVg::LvmVg ( const LvmVg c  ) 

LvmVg::~LvmVg (  )  [virtual]

References storage::Container::dev, and y2debug.

LvmVg::LvmVg ( Storage *const   s,
const string &  File,
int   
) [protected]

References storage::Container::dev, and y2debug.


Member Function Documentation

unsigned storage::LvmVg::numLv (  )  const [inline]

bool storage::LvmVg::lvm2 (  )  const [inline]

References lvm1.

Referenced by doRemove(), and getInfo().

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

References inactiv.

Referenced by storage::Storage::detectLvmVgs().

static storage::CType storage::LvmVg::staticType (  )  [inline, static]

Reimplemented from storage::Container.

References storage::LVM.

int LvmVg::removeVg (  ) 

int storage::LvmVg::extendVg ( const std::list< string > &  dl  ) 

int LvmVg::extendVg ( const string &  device  ) 

References extendVg().

int storage::LvmVg::reduceVg ( const std::list< string > &  dl  ) 

Referenced by reduceVg().

int LvmVg::reduceVg ( const string &  device  ) 

References reduceVg().

int LvmVg::createLv ( const string &  name,
unsigned long long  sizeK,
unsigned  stripe,
string &  device 
)

int LvmVg::removeLv ( const string &  name  ) 

int LvmVg::changeStripe ( const string &  name,
unsigned long  stripe 
)

int LvmVg::changeStripeSize ( const string &  name,
unsigned long long  stripeSize 
)

int LvmVg::setPeSize ( long long unsigned  peSizeK  ) 

void LvmVg::normalizeDmDevices (  ) 

void storage::LvmVg::getCommitActions ( std::list< storage::commitAction * > &  l  )  const [virtual]

Reimplemented from storage::Container.

int LvmVg::commitChanges ( storage::CommitStage  stage  )  [virtual]

int storage::LvmVg::getToCommit ( storage::CommitStage  stage,
std::list< Container * > &  col,
std::list< Volume * > &  vol 
) [virtual]

Reimplemented from storage::Container.

int LvmVg::resizeVolume ( Volume v,
unsigned long long  newSize 
) [virtual]

int LvmVg::removeVolume ( Volume v  )  [virtual]

Reimplemented from storage::Container.

References storage::Volume::name(), and removeLv().

void LvmVg::getInfo ( storage::LvmVgInfo info  )  const

bool LvmVg::equalContent ( const Container rhs  )  const [virtual]

void LvmVg::logDifference ( const Container rhs  )  const [virtual]

void LvmVg::activate ( bool  val = true  )  [static]

static void storage::LvmVg::getVgs ( std::list< string > &  l  )  [static]

static bool storage::LvmVg::lvNotDeleted ( const LvmLv l  )  [inline, static]

LvmLvPair storage::LvmVg::lvmLvPair ( bool(*)(const LvmLv &)  Check = NULL  )  [inline, protected]

LvmLvIter storage::LvmVg::lvmLvBegin ( bool(*)(const LvmLv &)  Check = NULL  )  [inline, protected]

LvmLvIter storage::LvmVg::lvmLvEnd ( bool(*)(const LvmLv &)  Check = NULL  )  [inline, protected]

ConstLvmLvPair storage::LvmVg::lvmLvPair ( bool(*)(const LvmLv &)  Check = NULL  )  const [inline, protected]

References lvmLvBegin(), and lvmLvEnd().

ConstLvmLvIter storage::LvmVg::lvmLvBegin ( bool(*)(const LvmLv &)  Check = NULL  )  const [inline, protected]

ConstLvmLvIter storage::LvmVg::lvmLvEnd ( bool(*)(const LvmLv &)  Check = NULL  )  const [inline, protected]

void LvmVg::getVgData ( const string &  name,
bool  exists = true 
) [protected]

void LvmVg::init (  )  [protected]

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

Reimplemented from storage::PeContainer.

virtual Container* storage::LvmVg::getCopy (  )  const [inline, protected, virtual]

Reimplemented from storage::PeContainer.

References LvmVg().

string LvmVg::createVgText ( bool  doing  )  const [protected]

string LvmVg::removeVgText ( bool  doing  )  const [protected]

string LvmVg::extendVgText ( bool  doing,
const string &  dev 
) const [protected]

string LvmVg::reduceVgText ( bool  doing,
const string &  dev 
) const [protected]

int LvmVg::doCreateVg (  )  [protected]

int LvmVg::doRemoveVg (  )  [protected]

int LvmVg::doExtendVg (  )  [protected]

int LvmVg::doReduceVg (  )  [protected]

int LvmVg::doCreate ( Volume v  )  [protected, virtual]

int LvmVg::doRemove ( Volume v  )  [protected, virtual]

int LvmVg::doResize ( Volume v  )  [protected, virtual]

int LvmVg::doCreatePv ( const string &  device  )  [protected]

string LvmVg::metaString (  )  [protected]

References lvm1.

Referenced by doCreatePv(), and doCreateVg().

string LvmVg::instSysString (  )  [protected]

void LvmVg::logData ( const string &  Dir  )  [protected, virtual]

Reimplemented from storage::Container.

void LvmVg::addLv ( unsigned long &  le,
string &  name,
string &  uuid,
string &  status,
string &  alloc,
bool &  ro 
) [protected]

void LvmVg::addPv ( Pv *&  p  )  [protected]


Friends And Related Function Documentation

friend class Storage [friend]

Reimplemented from storage::PeContainer.

std::ostream& operator<< ( std::ostream &  s,
const LvmVg d 
) [friend]


Member Data Documentation

string storage::LvmVg::status [protected]

string storage::LvmVg::uuid [protected]

bool storage::LvmVg::lvm1 [protected]

bool storage::LvmVg::inactiv [protected]

unsigned storage::LvmVg::num_lv [protected]

bool LvmVg::active = false [static, protected]

Reimplemented from storage::Container.

Referenced by getInfo().


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

Generated on Sun Jun 8 10:48:04 2008 for yast2-storage by  doxygen 1.5.5