libzypp  11.13.5
zypp::ZYpp Class Reference

#include <ZYpp.h>

Inheritance diagram for zypp::ZYpp:

List of all members.

Public Types

typedef intrusive_ptr< ZYppPtr
typedef intrusive_ptr< const ZYppconstPtr
typedef ZYppCommitResult CommitResult

Public Member Functions

ResPool pool () const
 Access to the global resolvable pool.
ResPoolProxy poolProxy () const
 Pool of ui::Selectable.
DiskUsageCounter::MountPointSet diskUsage ()
void setPartitions (const DiskUsageCounter::MountPointSet &mp)
DiskUsageCounter::MountPointSet getPartitions () const
Target_Ptr target () const
Target_Ptr getTarget () const
 Same as target but returns NULL if target is not initialized, instead of throwing.
void initializeTarget (const Pathname &root, bool doRebuild_r=false)
void finishTarget ()
ZYppCommitResult commit (const ZYppCommitPolicy &policy_r)
 Commit changes and transactions.
void installSrcPackage (const SrcPackage_constPtr &srcPackage_r)
 Install a source package on the Target.
Resolver_Ptr resolver () const
KeyRing_Ptr keyRing () const
ZYPP_DEPRECATED void setTextLocale (const Locale &textLocale_r)
 Set the preferred locale for translated labels, descriptions, etc.
ZYPP_DEPRECATED Locale getTextLocale () const
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 temp data.
void setHomePath (const Pathname &path)
 set the home, if you need to change it
ZYPP_DEPRECATED Arch architecture () const
 Get the system architecture.
ZYPP_DEPRECATED void setArchitecture (const Arch &arch)
 Set the system architecture.
ZYPP_DEPRECATED int applyLocks ()
move to pool
Deprecated:
Use ResPool diretcly.
void setRequestedLocales (const LocaleSet &locales_r) ZYPP_DEPRECATED
 Set the requested locales.
const LocaleSetgetRequestedLocales () const ZYPP_DEPRECATED
const LocaleSetgetAvailableLocales () const ZYPP_DEPRECATED
 Get the set of available locales.
- Public Member Functions inherited from zypp::base::ReferenceCounted
 ReferenceCounted ()
 Default ctor.
 ReferenceCounted (const ReferenceCounted &rhs)
 Copy ctor.
virtual ~ReferenceCounted ()
 Dtor.
ReferenceCountedoperator= (const ReferenceCounted &)
 Assignment.
unsigned refCount () const
 Return reference counter value.
void ref () const
 Add a reference.
void unref () const
 Release a reference.

Protected Member Functions

virtual ~ZYpp ()
 Dtor.
virtual std::ostream & dumpOn (std::ostream &str) const
 Stream output.
- Protected Member Functions inherited from zypp::base::ReferenceCounted
virtual void ref_to (unsigned) const
 Trigger derived classes after refCount was increased.
virtual void unref_to (unsigned) const
 Trigger derived classes after refCount was decreased.

Private Types

typedef zypp_detail::ZYppImpl Impl
typedef shared_ptr< ImplImpl_Ptr

Private Member Functions

 ZYpp (const Impl_Ptr &impl_r)
 Factory ctor.

Private Attributes

RW_pointer< Impl_pimpl
 Pointer to implementation.

Friends

class ZYppFactory
 Factory.

Additional Inherited Members

- Static Public Member Functions inherited from zypp::base::ReferenceCounted
static void add_ref (const ReferenceCounted *ptr_r)
 Called by zypp::intrusive_ptr to add a reference.
static void release (const ReferenceCounted *ptr_r)
 Called by zypp::intrusive_ptr to add a reference.

Detailed Description

Todo:
define Exceptions ZYpp API main interface

Definition at line 54 of file ZYpp.h.


Member Typedef Documentation

typedef intrusive_ptr<ZYpp> zypp::ZYpp::Ptr

Definition at line 58 of file ZYpp.h.

typedef intrusive_ptr<const ZYpp> zypp::ZYpp::constPtr

Definition at line 59 of file ZYpp.h.

Definition at line 107 of file ZYpp.h.

Definition at line 204 of file ZYpp.h.

typedef shared_ptr<Impl> zypp::ZYpp::Impl_Ptr
private

Definition at line 205 of file ZYpp.h.


Constructor & Destructor Documentation

zypp::ZYpp::~ZYpp ( )
protectedvirtual

Dtor.

Definition at line 39 of file ZYpp.cc.

zypp::ZYpp::ZYpp ( const Impl_Ptr impl_r)
explicitprivate

Factory ctor.

Definition at line 30 of file ZYpp.cc.


Member Function Documentation

ResPool zypp::ZYpp::pool ( void  ) const

Access to the global resolvable pool.

Same as zypp::ResPool::instance

Definition at line 58 of file ZYpp.cc.

ResPoolProxy zypp::ZYpp::poolProxy ( ) const

Pool of ui::Selectable.

Based on the ResPool, ui::Selectable groups ResObjetcs of same kind and name.

Definition at line 70 of file ZYpp.cc.

DiskUsageCounter::MountPointSet zypp::ZYpp::diskUsage ( )

Definition at line 61 of file ZYpp.cc.

void zypp::ZYpp::setPartitions ( const DiskUsageCounter::MountPointSet mp)

Definition at line 64 of file ZYpp.cc.

DiskUsageCounter::MountPointSet zypp::ZYpp::getPartitions ( ) const

Definition at line 67 of file ZYpp.cc.

Target_Ptr zypp::ZYpp::target ( ) const
Exceptions:
Exception

Definition at line 85 of file ZYpp.cc.

Target_Ptr zypp::ZYpp::getTarget ( ) const

Same as target but returns NULL if target is not initialized, instead of throwing.

Definition at line 88 of file ZYpp.cc.

void zypp::ZYpp::initializeTarget ( const Pathname &  root,
bool  doRebuild_r = false 
)
Exceptions:
ExceptionJust init the target, dont populate store or pool. If doRebuild_r is true, an already existing database is rebuilt (rpm –rebuilddb ).

Definition at line 91 of file ZYpp.cc.

void zypp::ZYpp::finishTarget ( )
Exceptions:
Exception

Definition at line 94 of file ZYpp.cc.

ZYppCommitResult zypp::ZYpp::commit ( const ZYppCommitPolicy policy_r)

Commit changes and transactions.

Parameters:
\refCommitPolicy
Returns:
CommitResult
Exceptions:
Exception

Definition at line 97 of file ZYpp.cc.

void zypp::ZYpp::installSrcPackage ( const SrcPackage_constPtr &  srcPackage_r)

Install a source package on the Target.

Exceptions:
Exception

Definition at line 100 of file ZYpp.cc.

Resolver_Ptr zypp::ZYpp::resolver ( ) const

Definition at line 73 of file ZYpp.cc.

KeyRing_Ptr zypp::ZYpp::keyRing ( ) const

Definition at line 76 of file ZYpp.cc.

ZYPP_DEPRECATED void zypp::ZYpp::setTextLocale ( const Locale textLocale_r)
inline

Set the preferred locale for translated labels, descriptions, etc.

passed to the UI.

Deprecated:
Use ZConfig diretcly.

Definition at line 130 of file ZYpp.h.

ZYPP_DEPRECATED Locale zypp::ZYpp::getTextLocale ( ) const
inline
Deprecated:
Use ZConfig diretcly.

Definition at line 133 of file ZYpp.h.

void zypp::ZYpp::setRequestedLocales ( const LocaleSet locales_r)

Set the requested locales.

Languages to be supported by the system, e.g. language specific packages to be installed. This function operates on the pool, so only the locales that are available as resolvables are marked as requested. The rest is ignored.

Deprecated:
Use ResPool diretcly.

Definition at line 105 of file ZYpp.cc.

const LocaleSet & zypp::ZYpp::getRequestedLocales ( ) const
Deprecated:
Use ResPool diretcly.

Definition at line 108 of file ZYpp.cc.

const LocaleSet & zypp::ZYpp::getAvailableLocales ( ) const

Get the set of available locales.

This is computed from the package data so it actually represents all locales packages claim to support.

Deprecated:
Use ResPool diretcly.

Definition at line 111 of file ZYpp.cc.

Pathname zypp::ZYpp::homePath ( ) const

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

Definition at line 115 of file ZYpp.cc.

Pathname zypp::ZYpp::tmpPath ( ) const

Get the path where zypp related plugins store temp data.

Definition at line 118 of file ZYpp.cc.

void zypp::ZYpp::setHomePath ( const Pathname &  path)

set the home, if you need to change it

Definition at line 121 of file ZYpp.cc.

ZYPP_DEPRECATED Arch zypp::ZYpp::architecture ( ) const
inline

Get the system architecture.

Deprecated:
Use ZConfig diretcly.

Definition at line 175 of file ZYpp.h.

ZYPP_DEPRECATED void zypp::ZYpp::setArchitecture ( const Arch arch)
inline

Set the system architecture.

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

Deprecated:
Use ZConfig diretcly.

Definition at line 182 of file ZYpp.h.

ZYPP_DEPRECATED int zypp::ZYpp::applyLocks ( )
inline
Deprecated:
Persistent locks are automatically maintained, kept in the pool, loaded and saved together with the Target.

ZConfig::apply_locks_file tells whether locks are applied or not.

Definition at line 191 of file ZYpp.h.

std::ostream & zypp::ZYpp::dumpOn ( std::ostream &  str) const
protectedvirtual

Stream output.

Reimplemented from zypp::base::ReferenceCounted.

Definition at line 47 of file ZYpp.cc.


Friends And Related Function Documentation

friend class ZYppFactory
friend

Factory.

Definition at line 201 of file ZYpp.h.


Member Data Documentation

RW_pointer<Impl> zypp::ZYpp::_pimpl
private

Pointer to implementation.

Definition at line 211 of file ZYpp.h.


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