]> git.saurik.com Git - apt.git/blame - apt-pkg/deb/debsystem.h
Merge branch 'feature/apt-dpkg-comm'
[apt.git] / apt-pkg / deb / debsystem.h
CommitLineData
b2e465d6
AL
1// -*- mode: cpp; mode: fold -*-
2// Description /*{{{*/
c5d2d50f 3// $Id: debsystem.h,v 1.4 2003/01/11 07:16:33 jgg Exp $
b2e465d6
AL
4/* ######################################################################
5
6 System - Debian version of the System Class
7
8 ##################################################################### */
9 /*}}}*/
10#ifndef PKGLIB_DEBSYSTEM_H
11#define PKGLIB_DEBSYSTEM_H
12
b2e465d6 13#include <apt-pkg/pkgsystem.h>
472ff00e 14#include <apt-pkg/pkgcache.h>
453b82a3 15#include <apt-pkg/cacheiterators.h>
c5d2d50f 16
453b82a3
DK
17#include <vector>
18class Configuration;
19class pkgIndexFile;
20class pkgPackageManager;
b8f90d97 21class debSystemPrivate;
472ff00e
DK
22class pkgDepCache;
23
453b82a3
DK
24#ifndef APT_10_CLEANER_HEADERS
25class debStatusIndex;
26#endif
27
b2e465d6
AL
28class debSystem : public pkgSystem
29{
b8f90d97 30 // private d-pointer
6c55f07a 31 debSystemPrivate * const d;
3809194b 32 APT_HIDDEN bool CheckUpdates();
b8f90d97 33
b2e465d6
AL
34 public:
35
3b302846 36 virtual bool Lock() APT_OVERRIDE;
b49068c5 37 virtual bool UnLock(bool NoErrors = false) APT_OVERRIDE;
3b302846
DK
38 virtual pkgPackageManager *CreatePM(pkgDepCache *Cache) const APT_OVERRIDE;
39 virtual bool Initialize(Configuration &Cnf) APT_OVERRIDE;
40 virtual bool ArchiveSupported(const char *Type) APT_OVERRIDE;
41 virtual signed Score(Configuration const &Cnf) APT_OVERRIDE;
42 virtual bool AddStatusFiles(std::vector<pkgIndexFile *> &List) APT_OVERRIDE;
af87ab54 43 virtual bool FindIndex(pkgCache::PkgFileIterator File,
3b302846 44 pkgIndexFile *&Found) const APT_OVERRIDE;
b2e465d6
AL
45
46 debSystem();
43fb90dc 47 virtual ~debSystem();
8d6d3f00
DK
48
49 APT_HIDDEN static std::string GetDpkgExecutable();
50 APT_HIDDEN static std::vector<std::string> GetDpkgBaseCommand();
51 APT_HIDDEN static void DpkgChrootDirectory();
b49068c5 52 APT_HIDDEN static pid_t ExecDpkg(std::vector<std::string> const &sArgs, int * const inputFd, int * const outputFd, bool const DiscardOutput);
8d6d3f00 53 APT_HIDDEN static bool SupportsMultiArch();
825db890 54 APT_HIDDEN static std::vector<std::string> SupportedArchitectures();
b2e465d6
AL
55};
56
57extern debSystem debSys;
58
59#endif