Exemplo n.º 1
0
 def start(self):
     logger.debug("start ConfigHandler with configfile %s",
                  DOORPI.arguments.config_file)
     DOORPI.register_module(__name__, self.start, self.stop)
     self._config_object = self.load_config_from_configfile(
         DOORPI.arguments.config_file)
     return self
Exemplo n.º 2
0
# -*- coding: utf-8 -*-

from main import DOORPI
logger = DOORPI.register_module(__name__, return_new_logger=True)

from plugins.interfaces.hardware import HardwareInterfaceBaseClass


class FileSystemBasedInterface(HardwareInterfaceBaseClass):
    def __init__(self):
        pass

    def start(self, interface_id, config):
        logger.debug('[%s] start interface %s (type: %s)', interface_id,
                     config['name'], config['type'])

    def stop(self):
        pass


__interface__ = FileSystemBasedInterface()
Exemplo n.º 3
0
 def __init__(self):
     DOORPI.register_module(__name__, self.start, self.stop, False)