PackageSack

class PackageSack

Public Functions

explicit PackageSack(const libdnf5::BaseWeakPtr &base)
explicit PackageSack(libdnf5::Base &base)
~PackageSack()
PackageSackWeakPtr get_weak_ptr()

Create WeakPtr to PackageSack.

libdnf5::BaseWeakPtr get_base() const

Since

5.0

Returns:

The Base object to which this object belongs.

int get_nsolvables() const noexcept

Returns number of solvables in pool.

void load_config_excludes_includes(bool only_main = false)

Loads excluded and included package sets from the configuration. Uses the disable_excludes, excludepkgs, and includepkgs configuration options for calculation.

Since

5.0

Parameters:

only_main – If true, the repository specific configurations are not used.

const PackageSet get_user_excludes()

Returns user excluded package set.

void add_user_excludes(const PackageSet &excludes)

Add package set to user excluded packages

Since

5.0

Parameters:

excludes – packages to add to excludes

void remove_user_excludes(const PackageSet &excludes)

Remove package set from user excluded packages

Since

5.0

Parameters:

excludes – packages to remove from excludes

void set_user_excludes(const PackageSet &excludes)

Resets user excluded packages to a new value

Since

5.0

Parameters:

excludes – packages to exclude

void clear_user_excludes()

Clear user excluded packages

Since

5.0

const PackageSet get_user_includes()

Returns user included package set.

void add_user_includes(const PackageSet &includes)

Add package set to user included packages

Since

5.0

Parameters:

includes – packages to add to includes

void remove_user_includes(const PackageSet &includes)

Remove package set from user included packages

Since

5.0

Parameters:

includes – packages to remove from includes

void set_user_includes(const PackageSet &includes)

Resets user included packages to a new value

Since

5.0

Parameters:

includes – packages to include

void clear_user_includes()

Clear user included packages

Since

5.0

VersionlockConfig get_versionlock_config() const

Returns versionlock configuration

Since

5.1.13

const PackageSet get_versionlock_excludes()

Returns versionlock excluded package set

Since

5.1.13

void add_versionlock_excludes(const PackageSet &excludes)

Add package set to versionlock excluded packages

Since

5.1.13

Parameters:

excludes – packages to add to excludes

void remove_versionlock_excludes(const PackageSet &excludes)

Remove package set from versionlock excluded packages

Since

5.1.13

Parameters:

excludes – packages to remove from excludes

void set_versionlock_excludes(const PackageSet &excludes)

Resets versionlock excluded packages to a new value

Since

5.1.13

Parameters:

excludes – packages to exclude

void clear_versionlock_excludes()

Clear versionlock excluded packages

Since

5.1.13

rpm::Package get_running_kernel()

Friends

friend class repo::Repo
friend class libdnf5::module::ModuleSack