X-Git-Url: https://git.saurik.com/apt.git/blobdiff_plain/b49068c566d749130e023536d54588c948c16edf..51818f26c784bb574dafc545e8ae320845e5e8fc:/apt-pkg/statechanges.h diff --git a/apt-pkg/statechanges.h b/apt-pkg/statechanges.h index fa60c5864..1eaf21a3a 100644 --- a/apt-pkg/statechanges.h +++ b/apt-pkg/statechanges.h @@ -14,14 +14,20 @@ class APT_PUBLIC StateChanges { public: // getter/setter for the different states - APT::VersionVector& Hold(); - void Hold(pkgCache::VerIterator const &Ver); - APT::VersionVector& Unhold(); - void Unhold(pkgCache::VerIterator const &Ver); +#define APT_GETTERSETTER(Name) \ + APT::VersionVector& Name(); \ + void Name(pkgCache::VerIterator const &Ver) + APT_GETTERSETTER(Hold); + APT_GETTERSETTER(Unhold); + APT_GETTERSETTER(Install); + APT_GETTERSETTER(Remove); + APT_GETTERSETTER(Purge); APT::VersionVector& Error(); +#undef APT_GETTERSETTER - // forgets all unsaved changes - void Discard(); + // operate on all containers at once + void clear(); + bool empty() const; /** commit the staged changes to the database(s). *