summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBenjamin Schubert <ben.c.schubert@gmail.com>2019-03-21 11:13:03 +0000
committerBenjamin Schubert <ben.c.schubert@gmail.com>2019-03-21 11:14:01 +0000
commitb777180db91d2e20b92f3a475ab6539c4004edbc (patch)
tree3c2f28e0bc760adb94ae29ae258ce04e6564e427
parentf0945bb392028ffd84bc9983c28aeb4fe41b956d (diff)
downloadbuildstream-bschubert/pipeline.tar.gz
fixup! plugin.py: move the creation and handling of the plugin table in Pluginbschubert/pipeline
-rw-r--r--buildstream/plugin.py12
1 files changed, 12 insertions, 0 deletions
diff --git a/buildstream/plugin.py b/buildstream/plugin.py
index 3b4a19bb9..c139c8cb7 100644
--- a/buildstream/plugin.py
+++ b/buildstream/plugin.py
@@ -700,6 +700,18 @@ class Plugin():
# Private Methods used in BuildStream #
#############################################################
+ # _lookup():
+ #
+ # Fetch a plugin in the current process by its
+ # unique identifier
+ #
+ # Args:
+ # unique_id: The unique identifier as returned by
+ # plugin._unique_id
+ #
+ # Returns:
+ # (Plugin): The plugin for the given ID, or None
+ #
@classmethod
def _lookup(cls, unique_id):
assert unique_id in cls.__TABLE, "Could not find plugin with ID {}".format(unique_id)