summaryrefslogtreecommitdiff
path: root/apt
diff options
context:
space:
mode:
authorJulian Andres Klode <jak@debian.org>2009-08-24 15:38:41 +0200
committerJulian Andres Klode <jak@debian.org>2009-08-24 15:38:41 +0200
commit0fcb7e9ad1ec729a08d93b133dda7d5df37a3fd8 (patch)
treec0ea1243b07ce9ea17ec3d622dc9aada8ef03680 /apt
parent4fcfe8b00e52a21c2144877fb631a70d6c75fd19 (diff)
parent545fcd342c772168c0f8ee27c82fde6052efd7a0 (diff)
downloadpython-apt-0fcb7e9ad1ec729a08d93b133dda7d5df37a3fd8.tar.gz
* apt/cache.py:
- add actiongroup() method (backport from 0.7.92)
Diffstat (limited to 'apt')
-rw-r--r--apt/cache.py9
1 files changed, 9 insertions, 0 deletions
diff --git a/apt/cache.py b/apt/cache.py
index 446cfae7..828b167b 100644
--- a/apt/cache.py
+++ b/apt/cache.py
@@ -335,6 +335,15 @@ class Cache(object):
a signal then """
self._runCallbacks("cache_pre_change")
+ def actiongroup(self):
+ """Return an ActionGroup() object for the current cache.
+
+ Action groups can be used to speedup actions. The action group is
+ active as soon as it is created, and disabled when the object is
+ deleted or when release() is called.
+ """
+ return apt_pkg.GetPkgActionGroup(self._depcache)
+
def connect(self, name, callback):
""" connect to a signal, currently only used for
cache_{post,pre}_{changed,open} """