libzypp 17.34.1
zypp::RepoCollector Struct Reference

Simple callback to collect the results. More...

#include <zypp/zypp_detail/repomanagerbase_p.h>

Inheritance diagram for zypp::RepoCollector:

Public Member Functions

 RepoCollector ()
 
 RepoCollector (std::string targetDistro_)
 
bool collect (const RepoInfo &repo)
 

Public Attributes

RepoInfoList repos
 
std::string targetDistro
 

Detailed Description

Simple callback to collect the results.

Classes like RepoFileReader call the callback once per each repo in a file.

Passing this functor as callback, you can collect all results at the end, without dealing with async code.

If targetDistro is set, all repos with non-empty RepoInfo::targetDistribution() will be skipped.

Todo
do this through a separate filter

Definition at line 99 of file repomanagerbase_p.h.

Constructor & Destructor Documentation

◆ RepoCollector() [1/2]

zypp::RepoCollector::RepoCollector ( )
inline

Definition at line 101 of file repomanagerbase_p.h.

◆ RepoCollector() [2/2]

zypp::RepoCollector::RepoCollector ( std::string targetDistro_)
inline

Definition at line 104 of file repomanagerbase_p.h.

Member Function Documentation

◆ collect()

bool zypp::RepoCollector::collect ( const RepoInfo & repo)

Definition at line 87 of file repomanagerbase_p.cc.

Member Data Documentation

◆ repos

RepoInfoList zypp::RepoCollector::repos

Definition at line 110 of file repomanagerbase_p.h.

◆ targetDistro

std::string zypp::RepoCollector::targetDistro

Definition at line 111 of file repomanagerbase_p.h.


The documentation for this struct was generated from the following files: