1 /*---------------------------------------------------------------------\
3 | |__ / \ / / . \ . \ |
8 \---------------------------------------------------------------------*/
9 /** \file zypp/pool/PoolImpl.h
12 #ifndef ZYPP_POOL_POOLIMPL_H
13 #define ZYPP_POOL_POOLIMPL_H
17 #include "zypp/pool/PoolTraits.h"
19 ///////////////////////////////////////////////////////////////////
21 { /////////////////////////////////////////////////////////////////
22 ///////////////////////////////////////////////////////////////////
24 { /////////////////////////////////////////////////////////////////
26 ///////////////////////////////////////////////////////////////////
28 // CLASS NAME : PoolImpl
33 friend std::ostream & operator<<( std::ostream & str, const PoolImpl & obj );
37 typedef PoolTraits::Item Item;
38 typedef PoolTraits::ContainerT ContainerT;
39 typedef PoolTraits::IndexContainerT IndexContainerT;
40 typedef PoolTraits::size_type size_type;
41 typedef PoolTraits::iterator iterator;
42 typedef PoolTraits::const_iterator const_iterator;
43 typedef PoolTraits::indexiterator indexiterator;
44 typedef PoolTraits::const_indexiterator const_indexiterator;
45 typedef PoolTraits::Inserter Inserter;
46 typedef PoolTraits::Deleter Deleter;
59 const ContainerT & store() const
63 IndexContainerT & providesstore()
64 { return _providesstore; }
66 const IndexContainerT & providesstore() const
67 { return _providesstore; }
71 { return _store.empty(); }
73 size_type size() const
74 { return _store.size(); }
78 { return _store.begin(); }
80 const_iterator begin() const
81 { return _store.begin(); }
84 indexiterator providesbegin(const std::string & tag_r)
85 { return _providesstore.lower_bound (tag_r); }
87 const_indexiterator providesbegin(const std::string & tag_r) const
88 { return _providesstore.lower_bound (tag_r); }
92 { return _store.end(); }
94 const_iterator end() const
95 { return _store.end(); }
98 indexiterator providesend(const std::string & tag_r)
99 { return _providesstore.upper_bound (tag_r); }
101 const_indexiterator providesend(const std::string & tag_r) const
102 { return _providesstore.upper_bound (tag_r); }
107 _providesstore.clear();
114 IndexContainerT _providesstore;
116 ///////////////////////////////////////////////////////////////////
118 /** \relates PoolImpl Stream output */
119 std::ostream & operator<<( std::ostream & str, const PoolImpl & obj );
121 /////////////////////////////////////////////////////////////////
123 ///////////////////////////////////////////////////////////////////
124 /////////////////////////////////////////////////////////////////
126 ///////////////////////////////////////////////////////////////////
127 #endif // ZYPP_POOL_POOLIMPL_H