1 /*---------------------------------------------------------------------\
3 | |__ / \ / / . \ . \ |
8 \---------------------------------------------------------------------*/
9 /** \file zypp/sat/detail/PoolMember.h
12 #ifndef ZYPP_SAT_DETAIL_POOLMEMBER_H
13 #define ZYPP_SAT_DETAIL_POOLMEMBER_H
15 #include "zypp/base/Iterator.h"
24 ///////////////////////////////////////////////////////////////////
26 { /////////////////////////////////////////////////////////////////
32 ///////////////////////////////////////////////////////////////////
34 { /////////////////////////////////////////////////////////////////
40 ///////////////////////////////////////////////////////////////////
42 { /////////////////////////////////////////////////////////////////
46 ///////////////////////////////////////////////////////////////////
48 // CLASS NAME : PoolMember
50 /** Backlink to the associated \ref PoolImpl.
51 * Simple as we currently use one global PoolImpl. If we change our
52 * minds this is where we'd store and do the \c Id to \ref PoolImpl
57 static PoolImpl & myPool();
59 ///////////////////////////////////////////////////////////////////
61 /////////////////////////////////////////////////////////////////
63 ///////////////////////////////////////////////////////////////////
66 ///////////////////////////////////////////////////////////////////
68 { /////////////////////////////////////////////////////////////////
70 /** Generic Id type. */
72 static const IdType noId( 0 );
73 static const IdType emptyId( 1 );
75 /** Internal ids satlib includes in dependencies.
76 * MPL check in PoolImpl.cc
78 static const IdType solvablePrereqMarker( 16 );
79 static const IdType solvableFileMarker ( 17 );
80 /** Test for internal ids satlib includes in dependencies. */
81 inline bool isDepMarkerId( IdType id_r )
82 { return( id_r == solvablePrereqMarker || id_r == solvableFileMarker ); }
84 /** Id type to connect \ref Solvable and sat-solvable.
85 * Indext into solvable array.
87 typedef unsigned SolvableIdType;
88 typedef SolvableIdType size_type;
89 /** Id to denote \ref Solvable::nosolvable. */
90 static const SolvableIdType noSolvableId( 0 );
92 /** Id type to connect \ref Repo and sat-repo. */
93 typedef ::_Repo * RepoIdType;
94 /** Id to denote \ref Repo::nosolvable. */
95 static const RepoIdType noRepoId( 0 );
97 /////////////////////////////////////////////////////////////////
99 ///////////////////////////////////////////////////////////////////
102 ///////////////////////////////////////////////////////////////////
104 { /////////////////////////////////////////////////////////////////
106 class SolvableIterator;
110 /////////////////////////////////////////////////////////////////
111 } // namespace detail
112 ///////////////////////////////////////////////////////////////////
114 /////////////////////////////////////////////////////////////////
116 ///////////////////////////////////////////////////////////////////
117 /////////////////////////////////////////////////////////////////
119 ///////////////////////////////////////////////////////////////////
120 #endif // ZYPP_SAT_DETAIL_POOLMEMBER_H