zypp::zypp_detail::ZYppImpl Class Reference

#include <ZYppImpl.h>

List of all members.

Public Types

typedef std::set
< Locale
LocaleSet

Public Member Functions

 ZYppImpl ()
 Default ctor.
 ~ZYppImpl ()
 Dtor.
ResPool pool () const
ResPoolProxy poolProxy () const
KeyRing_Ptr keyRing () const
Resolver_Ptr resolver () const
void addResolvables (const ResStore &store, bool installed=false)
void removeResolvables (const ResStore &store)
Target_Ptr target () const
void initializeTarget (const Pathname &root)
 
Exceptions:
Exception true, just init the target, dont populate store or pool

ZYPP_DEPRECATED void initTarget (const Pathname &root, bool commit_only)
 
Exceptions:
Exception if commit_only == true, just init the target, dont populate store or pool

void finishTarget ()
 
Exceptions:
Exception 

ZYppCommitResult commit (const ZYppCommitPolicy &policy_r)
 Commit changes and transactions.
void installSrcPackage (const SrcPackage_constPtr &srcPackage_r)
 Install a source package on the Target.
void setTextLocale (const Locale &textLocale_r)
Locale getTextLocale () const
void setRequestedLocales (const LocaleSet &locales_r)
LocaleSet getRequestedLocales () const
LocaleSet getAvailableLocales () const
void availableLocale (const Locale &locale_r)
 internal use
Arch architecture () const
 Get the system architecture.
void setArchitecture (const Arch &arch)
 Set the system architecture.
Pathname homePath () const
 Get the path where zypp related plugins store persistent data and caches.
Pathname tmpPath () const
 Get the path where zypp related plugins store tmp data.
void setHomePath (const Pathname &path)
 set the home, if you need to change it
DiskUsageCounter::MountPointSet diskUsage ()
void setPartitions (const DiskUsageCounter::MountPointSet &mp)
DiskUsageCounter::MountPointSet getPartitions () const
int applyLocks ()

Private Member Functions

void removeInstalledResolvables ()

Private Attributes

Locale _textLocale
ResPoolManager _pool
Target_Ptr _target
Resolver_Ptr _resolver
KeyRing_Ptr _keyring
Arch _architecture
Pathname _home_path
shared_ptr
< DiskUsageCounter
_disk_usage
 defined mount points, used for disk usage counting

Friends

std::ostream & operator<< (std::ostream &str, const ZYppImpl &obj)
 Stream output.


Detailed Description

Definition at line 41 of file ZYppImpl.h.


Member Typedef Documentation

typedef std::set<Locale> zypp::zypp_detail::ZYppImpl::LocaleSet

Definition at line 115 of file ZYppImpl.h.


Constructor & Destructor Documentation

zypp::zypp_detail::ZYppImpl::ZYppImpl (  ) 

Default ctor.

Definition at line 130 of file ZYppImpl.cc.

References _architecture, _keyring, _textLocale, MIL, and tmpPath().

zypp::zypp_detail::ZYppImpl::~ZYppImpl (  ) 

Dtor.

Definition at line 151 of file ZYppImpl.cc.


Member Function Documentation

void zypp::zypp_detail::ZYppImpl::removeInstalledResolvables (  )  [private]

Definition at line 170 of file ZYppImpl.cc.

References _pool, zypp::ResPool::end(), zypp::ResPoolManager::erase(), and pool().

Referenced by commit(), finishTarget(), initializeTarget(), and initTarget().

ResPool zypp::zypp_detail::ZYppImpl::pool ( void   )  const [inline]

Definition at line 56 of file ZYppImpl.h.

References _pool, and zypp::ResPoolManager::accessor().

Referenced by applyLocks(), commit(), diskUsage(), getAvailableLocales(), getRequestedLocales(), removeInstalledResolvables(), and setRequestedLocales().

ResPoolProxy zypp::zypp_detail::ZYppImpl::poolProxy (  )  const [inline]

Definition at line 59 of file ZYppImpl.h.

References _pool, and zypp::ResPoolManager::proxy().

KeyRing_Ptr zypp::zypp_detail::ZYppImpl::keyRing (  )  const [inline]

Definition at line 63 of file ZYppImpl.h.

References _keyring.

Resolver_Ptr zypp::zypp_detail::ZYppImpl::resolver (  )  const [inline]

Definition at line 67 of file ZYppImpl.h.

References _resolver.

void zypp::zypp_detail::ZYppImpl::addResolvables ( const ResStore store,
bool  installed = false 
)

Definition at line 157 of file ZYppImpl.cc.

References _pool, zypp::ResStore::begin(), zypp::ResStore::end(), and zypp::ResPoolManager::insert().

Referenced by commit(), and initTarget().

void zypp::zypp_detail::ZYppImpl::removeResolvables ( const ResStore store  ) 

Definition at line 162 of file ZYppImpl.cc.

References _pool, zypp::ResStore::begin(), zypp::ResStore::end(), and zypp::ResPoolManager::erase().

Target_Ptr zypp::zypp_detail::ZYppImpl::target (  )  const

Todo:
Signal locale change.
Exceptions:
Exception 

Definition at line 207 of file ZYppImpl.cc.

References _target, and ZYPP_THROW.

Referenced by applyLocks().

void zypp::zypp_detail::ZYppImpl::initializeTarget ( const Pathname &  root  ) 

Exceptions:
Exception true, just init the target, dont populate store or pool

Definition at line 214 of file ZYppImpl.cc.

References _target, MIL, and removeInstalledResolvables().

void zypp::zypp_detail::ZYppImpl::initTarget ( const Pathname &  root,
bool  commit_only 
)

Exceptions:
Exception if commit_only == true, just init the target, dont populate store or pool

Definition at line 228 of file ZYppImpl.cc.

References _target, addResolvables(), MIL, and removeInstalledResolvables().

void zypp::zypp_detail::ZYppImpl::finishTarget (  ) 

Exceptions:
Exception 

Definition at line 247 of file ZYppImpl.cc.

References _target, and removeInstalledResolvables().

ZYppCommitResult zypp::zypp_detail::ZYppImpl::commit ( const ZYppCommitPolicy policy_r  ) 

Commit changes and transactions.

Todo:
Remove workflow from target, lot's of it could be done here, and target used for transact.

Definition at line 259 of file ZYppImpl.cc.

References _target, addResolvables(), zypp::ZYppCommitPolicy::dryRun(), MIL, pool(), removeInstalledResolvables(), zypp::ZYppCommitPolicy::syncPoolAfterCommit(), and ZYPP_THROW.

void zypp::zypp_detail::ZYppImpl::installSrcPackage ( const SrcPackage_constPtr &  srcPackage_r  ) 

Install a source package on the Target.

Definition at line 290 of file ZYppImpl.cc.

References _target, and ZYPP_THROW.

void zypp::zypp_detail::ZYppImpl::setTextLocale ( const Locale textLocale_r  )  [inline]

Todo:
Signal locale change.

Definition at line 106 of file ZYppImpl.h.

References _textLocale.

Locale zypp::zypp_detail::ZYppImpl::getTextLocale (  )  const [inline]

Definition at line 109 of file ZYppImpl.h.

References _textLocale.

void zypp::zypp_detail::ZYppImpl::setRequestedLocales ( const LocaleSet locales_r  ) 

Definition at line 301 of file ZYppImpl.cc.

References _pool, zypp::NameKindProxy::availableBegin(), zypp::NameKindProxy::availableEmpty(), zypp::Language::availableInstance(), zypp::ResPool::byKindBegin(), zypp::ResPool::byKindEnd(), zypp::ResPoolManager::insert(), zypp::NameKindProxy::installedBegin(), zypp::NameKindProxy::installedEmpty(), zypp::ResStatus::KEEP_STATE, pool(), zypp::ResStatus::TRANSACT, and zypp::ResStatus::USER.

ZYppImpl::LocaleSet zypp::zypp_detail::ZYppImpl::getRequestedLocales (  )  const

Definition at line 369 of file ZYppImpl.cc.

References zypp::NameKindProxy::availableBegin(), zypp::NameKindProxy::availableEmpty(), zypp::ResPool::byKindBegin(), zypp::ResPool::byKindEnd(), zypp::NameKindProxy::installedBegin(), zypp::NameKindProxy::installedEmpty(), pool(), and zypp::ResStatus::TRANSACT.

ZYppImpl::LocaleSet zypp::zypp_detail::ZYppImpl::getAvailableLocales (  )  const

Definition at line 355 of file ZYppImpl.cc.

References zypp::ResPool::byKindBegin(), zypp::ResPool::byKindEnd(), and pool().

void zypp::zypp_detail::ZYppImpl::availableLocale ( const Locale locale_r  ) 

internal use

Definition at line 387 of file ZYppImpl.cc.

References _pool, zypp::Language::availableInstance(), and zypp::ResPoolManager::insert().

Arch zypp::zypp_detail::ZYppImpl::architecture (  )  const [inline]

Get the system architecture.

Definition at line 128 of file ZYppImpl.h.

References _architecture.

void zypp::zypp_detail::ZYppImpl::setArchitecture ( const Arch arch  ) 

Set the system architecture.

This should be used for testing/debugging only since the Target backend won't be able to install incompatible packages ;-)

Definition at line 395 of file ZYppImpl.cc.

References _architecture, and _resolver.

Pathname zypp::zypp_detail::ZYppImpl::homePath (  )  const

Get the path where zypp related plugins store persistent data and caches.

Definition at line 404 of file ZYppImpl.cc.

References _home_path.

Pathname zypp::zypp_detail::ZYppImpl::tmpPath (  )  const

Get the path where zypp related plugins store tmp data.

Definition at line 410 of file ZYppImpl.cc.

References zypp::filesystem::TmpPath::path().

Referenced by ZYppImpl().

void zypp::zypp_detail::ZYppImpl::setHomePath ( const Pathname &  path  ) 

set the home, if you need to change it

Definition at line 407 of file ZYppImpl.cc.

References _home_path.

DiskUsageCounter::MountPointSet zypp::zypp_detail::ZYppImpl::diskUsage (  ) 

Definition at line 181 of file ZYppImpl.cc.

References _disk_usage, zypp::DiskUsageCounter::detectMountPoints(), pool(), and setPartitions().

void zypp::zypp_detail::ZYppImpl::setPartitions ( const DiskUsageCounter::MountPointSet mp  ) 

Definition at line 190 of file ZYppImpl.cc.

References _disk_usage.

Referenced by diskUsage().

DiskUsageCounter::MountPointSet zypp::zypp_detail::ZYppImpl::getPartitions (  )  const

Definition at line 196 of file ZYppImpl.cc.

References _disk_usage, and zypp::DiskUsageCounter::detectMountPoints().

int zypp::zypp_detail::ZYppImpl::applyLocks (  ) 

Definition at line 416 of file ZYppImpl.cc.

References MIL, pool(), zypp::locks::readLocks(), and target().


Friends And Related Function Documentation

std::ostream & operator<< ( std::ostream &  str,
const ZYppImpl obj 
) [friend]

Stream output.

Definition at line 449 of file ZYppImpl.cc.


Member Data Documentation

Locale zypp::zypp_detail::ZYppImpl::_textLocale [private]

Definition at line 112 of file ZYppImpl.h.

Referenced by getTextLocale(), setTextLocale(), and ZYppImpl().

ResPoolManager zypp::zypp_detail::ZYppImpl::_pool [private]

Definition at line 155 of file ZYppImpl.h.

Referenced by addResolvables(), availableLocale(), pool(), poolProxy(), removeInstalledResolvables(), removeResolvables(), and setRequestedLocales().

Target_Ptr zypp::zypp_detail::ZYppImpl::_target [private]

Definition at line 157 of file ZYppImpl.h.

Referenced by commit(), finishTarget(), initializeTarget(), initTarget(), installSrcPackage(), and target().

Resolver_Ptr zypp::zypp_detail::ZYppImpl::_resolver [private]

Definition at line 159 of file ZYppImpl.h.

Referenced by resolver(), and setArchitecture().

KeyRing_Ptr zypp::zypp_detail::ZYppImpl::_keyring [private]

Definition at line 161 of file ZYppImpl.h.

Referenced by keyRing(), and ZYppImpl().

Arch zypp::zypp_detail::ZYppImpl::_architecture [private]

Definition at line 163 of file ZYppImpl.h.

Referenced by architecture(), setArchitecture(), and ZYppImpl().

Pathname zypp::zypp_detail::ZYppImpl::_home_path [private]

Definition at line 165 of file ZYppImpl.h.

Referenced by homePath(), and setHomePath().

shared_ptr<DiskUsageCounter> zypp::zypp_detail::ZYppImpl::_disk_usage [private]

defined mount points, used for disk usage counting

Definition at line 167 of file ZYppImpl.h.

Referenced by diskUsage(), getPartitions(), and setPartitions().


The documentation for this class was generated from the following files:
Generated on Tue Sep 25 19:23:30 2007 for libzypp by  doxygen 1.5.3