libzypp  17.25.1
Repository.cc
Go to the documentation of this file.
1 /*---------------------------------------------------------------------\
2 | ____ _ __ __ ___ |
3 | |__ / \ / / . \ . \ |
4 | / / \ V /| _/ _/ |
5 | / /__ | | | | | | |
6 | /_____||_| |_| |_| |
7 | |
8 \---------------------------------------------------------------------*/
12 #include <climits>
13 #include <iostream>
14 
15 #include <zypp/base/Logger.h>
16 #include <zypp/base/Gettext.h>
17 #include <zypp/base/Exception.h>
18 #include <zypp/base/Xml.h>
19 
20 #include <zypp/AutoDispose.h>
21 #include <zypp/Pathname.h>
22 
24 #include <zypp/Repository.h>
25 #include <zypp/ResPool.h>
26 #include <zypp/Product.h>
27 #include <zypp/sat/Pool.h>
28 
29 using std::endl;
30 
32 namespace zypp
33 {
34 
35  const Repository Repository::noRepository;
36 
37  const std::string & Repository::systemRepoAlias()
39 
41 
43  { return myPool().getRepo( _id ); }
44 
45 #define NO_REPOSITORY_RETURN( VAL ) \
46  sat::detail::CRepo * _repo( get() ); \
47  if ( ! _repo ) return VAL
48 
49 #define NO_REPOSITORY_THROW( VAL ) \
50  sat::detail::CRepo * _repo( get() ); \
51  if ( ! _repo ) ZYPP_THROW( VAL )
52 
54  {
55  NO_REPOSITORY_RETURN( false );
56  return myPool().isSystemRepo( _repo );
57  }
58 
59  std::string Repository::alias() const
60  {
61  NO_REPOSITORY_RETURN( std::string() );
62  if ( ! _repo->name )
63  return std::string();
64  return _repo->name;
65  }
66 
67  std::string Repository::name() const
68  { return info().name(); }
69 
70  std::string Repository::label() const
71  { return info().label(); }
72 
74  {
75  NO_REPOSITORY_RETURN( INT_MIN );
76  return _repo->priority;
77  }
78 
80  {
81  NO_REPOSITORY_RETURN( INT_MIN );
82  return _repo->subpriority;
83  }
84 
86  {
89  return q.empty() ? std::string() : q.begin().asString();
90  }
91 
93  {
96  return q.empty() ? std::string() : q.begin().asString();
97  }
98 
100  {
101  NO_REPOSITORY_RETURN( false );
103  for_( it, q.begin(), q.end() )
104  if ( it.asString() == id_r )
105  return true;
106  return false;
107  }
108 
110  {
113  return( q.empty() ? 0 : q.begin().asUnsigned() );
114  }
115 
117  {
119  Date generated = generatedTimestamp();
120  if ( ! generated )
121  return 0; // do not calculate over a missing generated timestamp
122 
124  if ( q.empty() )
125  return 0;
126 
127  return generated + Date(q.begin().asUnsigned());
128  }
129 
131  {
134  }
135 
136  bool Repository::hasKeyword( const std::string & val_r ) const
137  {
138  for ( const auto & val : keywords() )
139  if ( val == val_r )
140  return true;
141  return false;
142  }
143 
145  {
146  NO_REPOSITORY_RETURN( false );
147  // system repo is not mirrored
148  if ( isSystemRepo() )
149  return false;
150 
151  Date suggested = suggestedExpirationTimestamp();
152 
153  // if no data, don't suggest
154  if ( ! suggested )
155  return false;
156 
158  }
159 
160  bool Repository::providesUpdatesFor( const CpeId & cpeid_r ) const
161  {
162  NO_REPOSITORY_RETURN( false );
163  if ( ! cpeid_r )
164  return false; // filter queries/products without CpeId, as an empty CpeId matches ANYthing.
165 
166  // check in repository metadata
168  {
169  if ( compare( cpeid_r, it.cpeId(), SetRelation::subset ) )
170  return true;
171  }
172 
173  // check whether known products refer to this as update repo
174  sat::LookupRepoAttr myIds( sat::SolvAttr::repositoryRepoid, *this ); // usually just one, but...
175  if ( ! myIds.empty() )
176  {
177  const ResPool & pool( ResPool::instance() );
178  for_( it, pool.byKindBegin<Product>(), pool.byKindEnd<Product>() )
179  {
180  Product::constPtr prod( (*it)->asKind<Product>() );
181  if ( compare( cpeid_r, prod->cpeId(), SetRelation::superset ) )
182  {
183  for_( myId, myIds.begin(), myIds.end() )
184  {
185  if ( prod->hasUpdateContentIdentifier( myId.asString() ) )
186  return true;
187  }
188  }
189  }
190  }
191  return false;
192  }
193 
195  {
196  NO_REPOSITORY_RETURN( false );
197 
198  // check in repository metadata
200  return true;
201 
202  // check whether known products refer to this as update repo
203  sat::LookupRepoAttr myIds( sat::SolvAttr::repositoryRepoid, *this ); // usually just one, but...
204  if ( ! myIds.empty() )
205  {
206  const ResPool & pool( ResPool::instance() );
207  for_( it, pool.byKindBegin<Product>(), pool.byKindEnd<Product>() )
208  {
209  for_( myId, myIds.begin(), myIds.end() )
210  {
211  if ( (*it)->asKind<Product>()->hasUpdateContentIdentifier( myId.asString() ) )
212  return true;
213  }
214  }
215  }
216  return false;
217  }
218 
220  {
221  NO_REPOSITORY_RETURN( true );
222  return !_repo->nsolvables;
223  }
224 
226  {
228  return _repo->nsolvables;
229  }
230 
232  {
233  NO_REPOSITORY_RETURN( make_filter_iterator( detail::ByRepository( *this ),
236  return make_filter_iterator( detail::ByRepository( *this ),
237  sat::detail::SolvableIterator(_repo->start),
238  sat::detail::SolvableIterator(_repo->end) );
239  }
240 
242  {
243  NO_REPOSITORY_RETURN( make_filter_iterator( detail::ByRepository( *this ),
246  return make_filter_iterator(detail::ByRepository( *this ),
247  sat::detail::SolvableIterator(_repo->end),
248  sat::detail::SolvableIterator(_repo->end) );
249  }
250 
252  {
255  }
256 
258  {
259  return ProductInfoIterator();
260  }
261 
263  {
266  }
267 
269  {
270  return ProductInfoIterator();
271  }
272 
274  {
276  return myPool().repoInfo( _repo );
277  }
278 
279  void Repository::setInfo( const RepoInfo & info_r )
280  {
281  NO_REPOSITORY_THROW( Exception( "Can't set RepoInfo for norepo." ) );
282  if ( info_r.alias() != alias() )
283  {
284  ZYPP_THROW( Exception( str::form( "RepoInfo alias (%s) does not match repository alias (%s)",
285  info_r.alias().c_str(), alias().c_str() ) ) );
286  }
287  myPool().setRepoInfo( _repo, info_r );
288  MIL << *this << endl;
289  }
290 
292  {
294  myPool().setRepoInfo( _repo, RepoInfo() );
295  }
296 
298  {
300  MIL << *this << " removed from pool" << endl;
301  myPool()._deleteRepo( _repo );
303  }
304 
306  {
308  for_( it, sat::Pool::instance().reposBegin(), sat::Pool::instance().reposEnd() )
309  {
310  if ( *it == *this )
311  {
312  if ( ++it != _for_end )
313  return *it;
314  break;
315  }
316  }
317  return noRepository;
318  }
319 
320  void Repository::addSolv( const Pathname & file_r )
321  {
322  NO_REPOSITORY_THROW( Exception( "Can't add solvables to norepo." ) );
323 
324  AutoDispose<FILE*> file( ::fopen( file_r.c_str(), "re" ), ::fclose );
325  if ( file == NULL )
326  {
327  file.resetDispose();
328  ZYPP_THROW( Exception( "Can't open solv-file: "+file_r.asString() ) );
329  }
330 
331  if ( myPool()._addSolv( _repo, file ) != 0 )
332  {
333  ZYPP_THROW( Exception( "Error reading solv-file: "+file_r.asString() ) );
334  }
335 
336  MIL << *this << " after adding " << file_r << endl;
337  }
338 
339  void Repository::addHelix( const Pathname & file_r )
340  {
341  NO_REPOSITORY_THROW( Exception( "Can't add solvables to norepo." ) );
342 
343  std::string command( file_r.extension() == ".gz" ? "zcat " : "cat " );
344  command += file_r.asString();
345 
346  AutoDispose<FILE*> file( ::popen( command.c_str(), "re" ), ::pclose );
347  if ( file == NULL )
348  {
349  file.resetDispose();
350  ZYPP_THROW( Exception( "Can't open helix-file: "+file_r.asString() ) );
351  }
352 
353  if ( myPool()._addHelix( _repo, file ) != 0 )
354  {
355  ZYPP_THROW( Exception( "Error reading helix-file: "+file_r.asString() ) );
356  }
357 
358  MIL << *this << " after adding " << file_r << endl;
359  }
360 
361  void Repository::addTesttags( const Pathname & file_r )
362  {
363  NO_REPOSITORY_THROW( Exception( "Can't add solvables to norepo." ) );
364 
365  std::string command( file_r.extension() == ".gz" ? "zcat " : "cat " );
366  command += file_r.asString();
367 
368  AutoDispose<FILE*> file( ::popen( command.c_str(), "re" ), ::pclose );
369  if ( file == NULL )
370  {
371  file.resetDispose();
372  ZYPP_THROW( Exception( "Can't open testtags-file: "+file_r.asString() ) );
373  }
374 
375  if ( myPool()._addTesttags( _repo, file ) != 0 )
376  {
377  ZYPP_THROW( Exception( "Error reading testtags-file: "+file_r.asString() ) );
378  }
379 
380  MIL << *this << " after adding " << file_r << endl;
381  }
382 
384  {
385  NO_REPOSITORY_THROW( Exception( "Can't add solvables to norepo.") );
386  return myPool()._addSolvables( _repo, count_r );
387  }
388 
389  /******************************************************************
390  **
391  ** FUNCTION NAME : operator<<
392  ** FUNCTION TYPE : std::ostream &
393  */
394  std::ostream & operator<<( std::ostream & str, const Repository & obj )
395  {
396  if ( ! obj )
397  return str << "noRepository";
398 
399  return str << "sat::repo(" << obj.alias() << ")"
400  << "{"
401  << "prio " << obj.get()->priority << '.' << obj.get()->subpriority
402  << ", size " << obj.solvablesSize()
403  << "}";
404  }
405 
406  std::ostream & dumpAsXmlOn( std::ostream & str, const Repository & obj )
407  {
408  return xmlout::node( str, "repository", {
409  { "name", obj.name() },
410  { "alias", obj.alias() }
411  } );
412  }
413 
415  namespace detail
416  {
418  {
419  if ( base() )
420  {
422  do {
423  ++base_reference();
424  } while ( base() < satpool->repos+satpool->nrepos && !*base() );
425  }
426  }
427  } // namespace detail
429 
431  //
432  // Repository::ProductInfoIterator
433  //
435 
437  { base_reference() = sat::LookupRepoAttr( attr_r, repo_r ).begin(); }
438 
439  std::string Repository::ProductInfoIterator::label() const
440  { return base_reference().subFind( sat::SolvAttr::repositoryProductLabel ).asString(); }
441 
443  { return CpeId( base_reference().subFind( sat::SolvAttr::repositoryProductCpeid ).asString(), CpeId::noThrow ); }
444 
446 } // namespace zypp
zypp::Repository::updatesProductBegin
ProductInfoIterator updatesProductBegin() const
Get an iterator to the beginning of distos the repository provides upadates for.
Definition: Repository.cc:262
ResPool.h
zypp::sat::Pool::instance
static Pool instance()
Singleton ctor.
Definition: Pool.h:55
Xml.h
zypp::Repository::get
sat::detail::CRepo * get() const
Expert backdoor.
Definition: Repository.cc:42
zypp::Repository::nextInPool
Repository nextInPool() const
Return next Repository in Pool (or noRepository).
Definition: Repository.cc:305
zypp::Repository::hasContentIdentifier
bool hasContentIdentifier(const ContentIdentifier &id_r) const
Whether id_r matches this repos content identifier.
Definition: Repository.cc:99
zypp::Repository::isUpdateRepo
bool isUpdateRepo() const
Hint whether the Repo may provide updates for a product.
Definition: Repository.cc:194
zypp::Repository::addSolv
void addSolv(const Pathname &file_r)
Load Solvables from a solv-file.
Definition: Repository.cc:320
zypp::Repository::ProductInfoIterator::label
std::string label() const
Product label.
Definition: Repository.cc:438
zypp::sat::detail::PoolImpl::systemRepoAlias
static const std::string & systemRepoAlias()
Reserved system repository alias @System .
Definition: PoolImpl.cc:96
zypp::detail::ByRepository
Functor filtering Solvable by Repository.
Definition: Repository.h:484
zypp::Repository::keywords
Keywords keywords() const
repository keywords (tags)
Definition: Repository.cc:130
zypp::Repository::alias
std::string alias() const
Short unique string to identify a repo.
Definition: Repository.cc:59
zypp::sat::LookupAttr::empty
bool empty() const
Whether the query is empty.
Definition: LookupAttr.cc:242
zypp::sat::SolvAttr::repositoryProductLabel
static const SolvAttr repositoryProductLabel
Definition: SolvAttr.h:169
zypp::Exception
Base class for Exception.
Definition: Exception.h:145
zypp::RepoInfo
What is known about a repository.
Definition: RepoInfo.h:71
zypp::Repository::ProductInfoIterator::cpeId
CpeId cpeId() const
The Common Platform Enumeration name for this product.
Definition: Repository.cc:441
zypp::Repository::updatesProductEnd
ProductInfoIterator updatesProductEnd() const
Get an iterator to the end of distos the repository provides upadates for.
Definition: Repository.cc:268
zypp::sat::SolvAttr::repositoryTimestamp
static const SolvAttr repositoryTimestamp
Definition: SolvAttr.h:165
zypp::sat::detail::CPool
::s_Pool CPool
Wrapped libsolv C data type exposed as backdoor.
Definition: PoolMember.h:61
zypp::sat::LookupAttr::begin
iterator begin() const
Iterator to the begin of query results.
Definition: LookupAttr.cc:236
zypp::xmlout::node
std::ostream & node(std::ostream &out_r, const std::string &name_r, Node::Attr attr_r)
Definition: Xml.h:203
zypp::Product::constPtr
TraitsType::constPtrType constPtr
Definition: Product.h:38
zypp::filesystem::Pathname::extension
std::string extension() const
Return all of the characters in name after and including the last dot in the last element of name.
Definition: Pathname.h:135
MIL
#define MIL
Definition: Logger.h:79
zypp::dumpAsXmlOn
std::ostream & dumpAsXmlOn(std::ostream &str, const Tp &obj, const std::string &name_r)
Definition: Xml.h:213
zypp::Repository::ContentIdentifier
std::string ContentIdentifier
Definition: Repository.h:49
ZYPP_THROW
#define ZYPP_THROW(EXCPT)
Drops a logline and throws the Exception.
Definition: Exception.h:392
zypp::sat::detail::PoolMember::myPool
static PoolImpl & myPool()
Definition: PoolImpl.cc:178
zypp::ResPool::instance
static ResPool instance()
Singleton ctor.
Definition: ResPool.cc:37
Product.h
Pathname.h
zypp::Repository::addHelix
void addHelix(const Pathname &file_r)
Load Solvables from a helix-file.
Definition: Repository.cc:339
zypp::sat::LookupAttr::iterator::asUnsigned
unsigned asUnsigned() const
This is an overloaded member function, provided for convenience. It differs from the above function o...
Definition: LookupAttr.cc:558
zypp::Repository::ContentRevision
std::string ContentRevision
Definition: Repository.h:48
zypp::sat::detail::noRepoId
static const RepoIdType noRepoId(0)
Id to denote Repo::noRepository.
zypp::Repository::solvablesEnd
SolvableIterator solvablesEnd() const
Iterator behind the last Solvable.
Definition: Repository.cc:241
zypp::Repository::suggestedExpirationTimestamp
Date suggestedExpirationTimestamp() const
Suggested expiration timestamp.
Definition: Repository.cc:116
zypp::Product::hasUpdateContentIdentifier
bool hasUpdateContentIdentifier(const Repository::ContentIdentifier &cident_r) const
Whether cident_r is listed as required update repository.
Definition: Product.cc:229
zypp::CpeId
Common Platform Enumearation (2.3) See http://cpe.mitre.org/ for more information on the Common Platf...
Definition: CpeId.h:31
zypp::sat::SolvAttr::repositoryRevision
static const SolvAttr repositoryRevision
Definition: SolvAttr.h:173
Exception.h
NO_REPOSITORY_RETURN
#define NO_REPOSITORY_RETURN(VAL)
Definition: Repository.cc:45
zypp::sat::detail::PoolImpl::_deleteRepo
void _deleteRepo(CRepo *repo_r)
Delete repo repo_r from pool.
Definition: PoolImpl.cc:313
zypp::Repository::systemRepoAlias
static const std::string & systemRepoAlias()
Reserved system repository alias @System .
Definition: Repository.cc:37
zypp::sat::detail::SolvableIdType
unsigned SolvableIdType
Id type to connect Solvable and sat-solvable.
Definition: PoolMember.h:125
zypp::sat::SolvAttr
Solvable attribute keys.
Definition: SolvAttr.h:40
zypp::filesystem::Pathname::c_str
const char * c_str() const
String representation.
Definition: Pathname.h:110
PoolImpl.h
zypp::Repository::providesUpdatesFor
bool providesUpdatesFor(const CpeId &cpeid_r) const
Hint whether the Repo may provide updates for a product identified by it's CpeId.
Definition: Repository.cc:160
Logger.h
NO_REPOSITORY_THROW
#define NO_REPOSITORY_THROW(VAL)
Definition: Repository.cc:49
zypp::repo::RepoInfoBase::alias
std::string alias() const
unique identifier for this source.
Definition: RepoInfoBase.cc:111
zypp::ResPool::byKindBegin
byKind_iterator byKindBegin(const ResKind &kind_r) const
Definition: ResPool.h:261
zypp::Repository::hasKeyword
bool hasKeyword(const std::string &val_r) const
Whether val_r is present in keywords.
Definition: Repository.cc:136
zypp::Repository::solvablesSize
size_type solvablesSize() const
Number of solvables in Repository.
Definition: Repository.cc:225
zypp::str::form
std::string form(const char *format,...) __attribute__((format(printf
Printf style construction of std::string.
Definition: String.cc:35
zypp::repo::RepoInfoBase::name
std::string name() const
Repository name.
Definition: RepoInfoBase.cc:117
zypp::sat::detail::PoolImpl::setRepoInfo
void setRepoInfo(RepoIdType id_r, const RepoInfo &info_r)
Also adjust repo priority and subpriority accordingly.
Definition: PoolImpl.cc:406
zypp::Repository::compatibleWithProductBegin
ProductInfoIterator compatibleWithProductBegin() const
Get an iterator to the beginning of the repository compatible distros.
Definition: Repository.cc:251
zypp::Repository::ProductInfoIterator::ProductInfoIterator
ProductInfoIterator()
Definition: Repository.h:380
zypp
Easy-to use interface to the ZYPP dependency resolver.
Definition: CodePitfalls.doc:1
zypp::Repository::solvablesBegin
SolvableIterator solvablesBegin() const
Iterator to the first Solvable.
Definition: Repository.cc:231
zypp::Repository::satInternalPriority
int satInternalPriority() const
libsolv internal priorities.
Definition: Repository.cc:73
Pool.h
zypp::repo::RepoInfoBase::label
std::string label() const
Label for use in messages for the user interface.
Definition: RepoInfoBase.cc:127
AutoDispose.h
zypp::Repository::addSolvables
sat::Solvable::IdType addSolvables(unsigned count_r)
Add count_r new empty Solvable to this Repository.
Definition: Repository.cc:383
zypp::sat::LookupRepoAttr
Lightweight repository attribute value lookup.
Definition: LookupAttr.h:257
zypp::Repository::satInternalSubPriority
int satInternalSubPriority() const
Definition: Repository.cc:79
zypp::Repository::contentIdentifier
ContentIdentifier contentIdentifier() const
Unique string identifying a repositories content.
Definition: Repository.cc:92
zypp::Repository::clearInfo
void clearInfo()
Remove any RepoInfo set for this repository.
Definition: Repository.cc:291
zypp::sat::ArrayAttr
LookupAttr::TransformIterator based container to retrieve list attributes.
Definition: LookupAttr.h:592
zypp::Repository::Keywords
sat::ArrayAttr< std::string, std::string > Keywords
Definition: Repository.h:46
zypp::Repository::noRepository
static const Repository noRepository
Represents no Repository.
Definition: Repository.h:62
zypp::sat::SolvAttr::repositoryRepoid
static const SolvAttr repositoryRepoid
Definition: SolvAttr.h:171
zypp::sat::detail::SolvableIterator
Definition: Solvable.h:479
zypp::asString
std::string asString(const DefaultIntegral< Tp, TInitial > &obj)
Definition: DefaultIntegral.h:98
zypp::Repository::_id
IdType _id
Definition: Repository.h:329
zypp::ResPool
Global ResObject pool.
Definition: ResPool.h:60
Gettext.h
zypp::sat::SolvAttr::repositoryKeywords
static const SolvAttr repositoryKeywords
Definition: SolvAttr.h:172
zypp::AutoDispose< FILE * >
zypp::Repository::isSystemRepo
bool isSystemRepo() const
Return whether this is the system repository.
Definition: Repository.cc:53
zypp::operator<<
std::ostream & operator<<(std::ostream &str, const Exception &obj)
Definition: Exception.cc:147
zypp::Repository::ProductInfoIterator
Query class for Repository related products.
Definition: Repository.h:371
zypp::Repository::addTesttags
void addTesttags(const Pathname &file_r)
Load Solvables from a libsolv testtags-file.
Definition: Repository.cc:361
zypp::sat::detail::PoolImpl::isSystemRepo
bool isSystemRepo(CRepo *repo_r) const
Definition: PoolImpl.h:100
zypp::Date
Store and operate on date (time_t).
Definition: Date.h:32
for_
#define for_(IT, BEG, END)
Convenient for-loops using iterator.
Definition: Easy.h:28
zypp::Repository::contentRevision
ContentRevision contentRevision() const
Timestamp or arbitrary user supplied string.
Definition: Repository.cc:85
zypp::sat::SolvAttr::repositoryProductCpeid
static const SolvAttr repositoryProductCpeid
Definition: SolvAttr.h:170
zypp::detail::RepositoryIterator::increment
void increment()
Definition: Repository.cc:416
zypp::Repository::size_type
sat::detail::size_type size_type
Definition: Repository.h:43
zypp::Repository::eraseFromPool
void eraseFromPool()
Remove this Repository from it's Pool.
Definition: Repository.cc:297
zypp::Date::now
static Date now()
Return the current time.
Definition: Date.h:78
zypp::filesystem::Pathname
Pathname.
Definition: Pathname.h:44
zypp::ResPool::byKindEnd
byKind_iterator byKindEnd(const ResKind &kind_r) const
Definition: ResPool.h:268
zypp::Repository::compatibleWithProductEnd
ProductInfoIterator compatibleWithProductEnd() const
Get an iterator to the end of the repository compatible distros.
Definition: Repository.cc:257
zypp::sat::LookupAttr::end
iterator end() const
Iterator behind the end of query results.
Definition: LookupAttr.cc:239
zypp::Repository::solvablesEmpty
bool solvablesEmpty() const
Whether Repository contains solvables.
Definition: Repository.cc:219
Repository.h
zypp::Repository::name
std::string name() const
Label to display for this repo.
Definition: Repository.cc:67
zypp::sat::SolvAttr::repositoryUpdates
static const SolvAttr repositoryUpdates
array of repositoryProductLabel repositoryProductCpeid pairs
Definition: SolvAttr.h:167
zypp::sat::detail::PoolImpl::getRepo
CRepo * getRepo(RepoIdType id_r) const
Definition: PoolImpl.h:175
str
String related utilities and Regular expression matching.
zypp::Repository::info
RepoInfo info() const
Return any associated RepoInfo.
Definition: Repository.cc:273
zypp::AutoDispose::resetDispose
void resetDispose()
Set no dispose function.
Definition: AutoDispose.h:162
zypp::CpeId::noThrow
static constexpr NoThrowType noThrow
Indicator argument for non-trowing ctor.
Definition: CpeId.h:62
zypp::Repository::setInfo
void setInfo(const RepoInfo &info_r)
Set RepoInfo for this repository.
Definition: Repository.cc:279
zypp::filesystem::Pathname::asString
const std::string & asString() const
String representation.
Definition: Pathname.h:91
zypp::Repository::generatedTimestamp
Date generatedTimestamp() const
Timestamp when this repository was generated.
Definition: Repository.cc:109
zypp::sat::detail::PoolImpl::_addSolvables
detail::SolvableIdType _addSolvables(CRepo *repo_r, unsigned count_r)
Adding Solvables to a repo.
Definition: PoolImpl.cc:400
zypp::Repository::maybeOutdated
bool maybeOutdated() const
The suggested expiration date of this repository already passed.
Definition: Repository.cc:144
zypp::Repository
Definition: Repository.h:39
zypp::sat::detail::CRepo
::s_Repo CRepo
Wrapped libsolv C data type exposed as backdoor.
Definition: PoolMember.h:63
zypp::Repository::label
std::string label() const
Alias or name, according to ZConfig::repoLabelIsAlias.
Definition: Repository.cc:70
zypp::Repository::SolvableIterator
filter_iterator< detail::ByRepository, sat::detail::SolvableIterator > SolvableIterator
Definition: Repository.h:42
zypp::sat::SolvAttr::repositoryDistros
static const SolvAttr repositoryDistros
array of repositoryProductLabel repositoryProductCpeid pairs
Definition: SolvAttr.h:168
zypp::sat::Pool::get
detail::CPool * get() const
Expert backdoor.
Definition: Pool.cc:49
zypp::sat::LookupAttr::REPO_ATTR
Search for repository attributes.
Definition: LookupAttr.h:118
zypp::sat::detail::PoolImpl::repoInfo
const RepoInfo & repoInfo(RepoIdType id_r)
Definition: PoolImpl.h:212
zypp::Product
Product interface.
Definition: Product.h:32
zypp::sat::SolvAttr::repositoryExpire
static const SolvAttr repositoryExpire
Definition: SolvAttr.h:166
zypp::sat::LookupAttr::iterator::asString
std::string asString() const
This is an overloaded member function, provided for convenience. It differs from the above function o...
Definition: LookupAttr.cc:610