43
43
* an ordinary filter iterator. Do not provide filter iterators
44
44
* here, if there is no index table for it.
46
* For most (*Begin,*End) iterator-pairs there's also an \ref Iterable
47
* provided, so you can use then in range-based for loops:
50
* for_( it, pool.filterBegin(myfilter), pool.filterEnd(myfilter) )
54
* for ( const PoolItem & pi : pool.filter(myfilter) )
46
58
* \include n_ResPool_nomorenameiter
110
122
template<class _Filter>
111
123
filter_iterator<_Filter,const_iterator> filterEnd( const _Filter & filter_r ) const
112
124
{ return make_filter_end( filter_r, *this ); }
126
template<class _Filter>
127
Iterable<filter_iterator<_Filter,const_iterator> > filter( const _Filter & filter_r ) const
128
{ return makeIterable( filterBegin( filter_r ), filterEnd( filter_r ) ); }
115
131
/** \name Iterate over all PoolItems by status.
137
153
filter_iterator<filter::ByStatus,const_iterator> byStatusEnd( const filter::ByStatus & filter_r ) const
138
154
{ return make_filter_end( filter_r, *this ); }
156
Iterable<filter_iterator<filter::ByStatus,const_iterator> > byStatus( const filter::ByStatus & filter_r ) const
157
{ return makeIterable( byStatusBegin( filter_r ), byStatusEnd( filter_r ) ); }
204
223
/** Takes a \ref sat::Solvable::ident string. */
205
224
byIdent_iterator byIdentEnd( IdString ident_r ) const
206
225
{ return byIdentEnd( ByIdent(ident_r) ); }
228
Iterable<byIdent_iterator> byIdent( const ByIdent & ident_r ) const
229
{ return makeIterable( byIdentBegin( ident_r ), byIdentEnd( ident_r ) ); }
231
Iterable<byIdent_iterator> byIdent( ResKind kind_r, IdString name_r ) const
232
{ return makeIterable( byIdentBegin( kind_r, name_r ), byIdentEnd( kind_r, name_r ) ); }
234
Iterable<byIdent_iterator> byIdent( ResKind kind_r, const C_Str & name_r ) const
235
{ return makeIterable( byIdentBegin( kind_r, name_r ), byIdentEnd( kind_r, name_r ) ); }
238
Iterable<byIdent_iterator> byIdent( IdString name_r ) const
239
{ return makeIterable( byIdentBegin<_Res>( name_r ), byIdentEnd<_Res>( name_r ) ); }
242
Iterable<byIdent_iterator> byIdent( const C_Str & name_r ) const
243
{ return makeIterable( byIdentBegin<_Res>( name_r ), byIdentEnd<_Res>( name_r ) ); }
245
Iterable<byIdent_iterator> byIdent( const PoolItem & pi_r ) const
246
{ return makeIterable( byIdentBegin( pi_r ), byIdentEnd( pi_r ) ); }
248
Iterable<byIdent_iterator> byIdent(sat::Solvable slv_r ) const
249
{ return makeIterable( byIdentBegin( slv_r ), byIdentEnd( slv_r ) ); }
251
Iterable<byIdent_iterator> byIdent( IdString ident_r ) const
252
{ return makeIterable( byIdentBegin( ident_r ), byIdentEnd( ident_r ) ); }
225
271
template<class _Res>
226
272
byKind_iterator byKindEnd() const
227
273
{ return make_filter_end( resfilter::byKind<_Res>(), *this ); }
275
Iterable<byKind_iterator> byKind( const ResKind & kind_r ) const
276
{ return makeIterable( byKindBegin( kind_r ), byKindEnd( kind_r ) ); }
279
Iterable<byKind_iterator> byKind() const
280
{ return makeIterable( byKindBegin<_Res>(), byKindEnd<_Res>() ); }
239
292
byName_iterator byNameEnd( const std::string & name_r ) const
240
293
{ return make_filter_end( ByName(name_r), *this ); }
295
Iterable<byName_iterator> byName( const std::string & name_r ) const
296
{ return makeIterable( byNameBegin( name_r ), byNameEnd( name_r ) ); }
259
315
* Returns \ref Repository::norepository if there is no such \ref Repository.
261
317
Repository reposFind( const std::string & alias_r ) const;
319
Iterable<repository_iterator> knownRepositories() const
320
{ return makeIterable( knownRepositoriesBegin(), knownRepositoriesEnd() ); }
336
395
hardLockQueries_iterator hardLockQueriesBegin() const;
337
396
hardLockQueries_iterator hardLockQueriesEnd() const;
398
Iterable<hardLockQueries_iterator> hardLockQueries() const
399
{ return makeIterable( hardLockQueriesBegin(), hardLockQueriesEnd() ); }
339
401
/** Set a new set of queries.
340
402
* The hard-locks of existing PoolItems are adjusted according
341
403
* to the queries. (usually called on target load)