summaryrefslogtreecommitdiff
path: root/apt-pkg/edsp
diff options
context:
space:
mode:
Diffstat (limited to 'apt-pkg/edsp')
-rw-r--r--apt-pkg/edsp/edspindexfile.cc16
-rw-r--r--apt-pkg/edsp/edspindexfile.h32
-rw-r--r--apt-pkg/edsp/edsplistparser.h18
-rw-r--r--apt-pkg/edsp/edspsystem.h40
4 files changed, 53 insertions, 53 deletions
diff --git a/apt-pkg/edsp/edspindexfile.cc b/apt-pkg/edsp/edspindexfile.cc
index e97f16894..99947f4fb 100644
--- a/apt-pkg/edsp/edspindexfile.cc
+++ b/apt-pkg/edsp/edspindexfile.cc
@@ -28,7 +28,7 @@ edspLikeIndex::edspLikeIndex(std::string const &File) : pkgDebianIndexRealFile(F
}
std::string edspLikeIndex::GetArchitecture() const
{
- return std::string();
+ return {};
}
bool edspLikeIndex::HasPackages() const
{
@@ -94,10 +94,10 @@ pkgCacheListParser * eippIndex::CreateListParser(FileFd &Pkg)
class APT_HIDDEN edspIFType: public pkgIndexFile::Type
{
public:
- virtual pkgRecords::Parser *CreatePkgParser(pkgCache::PkgFileIterator const &) const APT_OVERRIDE
+ [[nodiscard]] pkgRecords::Parser *CreatePkgParser(pkgCache::PkgFileIterator const &/*PkgFile*/) const override
{
// we don't have a record parser for this type as the file is not persistent
- return NULL;
+ return nullptr;
};
edspIFType() {Label = "EDSP scenario file";};
};
@@ -110,10 +110,10 @@ const pkgIndexFile::Type *edspIndex::GetType() const
class APT_HIDDEN eippIFType: public pkgIndexFile::Type
{
public:
- virtual pkgRecords::Parser *CreatePkgParser(pkgCache::PkgFileIterator const &) const APT_OVERRIDE
+ [[nodiscard]] pkgRecords::Parser *CreatePkgParser(pkgCache::PkgFileIterator const &/*PkgFile*/) const override
{
// we don't have a record parser for this type as the file is not persistent
- return NULL;
+ return nullptr;
};
eippIFType() {Label = "EIPP scenario file";};
};
@@ -124,6 +124,6 @@ const pkgIndexFile::Type *eippIndex::GetType() const
}
/*}}}*/
-edspLikeIndex::~edspLikeIndex() {}
-edspIndex::~edspIndex() {}
-eippIndex::~eippIndex() {}
+edspLikeIndex::~edspLikeIndex() = default;
+edspIndex::~edspIndex() = default;
+eippIndex::~eippIndex() = default;
diff --git a/apt-pkg/edsp/edspindexfile.h b/apt-pkg/edsp/edspindexfile.h
index 42ef3fea3..ee1079aa4 100644
--- a/apt-pkg/edsp/edspindexfile.h
+++ b/apt-pkg/edsp/edspindexfile.h
@@ -18,42 +18,42 @@ class pkgCacheGenerator;
class APT_HIDDEN edspLikeIndex : public pkgDebianIndexRealFile
{
protected:
- virtual bool OpenListFile(FileFd &Pkg, std::string const &File) APT_OVERRIDE;
- virtual uint8_t GetIndexFlags() const APT_OVERRIDE;
- virtual std::string GetArchitecture() const APT_OVERRIDE;
+ bool OpenListFile(FileFd &Pkg, std::string const &File) override;
+ [[nodiscard]] uint8_t GetIndexFlags() const override;
+ [[nodiscard]] std::string GetArchitecture() const override;
-public:
- virtual bool Exists() const APT_OVERRIDE;
- virtual bool HasPackages() const APT_OVERRIDE;
+ public:
+ [[nodiscard]] bool Exists() const override;
+ [[nodiscard]] bool HasPackages() const override;
explicit edspLikeIndex(std::string const &File);
- virtual ~edspLikeIndex();
+ ~edspLikeIndex() override;
};
class APT_HIDDEN edspIndex : public edspLikeIndex
{
protected:
- APT_HIDDEN virtual pkgCacheListParser * CreateListParser(FileFd &Pkg) APT_OVERRIDE;
- virtual std::string GetComponent() const APT_OVERRIDE;
+ APT_HIDDEN pkgCacheListParser *CreateListParser(FileFd &Pkg) override;
+ [[nodiscard]] std::string GetComponent() const override;
public:
- virtual const Type *GetType() const APT_OVERRIDE APT_PURE;
+ [[nodiscard]] const Type *GetType() const override APT_PURE;
explicit edspIndex(std::string const &File);
- virtual ~edspIndex();
+ ~edspIndex() override;
};
class APT_HIDDEN eippIndex : public edspLikeIndex
{
protected:
- APT_HIDDEN virtual pkgCacheListParser * CreateListParser(FileFd &Pkg) APT_OVERRIDE;
- virtual std::string GetComponent() const APT_OVERRIDE;
+ APT_HIDDEN pkgCacheListParser *CreateListParser(FileFd &Pkg) override;
+ [[nodiscard]] std::string GetComponent() const override;
-public:
- virtual const Type *GetType() const APT_OVERRIDE APT_PURE;
+ public:
+ [[nodiscard]] const Type *GetType() const override APT_PURE;
explicit eippIndex(std::string const &File);
- virtual ~eippIndex();
+ ~eippIndex() override;
};
#endif
diff --git a/apt-pkg/edsp/edsplistparser.h b/apt-pkg/edsp/edsplistparser.h
index 3f0f3e64c..a7ad9830c 100644
--- a/apt-pkg/edsp/edsplistparser.h
+++ b/apt-pkg/edsp/edsplistparser.h
@@ -21,13 +21,13 @@
class APT_HIDDEN edspLikeListParser : public debListParser
{
public:
- virtual bool NewVersion(pkgCache::VerIterator &Ver) APT_OVERRIDE;
- virtual std::vector<std::string> AvailableDescriptionLanguages() APT_OVERRIDE;
- virtual std::string_view Description_md5() APT_OVERRIDE;
- virtual uint32_t VersionHash() APT_OVERRIDE;
+ bool NewVersion(pkgCache::VerIterator &Ver) override;
+ std::vector<std::string> AvailableDescriptionLanguages() override;
+ std::string_view Description_md5() override;
+ uint32_t VersionHash() override;
explicit edspLikeListParser(FileFd *File);
- virtual ~edspLikeListParser();
+ ~edspLikeListParser() override;
};
class APT_HIDDEN edspListParser : public edspLikeListParser
@@ -36,20 +36,20 @@ class APT_HIDDEN edspListParser : public edspLikeListParser
FileFd preferences;
protected:
- virtual bool ParseStatus(pkgCache::PkgIterator &Pkg,pkgCache::VerIterator &Ver) APT_OVERRIDE;
+ bool ParseStatus(pkgCache::PkgIterator &Pkg, pkgCache::VerIterator &Ver) override;
public:
explicit edspListParser(FileFd *File);
- virtual ~edspListParser();
+ ~edspListParser() override;
};
class APT_HIDDEN eippListParser : public edspLikeListParser
{
protected:
- virtual bool ParseStatus(pkgCache::PkgIterator &Pkg,pkgCache::VerIterator &Ver) APT_OVERRIDE;
+ bool ParseStatus(pkgCache::PkgIterator &Pkg,pkgCache::VerIterator &Ver) override;
public:
explicit eippListParser(FileFd *File);
- virtual ~eippListParser();
+ ~eippListParser() override;
};
#endif
diff --git a/apt-pkg/edsp/edspsystem.h b/apt-pkg/edsp/edspsystem.h
index 97c2d66e2..e34c4ecce 100644
--- a/apt-pkg/edsp/edspsystem.h
+++ b/apt-pkg/edsp/edspsystem.h
@@ -29,24 +29,24 @@ protected:
std::unique_ptr<pkgIndexFile> StatusFile;
public:
- virtual bool Lock(OpProgress * const Progress) APT_OVERRIDE APT_PURE;
- virtual bool UnLock(bool NoErrors = false) APT_OVERRIDE APT_PURE;
- virtual pkgPackageManager *CreatePM(pkgDepCache *Cache) const APT_OVERRIDE APT_PURE;
- virtual bool Initialize(Configuration &Cnf) APT_OVERRIDE;
- virtual bool ArchiveSupported(const char *Type) APT_OVERRIDE APT_PURE;
- virtual signed Score(Configuration const &Cnf) APT_OVERRIDE;
- virtual bool FindIndex(pkgCache::PkgFileIterator File,
- pkgIndexFile *&Found) const APT_OVERRIDE;
-
- bool MultiArchSupported() const override { return true; }
- std::vector<std::string> ArchitecturesSupported() const override { return {}; };
-
- bool LockInner(OpProgress * const, int) override { return _error->Error("LockInner is not implemented"); };
- bool UnLockInner(bool) override { return _error->Error("UnLockInner is not implemented"); };
+ bool Lock(OpProgress *Progress) override APT_PURE;
+ bool UnLock(bool NoErrors = false) override APT_PURE;
+ pkgPackageManager *CreatePM(pkgDepCache *Cache) const override APT_PURE;
+ bool Initialize(Configuration &Cnf) override;
+ bool ArchiveSupported(const char *Type) override APT_PURE;
+ signed Score(Configuration const &Cnf) override;
+ bool FindIndex(pkgCache::PkgFileIterator File,
+ pkgIndexFile *&Found) const override;
+
+ [[nodiscard]] bool MultiArchSupported() const override { return true; }
+ [[nodiscard]] std::vector<std::string> ArchitecturesSupported() const override { return {}; };
+
+ bool LockInner(OpProgress * const /*Progress*/, int /*timeOutSec*/) override { return _error->Error("LockInner is not implemented"); };
+ bool UnLockInner(bool /*NoErrors*/) override { return _error->Error("UnLockInner is not implemented"); };
bool IsLocked() override { return true; };
explicit edspLikeSystem(char const * const Label);
- virtual ~edspLikeSystem();
+ ~edspLikeSystem() override;
};
class APT_HIDDEN edspSystem : public edspLikeSystem
@@ -56,20 +56,20 @@ class APT_HIDDEN edspSystem : public edspLikeSystem
std::string tempPrefsFile;
public:
- virtual bool Initialize(Configuration &Cnf) APT_OVERRIDE;
- virtual bool AddStatusFiles(std::vector<pkgIndexFile *> &List) APT_OVERRIDE;
+ bool Initialize(Configuration &Cnf) override;
+ bool AddStatusFiles(std::vector<pkgIndexFile *> &List) override;
edspSystem();
- virtual ~edspSystem();
+ ~edspSystem() override;
};
class APT_HIDDEN eippSystem : public edspLikeSystem
{
public:
- virtual bool AddStatusFiles(std::vector<pkgIndexFile *> &List) APT_OVERRIDE;
+ bool AddStatusFiles(std::vector<pkgIndexFile *> &List) override;
eippSystem();
- virtual ~eippSystem();
+ ~eippSystem() override;
};
#endif