diff options
Diffstat (limited to 'apt/cache.py')
| -rw-r--r-- | apt/cache.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/apt/cache.py b/apt/cache.py index ff3149f5..0065d14c 100644 --- a/apt/cache.py +++ b/apt/cache.py @@ -202,6 +202,11 @@ class Cache(object): finally: os.close(lock) + def isVirtualPackage(self, pkgname): + """Return whether the package is a virtual package.""" + pkg = self._cache[pkgname] + return bool(pkg.ProvidesList and not pkg.VersionList) + def getProvidingPackages(self, virtual): """ Return a list of packages which provide the virtual package of the |
