Exemplo n.º 1
0
 def __init__(self):
     PluginGlobals.push_env('orion')
     
     self.__window_managers = ExtensionPoint(IWindowManager)
     self.__display_servers = ExtensionPoint(IDisplayServerCommunicator)
     self.__accessibility_manager = None
     self.__conn = None
Exemplo n.º 2
0
from pyutilib.component.core import Interface, ExtensionPoint, implements, Plugin, PluginGlobals, SingletonPlugin
import pyutilib.component.loader
import threading

print "[interfaces] %s" % threading.current_thread()

PluginGlobals.push_env("microdrop.managed")
PluginGlobals.pop_env()


PluginGlobals.push_env("microdrop")


if "IFoo" in PluginGlobals.interface_registry:
    IFoo = PluginGlobals.interface_registry["IFoo"]
else:

    class IFoo(Interface):
        pass


if "ILoggingPlugin" in PluginGlobals.interface_registry:
    ILoggingPlugin = PluginGlobals.interface_registry["ILoggingPlugin"]
else:

    class ILoggingPlugin(Interface):
        def on_debug(self, record):
            pass

        def on_info(self, record):
            pass
Exemplo n.º 3
0
 def _create_environment(self):
     if Config._environment == None:
         env_name = "Bumblebee"
         Config._environment = PluginEnvironment(env_name)
         PluginGlobals.push_env(Config._environment)
Exemplo n.º 4
0
from pyutilib.component.core import Interface, PluginGlobals
import threading

print '[interfaces] %s' % threading.current_thread()

PluginGlobals.push_env('microdrop.managed')
PluginGlobals.pop_env()


PluginGlobals.push_env('microdrop')


if 'IFoo' in PluginGlobals.interface_registry:
    IFoo = PluginGlobals.interface_registry['IFoo']
else:
    class IFoo(Interface):
        pass


if 'ILoggingPlugin' in PluginGlobals.interface_registry:
    ILoggingPlugin = PluginGlobals.interface_registry['ILoggingPlugin']
else:
    class ILoggingPlugin(Interface):
        def on_debug(self, record):
            pass

        def on_info(self, record):
            pass

        def on_warning(self, record):
            pass
Exemplo n.º 5
0
#  _________________________________________________________________________
#
#  PyUtilib: A Python utility library.
#  Copyright (c) 2008 Sandia Corporation.
#  This software is distributed under the BSD License.
#  Under the terms of Contract DE-AC04-94AL85000 with Sandia Corporation,
#  the U.S. Government retains certain rights in this software.
#  _________________________________________________________________________

"""
The pyutilib.component.config package includes utilities to configure
the PyUtilib Component Architecture.  This includes facilities for using
configuration files, controlling logging, and specifying component options.
"""

from pyutilib.component.core import PluginGlobals
PluginGlobals.push_env("pca")

from pyutilib.component.config.options import *
from pyutilib.component.config.managed_plugin import *
from pyutilib.component.config.configuration import *
from pyutilib.component.config.logging_config import *
from pyutilib.component.config.env_config import *
from pyutilib.component.config.tempfiles import *
import pyutilib.component.config.plugin_ConfigParser

PluginGlobals.pop_env()
Exemplo n.º 6
0
from pyutilib.component.core import Interface, PluginGlobals
import threading

print '[interfaces] %s' % threading.current_thread()

PluginGlobals.push_env('microdrop.managed')
PluginGlobals.pop_env()


PluginGlobals.push_env('microdrop')


if 'IFoo' in PluginGlobals.interface_registry:
    IFoo = PluginGlobals.interface_registry['IFoo']
else:
    class IFoo(Interface):
        pass


if 'ILoggingPlugin' in PluginGlobals.interface_registry:
    ILoggingPlugin = PluginGlobals.interface_registry['ILoggingPlugin']
else:
    class ILoggingPlugin(Interface):
        def on_debug(self, record):
            pass

        def on_info(self, record):
            pass

        def on_warning(self, record):
            pass