AdvisorySet

class libdnf5.advisory.AdvisorySet(*args)
add(adv)

Add adv to the set.

Parameters:

adv (Advisory) – Advisory to be added to the set.

Since: 5.0

begin()
clear()

Remove all advisories from the set.

Since: 5.0

contains(adv)
Return type:

boolean

Returns:

true if an advisory is in the set, false otherwise.

Parameters:

adv (Advisory) – Advisory that is tested for presence.

Since: 5.0

difference(other)

Set difference: elements in the current set that are not in the other set.

Parameters:

other (AdvisorySet) – The set to check for differences in.

Raises:

UsedDifferentSack When the sets entering the operation do not share the same AdvisorySack.

Since: 5.0

empty()
Return type:

boolean

Returns:

true if the set is empty, false otherwise.

Since: 5.0

end()
get_advisory_packages_sorted_by_name_arch_evr(only_applicable=False)

Gather AdvisoryPackages for each Advisory in the set. The AdvisoryPackages are sorted by libsolv `id`s of name, arch and evr. This is a different sorting than sorting by the strings of AdvisoryPackages names, architectures and evrs.

Parameters:

only_applicable (boolean, optional) – Whether to return only AdvisoryPackages from applicable AdvisoryCollections.

Since: 5.0

get_base()
intersection(other)

Set intersection: elements in the current set that are also in the other set.

Parameters:

other (AdvisorySet) – The set to intersect with.

Raises:

UsedDifferentSack When the sets entering the operation do not share the same AdvisorySack.

Since: 5.0

remove(adv)

Remove adv from the set.

Parameters:

adv (Advisory) – Advisory to be removed from the set.

Since: 5.0

size()
Return type:

int

Returns:

Number of elements in the set.

swap(other)
thisown
update(other)

Set union: elements that are in the current set or in the other set.

Parameters:

other (AdvisorySet) – The set to unify with.

Raises:

UsedDifferentSack When the sets entering the operation do not share the same AdvisorySack.

Since: 5.0