Changeset 5016 for main/waeup.sirp/trunk/src/waeup
- Timestamp:
- 4 Feb 2010, 17:55:34 (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.sirp/trunk/src/waeup/sirp/app.py
r4968 r5016 4 4 from zope.app.authentication.authentication import PluggableAuthentication 5 5 from zope.app.security.interfaces import IAuthentication 6 from zope.component import createObject 6 from zope.component import createObject, getAllUtilitiesRegisteredFor 7 7 8 from waeup.sirp.interfaces import (IUniversity, IDataCenter, 9 IDataCenterStorageMovedEvent) 8 from waeup.sirp.interfaces import ( 9 IUniversity, IDataCenter, IWAeUPSIRPPluggable, 10 IDataCenterStorageMovedEvent) 10 11 from waeup.sirp.authentication import setup_authentication 11 12 from waeup.sirp.datacenter import DataCenter … … 38 39 39 40 def setup(self): 40 self['students'] = createObject(u'waeup.StudentContainer')41 self['hostels'] = createObject(u'waeup.HostelContainer')42 self['faculties'] = createObject(u'waeup.FacultyContainer')43 41 self['users'] = UserContainer() 44 42 self['datacenter'] = DataCenter() 45 43 44 self['students'] = createObject(u'waeup.StudentContainer') 45 self['hostels'] = createObject(u'waeup.HostelContainer') 46 self._createPlugins() 47 48 def _createPlugins(self): 49 """Create instances of all plugins defined somewhere. 50 """ 51 plugins = getAllUtilitiesRegisteredFor(IWAeUPSIRPPluggable) 52 for plugin in plugins: 53 self[plugin.name] = createObject(plugin.factory_name) 54 46 55 def _setupLogger(self, logger): 47 56 """Setup general application logger.
Note: See TracChangeset for help on using the changeset viewer.