def __call__(self): sm = zapi.getSiteManager() result = ('zapi.getSiteManager() is zapi.getGlobalSiteManager(): %s\n' 'IFiveUtilityRegistry.providedBy(utility_service): %s\n' 'isinstance(zapi.getSiteManager(), FiveSiteManager): %s' % (sm is zapi.getGlobalSiteManager(), IFiveUtilityRegistry.providedBy( sm.utilities), isinstance(sm, FiveSiteManager))) return result
def __call__(self): sm = zapi.getSiteManager() result = ('zapi.getSiteManager() is zapi.getGlobalSiteManager(): %s\n' 'IFiveUtilityRegistry.providedBy(utility_service): %s\n' 'isinstance(zapi.getSiteManager(), FiveSiteManager): %s' % (sm is zapi.getGlobalSiteManager(), IFiveUtilityRegistry.providedBy(sm.utilities), isinstance(sm, FiveSiteManager))) return result
def __call__(self): sm = zapi.getSiteManager() result = { 'zapi.getSiteManager() is zapi.getGlobalSiteManager()': sm is zapi.getGlobalSiteManager(), 'IFiveUtilityRegistry.providedBy(utility_service)': IFiveUtilityRegistry.providedBy(sm.utilities), 'isinstance(zapi.getSiteManager(), FiveSiteManager)': isinstance(sm, FiveSiteManager), } return pprint.pformat(result)
def utilities(self): return IFiveUtilityRegistry(self.context)