|
libzypp
9.1.2
|
Downloader for YUM (rpm-nmd) repositories Encapsulates all the knowledge of which files have to be downloaded to the local disk. More...
#include <Downloader.h>

Public Member Functions | |
| Downloader (const RepoInfo &info, const Pathname &delta_dir=Pathname()) | |
| Constructor from the repository information. | |
| void | download (MediaSetAccess &media, const Pathname &dest_dir, const ProgressData::ReceiverFnc &progress=ProgressData::ReceiverFnc()) |
| Download metadata to a local directory. | |
| RepoStatus | status (MediaSetAccess &media) |
| Status of the remote repository. | |
Protected Member Functions | |
| bool | repomd_Callback (const OnMediaLocation &loc, const ResourceType &dtype) |
| bool | patches_Callback (const OnMediaLocation &loc, const std::string &id) |
Private Attributes | |
| Pathname | _dest_dir |
| Pathname | _delta_dir |
| std::list< OnMediaLocation > | _patches_files |
| MediaSetAccess * | _media_ptr |
Downloader for YUM (rpm-nmd) repositories Encapsulates all the knowledge of which files have to be downloaded to the local disk.
MediaSetAccess media(url); Downloader yum(path); yum.download( media, "localdir");
Definition at line 41 of file Downloader.h.
| zypp::repo::yum::Downloader::Downloader | ( | const RepoInfo & | info, |
| const Pathname & | delta_dir = Pathname() |
||
| ) |
Constructor from the repository information.
The repository information allows more context to be given to the user when something fails.
| info | Repository information |
Definition at line 36 of file Downloader.cc.
| void zypp::repo::yum::Downloader::download | ( | MediaSetAccess & | media, |
| const Pathname & | dest_dir, | ||
| const ProgressData::ReceiverFnc & | progress = ProgressData::ReceiverFnc() |
||
| ) | [virtual] |
Download metadata to a local directory.
| media | Media access to the repository url |
| dest_dir | Local destination directory |
| progress | progress receiver |
Reimplemented from zypp::repo::Downloader.
Definition at line 129 of file Downloader.cc.
References _dest_dir, _media_ptr, zypp::SignatureFileChecker::addPublicKey(), zypp::repo::RepoInfoBase::alias(), zypp::Fetcher::enqueue(), zypp::RepoInfo::gpgCheck(), zypp::RepoInfo::path(), zypp::repo::Downloader::repoInfo(), repomd_Callback(), zypp::Fetcher::reset(), zypp::ProgressData::sendTo(), zypp::SignatureFileChecker::setKeyContext(), zypp::KeyContext::setRepoInfo(), zypp::Fetcher::start(), zypp::ProgressData::tick(), zypp::ProgressData::toMax(), zypp::ProgressData::toMin(), WAR, and ZYPP_THROW.
| RepoStatus zypp::repo::yum::Downloader::status | ( | MediaSetAccess & | media | ) | [virtual] |
Status of the remote repository.
Reimplemented from zypp::repo::Downloader.
Definition at line 42 of file Downloader.cc.
References zypp::MediaSetAccess::provideFile(), and zypp::repo::Downloader::repoInfo().
| bool zypp::repo::yum::Downloader::repomd_Callback | ( | const OnMediaLocation & | loc, |
| const ResourceType & | dtype | ||
| ) | [protected] |
Definition at line 93 of file Downloader.cc.
References _delta_dir, _dest_dir, _media_ptr, zypp::Fetcher::enqueueDigested(), zypp::repo::yum::ResourceType::FILELISTS, zypp::OnMediaLocation::filename(), zypp::repo::yum::loc_with_path_prefix(), MIL, zypp::repo::yum::ResourceType::OTHER, zypp::repo::yum::ResourceType::PATCHES, patches_Callback(), zypp::repo::Downloader::repoInfo(), zypp::repo::yum::search_deltafile(), and zypp::Fetcher::start().
Referenced by download().
| bool zypp::repo::yum::Downloader::patches_Callback | ( | const OnMediaLocation & | loc, |
| const std::string & | id | ||
| ) | [protected] |
Definition at line 84 of file Downloader.cc.
References _delta_dir, zypp::Fetcher::enqueueDigested(), zypp::OnMediaLocation::filename(), zypp::repo::yum::loc_with_path_prefix(), MIL, zypp::repo::Downloader::repoInfo(), and zypp::repo::yum::search_deltafile().
Referenced by repomd_Callback().
Pathname zypp::repo::yum::Downloader::_dest_dir [private] |
Definition at line 75 of file Downloader.h.
Referenced by download(), and repomd_Callback().
Pathname zypp::repo::yum::Downloader::_delta_dir [private] |
Definition at line 76 of file Downloader.h.
Referenced by patches_Callback(), and repomd_Callback().
std::list<OnMediaLocation> zypp::repo::yum::Downloader::_patches_files [private] |
Definition at line 77 of file Downloader.h.
Definition at line 79 of file Downloader.h.
Referenced by download(), and repomd_Callback().
1.7.6.1