libzypp: zypp::repo::RpmPackageProvider Class Reference

libzypp 17.36.6

Public Member Functions | Protected Member Functions | Private Types | Private Member Functions | Private Attributes | List of all members
zypp::repo::RpmPackageProvider Class Reference

RPM PackageProvider implementation (with deltarpm processing). More...

Inheritance diagram for zypp::repo::RpmPackageProvider:

## Public Member Functions
| RpmPackageProvider (RepoMediaAccess &access_r, Package::constPtr &&package_r, DeltaCandidates &&deltas_r, PackageProviderPolicy &&policy_r)
Public Member Functions inherited from zypp::repo::PackageProviderImpl< Package >
| PackageProviderImpl (RepoMediaAccess &access_r, TPackagePtr &&package_r, PackageProviderPolicy &&policy_r)
| Ctor taking the Package to provide.
| PackageProviderImpl (const PackageProviderImpl &)=delete
| PackageProviderImpl (PackageProviderImpl &&)=delete
PackageProviderImpl & | operator= (const PackageProviderImpl &)=delete
PackageProviderImpl & | operator= (PackageProviderImpl &&)=delete
| ~PackageProviderImpl () override
ManagedFile | providePackage () const override
| Provide the package.
ManagedFile | providePackageFromCache () const override
| Provide the package if it is cached.
bool | isCached () const override
| Whether the package is cached.
Public Member Functions inherited from zypp::repo::PackageProvider::Impl
| Impl ()
| Impl (const Impl &)=delete
| Impl (Impl &&)=delete
Impl & | operator= (const Impl &)=delete
Impl & | operator= (Impl &&)=delete
virtual | ~Impl ()

## Protected Member Functions
ManagedFile | doProvidePackage () const override
| Actually provide the final rpm.
Protected Member Functions inherited from zypp::repo::PackageProviderImpl< Package >
ManagedFile | doProvidePackageFromCache () const
| Lookup the final rpm in cache.
Report & | report () const
| Access to the DownloadResolvableReport.
bool | progressPackageDownload (int value) const
| Redirect ProvideFilePolicy package download progress to this.
void | rpmSigFileChecker (const Pathname &file_r) const
RpmDb::CheckPackageResult | packageSigCheck (const Pathname &path_r, bool isMandatory_r, UserData &userData) const
| Actual rpm package signature check.
void | resolveSignatureErrorAction (repo::DownloadResolvableReport::Action action_r) const
| React on signature verification error user action.
void | defaultReportSignatureError (RpmDb::CheckPackageResult ret, const std::string &detail_r=std::string()) const
| Default signature verification error handling.

## Private Types
using | DeltaRpm = packagedelta::DeltaRpm

## Private Member Functions
ManagedFile | tryDelta (const DeltaRpm &delta_r) const
bool | progressDeltaDownload (int value) const
void | progressDeltaApply (int value) const
bool | queryInstalled (const Edition &ed_r=Edition()) const

## Private Attributes
DeltaCandidates | _deltas

## Additional Inherited Members
Protected Types inherited from zypp::repo::PackageProviderImpl< Package >
using | Base
using | Report
using | RpmDb
PackageProviderPolicy | _policy
TPackagePtr | _package
RepoMediaAccess & | _access

## Detailed Description

RPM PackageProvider implementation (with deltarpm processing).

Definition at line 534 of file PackageProvider.cc.

## Member Typedef Documentation

## ◆ DeltaRpm

using zypp::repo::RpmPackageProvider::DeltaRpm = packagedelta::DeltaRpm
| private

Definition at line 549 of file PackageProvider.cc.

## Constructor & Destructor Documentation

## ◆ RpmPackageProvider()

zypp::repo::RpmPackageProvider::RpmPackageProvider | ( | RepoMediaAccess & | access_r,
|  | Package::constPtr && | package_r,
|  | DeltaCandidates && | deltas_r,
|  | PackageProviderPolicy && | policy_r )
| inline

Definition at line 537 of file PackageProvider.cc.

## Member Function Documentation

## ◆ doProvidePackage()

ManagedFile zypp::repo::RpmPackageProvider::doProvidePackage | ( |  | ) | const
| overrideprotectedvirtual

Actually provide the final rpm.

Report start/problem/finish and retry loop are hadled by providePackage. Here you trigger just progress and delta/plugin callbacks as needed.

Proxy method for progressPackageDownload is provided here.

ProvideFilePolicy policy;
policy.progressCB( bind( &Base::progressPackageDownload, this, _1 ) );
return _access.provideFile( _package->repoInfo(), loc, policy );
zypp::ProvideFilePolicy
Policy for provideFile and RepoMediaAccess.
Definition ProvideFilePolicy.h:31
zypp::ProvideFilePolicy::progressCB
ProvideFilePolicy & progressCB(ProgressCB progressCB_r)
Set callback.
Definition ProvideFilePolicy.h:37
zypp::repo::PackageProviderImpl< Package >::progressPackageDownload
bool progressPackageDownload(int value) const
Definition PackageProvider.cc:198
zypp::repo::PackageProviderImpl< Package >::_access
RepoMediaAccess & _access
Definition PackageProvider.cc:353
zypp::repo::PackageProviderImpl< Package >::_package
TPackagePtr _package
Definition PackageProvider.cc:352

Note
  The provided default implementation retrieves the packages default location.

Reimplemented from zypp::repo::PackageProviderImpl< Package >.

Definition at line 567 of file PackageProvider.cc.

## ◆ tryDelta()

ManagedFile zypp::repo::RpmPackageProvider::tryDelta | ( | const DeltaRpm & | delta_r | ) | const
| private

Definition at line 593 of file PackageProvider.cc.

## ◆ progressDeltaDownload()

bool zypp::repo::RpmPackageProvider::progressDeltaDownload | ( | int | value | ) | const
| inlineprivate

Definition at line 553 of file PackageProvider.cc.

## ◆ progressDeltaApply()

void zypp::repo::RpmPackageProvider::progressDeltaApply | ( | int | value | ) | const
| inlineprivate

Definition at line 556 of file PackageProvider.cc.

## ◆ queryInstalled()

bool zypp::repo::RpmPackageProvider::queryInstalled | ( | const Edition & | ed_r = Edition() | ) | const
| inlineprivate

Definition at line 559 of file PackageProvider.cc.

## Member Data Documentation

## ◆ _deltas

DeltaCandidates zypp::repo::RpmPackageProvider::_deltas
| private

Definition at line 563 of file PackageProvider.cc.

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

- zypp/repo/PackageProvider.cc