#include <Source.h>
Inheritance diagram for zypp::Source_Ref:

Public Types | |
| typedef source::SourceImpl | Impl |
| typedef source::SourceImpl_Ptr | Impl_Ptr |
| typedef unsigned long | NumericId |
Public Member Functions | |
| Source_Ref () | |
| Default ctor: noSource. | |
| NumericId | numericId () const |
| Runtime unique numeric Source Id. | |
| std::string | checksum () const |
| an aproxmate checksum that should change when the source changes can be used to determine if the source needs to be read again or not. | |
| Date | timestamp () const |
| aproximate age of the source, can be used to determine if the source needs to be read again or not. | |
| bool | hasResolvablesOfKind (const zypp::Resolvable::Kind &kind) const |
| wether this source provides or supports resolvables of certain kind. | |
| std::set< zypp::Resolvable::Kind > | resolvableKinds () const |
| set of resolvable types the source can offer at this moment | |
| bool | resStoreInitialized () const |
| Whether the ResStore is initialized. | |
| const ResStore & | resolvables () const |
| All resolvables provided by this source. | |
| const ResStore | resolvables (zypp::Resolvable::Kind kind) const |
| All resolvables of a given kind provided by this source. | |
| const Pathname | providePackage (Package::constPtr package) |
| const Pathname | provideFile (const Pathname &file_r, const unsigned media_nr=1) |
| Provide a file to local filesystem. | |
| const Pathname | provideDirTree (const Pathname &dir_r, const unsigned media_nr=1) |
| const void | releaseFile (const Pathname &file_r, const unsigned media_nr=1) |
| const void | releaseDir (const Pathname &dir_r, const unsigned media_nr=1, bool recursive=false) |
| bool | enabled () const |
| void | enable () |
| void | disable () |
| bool | autorefresh () const |
| void | setAutorefresh (bool enable_r) |
| void | refresh () |
| void | storeMetadata (const Pathname &cache_dir_r) |
| std::string | alias (void) const |
| User chosen identificaton, must be unique. | |
| void | setAlias (const std::string &alias_r) |
| User chosen identificaton, must be unique. | |
| std::string | type (void) const |
| Source type, like YaST or YUM. | |
| unsigned | numberOfMedia (void) const |
| std::string | vendor (void) const |
| from media.1/media | |
| std::string | unique_id (void) const |
| from media.1/media | |
| void | changeMedia (const media::MediaId &media_r, const Pathname &path_r) |
| Change the media of the source (in case original media is not available) The media must be ready-to-use (in the same form as when passing to SourceImpl constructor). | |
| void | redirect (unsigned media_nr, const Url &new_url) |
| Redirect the given media to the given URL instead of the standard one. | |
| void | release () |
| Release all medias attached by the source. | |
| void | reattach (const Pathname &attach_point) |
| Reattach the source if it is not mounted, but downloaded, to different directory. | |
| media::MediaVerifierRef | verifier (unsigned media_nr) |
| Provide a media verifier suitable for the given media number. | |
Static Public Attributes | |
| static const Source_Ref | noSource |
A dummy Source (Id 0) providing nothing, doing nothing. | |
Private Member Functions | |
| friend | base::SafeBool () const |
| bool | boolTest () const |
| SafeBool test. | |
| Source_Ref (const Impl_Ptr &impl_r) | |
| Factory ctor. | |
Private Attributes | |
| Impl_Ptr | _pimpl |
| Pointer to implementation. | |
Friends | |
| class | SourceFactory |
| Factory. | |
| class | source::SourceImpl |
| std::ostream & | operator<< (std::ostream &str, const Source_Ref &obj) |
| bool | operator== (const Source_Ref &lhs, const Source_Ref &rhs) |
| Equal if same implementation class. | |
| bool | operator< (const Source_Ref &lhs, const Source_Ref &rhs) |
| Order in std::conainer based on _pimpl. | |
Related Functions | |
| (Note that these are not member functions.) | |
| bool | operator!= (const Source_Ref &lhs, const Source_Ref &rhs) |
No COW is performed.
Definition at line 109 of file Source.h.
| typedef source::SourceImpl_Ptr zypp::Source_Ref::Impl_Ptr |
| typedef unsigned long zypp::Source_Ref::NumericId |
| zypp::Source_Ref::Source_Ref | ( | ) |
Default ctor: noSource.
Real Sources are to be created via SourceFactory.
| zypp::Source_Ref::Source_Ref | ( | const Impl_Ptr & | impl_r | ) | [explicit, private] |
| Source_Ref::NumericId zypp::Source_Ref::numericId | ( | ) | const |
Runtime unique numeric Source Id.
Definition at line 54 of file Source.cc.
References _pimpl.
Referenced by zypp::solver::detail::Testcase::createTestcase(), zypp::ResObject::dumpOn(), zypp::solver::detail::HelixControl::installResolvable(), and zypp::sourceTableAdd().
| std::string zypp::Source_Ref::checksum | ( | ) | const |
| Date zypp::Source_Ref::timestamp | ( | ) | const |
| bool zypp::Source_Ref::hasResolvablesOfKind | ( | const zypp::Resolvable::Kind & | kind | ) | const |
| std::set< zypp::Resolvable::Kind > zypp::Source_Ref::resolvableKinds | ( | ) | const |
| bool zypp::Source_Ref::resStoreInitialized | ( | ) | const |
| const ResStore & zypp::Source_Ref::resolvables | ( | ) | const |
| const ResStore zypp::Source_Ref::resolvables | ( | zypp::Resolvable::Kind | kind | ) | const |
| const Pathname zypp::Source_Ref::providePackage | ( | Package::constPtr | package | ) |
| const Pathname zypp::Source_Ref::provideFile | ( | const Pathname & | file_r, | |
| const unsigned | media_nr = 1 | |||
| ) |
Provide a file to local filesystem.
Definition at line 66 of file Source.cc.
References _pimpl.
Referenced by zypp::source::yum::YUMScriptImpl::do_script(), zypp::source::provideFile(), and zypp::source::yum::YUMScriptImpl::undo_script().
| const Pathname zypp::Source_Ref::provideDirTree | ( | const Pathname & | dir_r, | |
| const unsigned | media_nr = 1 | |||
| ) |
| const void zypp::Source_Ref::releaseFile | ( | const Pathname & | file_r, | |
| const unsigned | media_nr = 1 | |||
| ) |
Definition at line 77 of file Source.cc.
References _pimpl.
Referenced by zypp::source::provideFile().
| const void zypp::Source_Ref::releaseDir | ( | const Pathname & | dir_r, | |
| const unsigned | media_nr = 1, |
|||
| bool | recursive = false | |||
| ) |
| bool zypp::Source_Ref::enabled | ( | ) | const |
| void zypp::Source_Ref::enable | ( | ) |
Definition at line 89 of file Source.cc.
References _pimpl.
Referenced by zypp::SourceManager::restore().
| void zypp::Source_Ref::disable | ( | ) |
Definition at line 92 of file Source.cc.
References _pimpl.
Referenced by zypp::SourceManager::restore().
| bool zypp::Source_Ref::autorefresh | ( | ) | const |
| void zypp::Source_Ref::setAutorefresh | ( | bool | enable_r | ) |
| void zypp::Source_Ref::storeMetadata | ( | const Pathname & | cache_dir_r | ) |
Definition at line 110 of file Source.cc.
References _pimpl.
Referenced by zypp::SourceCache::storeSource().
| string zypp::Source_Ref::alias | ( | void | ) | const |
User chosen identificaton, must be unique.
Definition at line 113 of file Source.cc.
References _pimpl.
Referenced by zypp::source::susetags::PackagesParser::collectDeps(), zypp::source::susetags::PackagesParser::consume(), zypp::source::plaindir::PlaindirImpl::extract_packages_from_directory(), zypp::source::susetags::ProductMetadataParser::parse(), zypp::source::susetags::parsePackages(), zypp::source::susetags::parseSelection(), zypp::SourceManager::renameSource(), zypp::SourceCache::storeSource(), and zypp::solver::detail::ResolverInfo::toString().
| void zypp::Source_Ref::setAlias | ( | const std::string & | alias_r | ) |
User chosen identificaton, must be unique.
Definition at line 116 of file Source.cc.
References _pimpl.
Referenced by zypp::SourceManager::renameSource().
| string zypp::Source_Ref::type | ( | void | ) | const |
| unsigned zypp::Source_Ref::numberOfMedia | ( | void | ) | const |
| std::string zypp::Source_Ref::vendor | ( | void | ) | const |
from media.1/media
Definition at line 194 of file Source.cc.
References _pimpl.
Referenced by zypp::source::susetags::SuseTagsPackageImpl::vendor().
| std::string zypp::Source_Ref::unique_id | ( | void | ) | const |
| string zypp::Source_Ref::id | ( | void | ) | const |
| void zypp::Source_Ref::setId | ( | const std::string | id_r | ) |
| unsigned zypp::Source_Ref::priority | ( | void | ) | const |
Definition at line 140 of file Source.cc.
References _pimpl.
Referenced by zypp::solver::detail::ResolverQueue::copy_queue_except_for_branch(), and zypp::solver::detail::ResolverContext::getSourcePriority().
| void zypp::Source_Ref::setPriority | ( | unsigned | p | ) |
| unsigned zypp::Source_Ref::priorityUnsubscribed | ( | void | ) | const |
Definition at line 146 of file Source.cc.
References _pimpl.
Referenced by zypp::solver::detail::ResolverContext::getSourcePriority().
| void zypp::Source_Ref::setPriorityUnsubscribed | ( | unsigned | p | ) |
| bool zypp::Source_Ref::subscribed | ( | void | ) | const |
Definition at line 152 of file Source.cc.
References _pimpl.
Referenced by zypp::solver::detail::ResolverContext::getSourcePriority().
| void zypp::Source_Ref::setSubscribed | ( | bool | s | ) |
| const Pathname & zypp::Source_Ref::cacheDir | ( | void | ) | const |
| const std::list< Pathname > zypp::Source_Ref::publicKeys | ( | ) |
| string zypp::Source_Ref::zmdName | ( | void | ) | const |
| void zypp::Source_Ref::setZmdName | ( | const std::string | name_r | ) |
| string zypp::Source_Ref::zmdDescription | ( | void | ) | const |
| void zypp::Source_Ref::setZmdDescription | ( | const std::string | desc_r | ) |
| Url zypp::Source_Ref::url | ( | void | ) | const |
Definition at line 158 of file Source.cc.
References _pimpl.
Referenced by zypp::source::susetags::PackagesParser::collectDeps(), zypp::source::susetags::PackagesParser::consume(), zypp::source::MediaSet::getMediaAccessId(), zypp::source::susetags::ProductMetadataParser::parse(), zypp::source::susetags::parsePackages(), zypp::source::susetags::parseSelection(), setUrl(), and zypp::SourceCache::storeSource().
| void zypp::Source_Ref::setUrl | ( | const Url & | url | ) |
| bool zypp::Source_Ref::remote | ( | ) | const |
| const Pathname & zypp::Source_Ref::path | ( | void | ) | const |
Definition at line 167 of file Source.cc.
References _pimpl.
Referenced by zypp::source::MediaSet::getMediaAccessId(), and zypp::SourceCache::storeSource().
| bool zypp::Source_Ref::baseSource | ( | ) | const |
Definition at line 170 of file Source.cc.
References _pimpl.
Referenced by zypp::source::susetags::ProductMetadataParser::parse(), and zypp::source::yum::YUMProductImpl::YUMProductImpl().
| void zypp::Source_Ref::changeMedia | ( | const media::MediaId & | media_r, | |
| const Pathname & | path_r | |||
| ) |
| void zypp::Source_Ref::redirect | ( | unsigned | media_nr, | |
| const Url & | new_url | |||
| ) |
| void zypp::Source_Ref::release | ( | ) |
Release all medias attached by the source.
Definition at line 182 of file Source.cc.
References _pimpl.
Referenced by zypp::target::TargetImpl::commit().
| void zypp::Source_Ref::reattach | ( | const Pathname & | attach_point | ) |
| media::MediaVerifierRef zypp::Source_Ref::verifier | ( | unsigned | media_nr | ) |
Provide a media verifier suitable for the given media number.
Definition at line 188 of file Source.cc.
References _pimpl.
Referenced by zypp::source::MediaSet::getMediaAccessId(), and zypp::source::MediaSet::redirect().
| zypp::Source_Ref::base::SafeBool | ( | ) | const [private] |
| bool zypp::Source_Ref::boolTest | ( | ) | const [inline, private] |
| string zypp::Source_Ref::id | ( | void | ) | const |
| void zypp::Source_Ref::setId | ( | const std::string | id_r | ) |
| unsigned zypp::Source_Ref::priority | ( | void | ) | const |
Definition at line 140 of file Source.cc.
References _pimpl.
Referenced by zypp::solver::detail::ResolverQueue::copy_queue_except_for_branch(), and zypp::solver::detail::ResolverContext::getSourcePriority().
| void zypp::Source_Ref::setPriority | ( | unsigned | p | ) |
| unsigned zypp::Source_Ref::priorityUnsubscribed | ( | void | ) | const |
Definition at line 146 of file Source.cc.
References _pimpl.
Referenced by zypp::solver::detail::ResolverContext::getSourcePriority().
| void zypp::Source_Ref::setPriorityUnsubscribed | ( | unsigned | p | ) |
| bool zypp::Source_Ref::subscribed | ( | void | ) | const |
Definition at line 152 of file Source.cc.
References _pimpl.
Referenced by zypp::solver::detail::ResolverContext::getSourcePriority().
| void zypp::Source_Ref::setSubscribed | ( | bool | s | ) |
| const Pathname & zypp::Source_Ref::cacheDir | ( | void | ) | const |
| const std::list< Pathname > zypp::Source_Ref::publicKeys | ( | ) |
| string zypp::Source_Ref::zmdName | ( | void | ) | const |
| void zypp::Source_Ref::setZmdName | ( | const std::string | name_r | ) |
| string zypp::Source_Ref::zmdDescription | ( | void | ) | const |
| void zypp::Source_Ref::setZmdDescription | ( | const std::string | desc_r | ) |
| Url zypp::Source_Ref::url | ( | void | ) | const |
Definition at line 158 of file Source.cc.
References _pimpl.
Referenced by zypp::source::susetags::PackagesParser::collectDeps(), zypp::source::susetags::PackagesParser::consume(), zypp::source::MediaSet::getMediaAccessId(), zypp::source::susetags::ProductMetadataParser::parse(), zypp::source::susetags::parsePackages(), zypp::source::susetags::parseSelection(), setUrl(), and zypp::SourceCache::storeSource().
| void zypp::Source_Ref::setUrl | ( | const Url & | url | ) |
| bool zypp::Source_Ref::remote | ( | ) | const |
| const Pathname & zypp::Source_Ref::path | ( | void | ) | const |
Definition at line 167 of file Source.cc.
References _pimpl.
Referenced by zypp::source::MediaSet::getMediaAccessId(), and zypp::SourceCache::storeSource().
| bool zypp::Source_Ref::baseSource | ( | ) | const |
Definition at line 170 of file Source.cc.
References _pimpl.
Referenced by zypp::source::susetags::ProductMetadataParser::parse(), and zypp::source::yum::YUMProductImpl::YUMProductImpl().
friend class SourceFactory [friend] |
friend class source::SourceImpl [friend] |
| std::ostream& operator<< | ( | std::ostream & | str, | |
| const Source_Ref & | obj | |||
| ) | [friend] |
| bool operator== | ( | const Source_Ref & | lhs, | |
| const Source_Ref & | rhs | |||
| ) | [friend] |
| bool operator< | ( | const Source_Ref & | lhs, | |
| const Source_Ref & | rhs | |||
| ) | [friend] |
| bool operator!= | ( | const Source_Ref & | lhs, | |
| const Source_Ref & | rhs | |||
| ) | [related] |
const Source_Ref zypp::Source_Ref::noSource [static] |
A dummy Source (Id 0) providing nothing, doing nothing.
Definition at line 129 of file Source.h.
Referenced by boolTest(), zypp::solver::detail::ResolverContext::collectCompareInfo(), zypp::SourceFactory::createFrom(), zypp::MediaSetAccess::provideFileInternal(), and zypp::detail::ResObjectImplIf::source().
Impl_Ptr zypp::Source_Ref::_pimpl [private] |
Pointer to implementation.
Definition at line 309 of file Source.h.
Referenced by alias(), autorefresh(), baseSource(), boolTest(), cacheDir(), changeMedia(), checksum(), disable(), enable(), enabled(), hasResolvablesOfKind(), id(), numberOfMedia(), numericId(), zypp::operator<<(), path(), priority(), priorityUnsubscribed(), provideDirTree(), provideFile(), providePackage(), publicKeys(), reattach(), redirect(), refresh(), release(), releaseDir(), releaseFile(), remote(), resolvableKinds(), resolvables(), resStoreInitialized(), setAlias(), setAutorefresh(), setId(), setPriority(), setPriorityUnsubscribed(), setSubscribed(), setUrl(), setZmdDescription(), setZmdName(), storeMetadata(), subscribed(), timestamp(), type(), unique_id(), url(), vendor(), verifier(), zmdDescription(), and zmdName().
1.5.0