inline bool IsGood() const { return S && Owner && ! end();};
inline unsigned long Index() const {return S - OwnerPointer();};
- void ReOwn(pkgCache &newOwner, void const * const oldMap, void const * const newMap) {
- if (S == 0)
+ void ReMap(void const * const oldMap, void const * const newMap) {
+ if (Owner == 0 || S == 0)
return;
S += (Str*)(newMap) - (Str*)(oldMap);
}
/** \brief find the package with the "best" architecture
The best architecture is either the "native" or the first
- in the list of Architectures which is not an end-Pointer */
- PkgIterator FindPreferredPkg() const;
+ in the list of Architectures which is not an end-Pointer
+
+ \param PreferNonVirtual tries to respond with a non-virtual package
+ and only if this fails returns the best virtual package */
+ PkgIterator FindPreferredPkg(bool const &PreferNonVirtual = true) const;
PkgIterator NextPkg(PkgIterator const &Pkg) const;
// Constructors