# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
+from ipsilon.util.log import Log
from ipsilon.util.plugin import PluginLoader, PluginObject
from ipsilon.util.plugin import PluginInstaller
from ipsilon.util.page import Page
import cherrypy
-class ProviderException(Exception):
+class ProviderException(Exception, Log):
def __init__(self, message):
super(ProviderException, self).__init__(message)
def __str__(self):
return repr(self.message)
- def _debug(self, fact):
- if cherrypy.config.get('debug', False):
- cherrypy.log('%s: %s' % (self.__class__.__name__, fact))
-
class ProviderBase(PluginObject):
self.tree = None
self.admin = None
- def _debug(self, fact):
- if cherrypy.config.get('debug', False):
- cherrypy.log(fact)
-
def get_tree(self, site):
raise NotImplementedError
FACILITY = 'provider_config'
-class LoadProviders(object):
+class LoadProviders(Log):
def __init__(self, root, site):
loader = PluginLoader(LoadProviders, FACILITY, 'IdpProvider')
plugin = providers['available'][item]
plugin.register(site)
- def _debug(self, fact):
- if cherrypy.config.get('debug', False):
- cherrypy.log(fact)
-
class ProvidersInstall(object):