浏览代码

start working on TriggerLauncher

nico 8 年之前
父节点
当前提交
b198afb326
共有 1 个文件被更改,包括 24 次插入0 次删除
  1. 24 0
      core/TriggerLauncher.py

+ 24 - 0
core/TriggerLauncher.py

@@ -0,0 +1,24 @@
+import logging
+
+logging.basicConfig()
+logger = logging.getLogger("jarvis")
+
+
+class TriggerLauncher(object):
+    def __init__(self):
+        pass
+
+    @classmethod
+    def start_trigger(cls, trigger_name, callback, parameters=None):
+        """
+
+        :param trigger_name: Name of the trigger class to instantiate
+        :param callback: Callback function to call when the trigger
+        catch the magic word
+        :param parameters: Dict of parameter to send to the trigger
+        :return:
+        """
+        pass
+        # plugin = neuron.name.capitalize()
+        # plugin = plugin.capitalize()
+        # _run_plugin(plugin, neuron.parameters)