debsystem.h 1.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. // -*- mode: cpp; mode: fold -*-
  2. // Description /*{{{*/
  3. // $Id: debsystem.h,v 1.4 2003/01/11 07:16:33 jgg Exp $
  4. /* ######################################################################
  5. System - Debian version of the System Class
  6. ##################################################################### */
  7. /*}}}*/
  8. #ifndef PKGLIB_DEBSYSTEM_H
  9. #define PKGLIB_DEBSYSTEM_H
  10. #ifdef __GNUG__
  11. #pragma interface "apt-pkg/debsystem.h"
  12. #endif
  13. #include <apt-pkg/pkgsystem.h>
  14. class debStatusIndex;
  15. class debSystem : public pkgSystem
  16. {
  17. // For locking support
  18. int LockFD;
  19. unsigned LockCount;
  20. bool CheckUpdates();
  21. debStatusIndex *StatusFile;
  22. public:
  23. virtual bool Lock();
  24. virtual bool UnLock(bool NoErrors = false);
  25. virtual pkgPackageManager *CreatePM(pkgDepCache *Cache) const;
  26. virtual bool Initialize(Configuration &Cnf);
  27. virtual bool ArchiveSupported(const char *Type);
  28. virtual signed Score(Configuration const &Cnf);
  29. virtual bool AddStatusFiles(std::vector<pkgIndexFile *> &List);
  30. virtual bool FindIndex(pkgCache::PkgFileIterator File,
  31. pkgIndexFile *&Found) const;
  32. debSystem();
  33. ~debSystem();
  34. };
  35. extern debSystem debSys;
  36. #endif