def _listAll(self): appList = self._appService.getAll() if 1 > len(appList): print('There are no registered applications.') print() usage = 'To add application, Usage:\n $ {0} {1} {2} APP_NAME --description "Application description"' setAction = IoC.resolve(SetAction) print(usage.format(setAction.app.getAppName(), setAction.name, self.name)) else: print('{0:<20} {1:<60}'.format('NAME', 'DESCRIPTION')) print('{0:-<20} {1:-<60}'.format('','')) for app in appList: print('{0:<20} {1:<60}'.format(app.Name, app.Description[:60]))
def _appService(self): if not self._appService_: self._appService_ = IoC.resolve(ApplicationService) return self._appService_
def _settingService(self): if not self._settingService_: self._settingService_ = IoC.resolve(SettingDataService) return self._settingService_
def _settingService(self): if not self._settingService_: self._settingService_ = IoC.resolve(SettingTemplateService) return self._settingService_