public MenuConfiguratorService(InitParams initParams, ConfigurationManager configurationManager) { this.configurationManager = configurationManager; if (initParams.containsKey("setup.navigation.file")) { setupNavigationFilePath = initParams.getValueParam("setup.navigation.file").getValue(); } else { throw new IllegalStateException("Init param 'setup.navigation.file' have to be set."); } }
public MenuConfiguratorRemoveNodePlugin(MenuConfiguratorService menuConfiguratorService, InitParams initParams) { this.menuConfiguratorService = menuConfiguratorService; if (initParams.containsKey(TARGET_NODE)) { targetNode = (PageNode) initParams.getObjectParam(TARGET_NODE).getObject(); } }
public MenuConfiguratorAddNodePlugin(InitParams initParams, ConfigurationManager configurationManager, MenuConfiguratorService menuConfiguratorService) { this.configurationManager = configurationManager; this.menuConfiguratorService = menuConfiguratorService; if (initParams.containsKey(EXTENDED_SETUP_NAVIGATION_FILE)) { navPath = initParams.getValueParam(EXTENDED_SETUP_NAVIGATION_FILE).getValue(); } if (initParams.containsKey(TARGET_NODE_CONFIG)) { targetNav = (PageNode) initParams.getObjectParam(TARGET_NODE_CONFIG).getObject(); } if (initParams.containsKey(IS_CHILD)) { isChild = initParams.getValueParam(IS_CHILD).getValue(); } }
public IDMQueueServiceImpl(IDMQueueDAO queueDAO, SettingService settingService, InitParams params) { this.settingService = settingService; this.queueDAO = queueDAO; if (params != null && params.containsKey(IDM_QUEUE_PROCESSING_MAX_RETRIES)) { String maxRetriesString = params.getValueParam(IDM_QUEUE_PROCESSING_MAX_RETRIES).getValue(); try { maxRetries = Integer.parseInt(maxRetriesString); } catch (NumberFormatException e) { LOG.warn("Unable to parse max retries " + maxRetriesString + ". Default value " + DEFAULT_MAX_RETRIES + " will be used", e); } } }
public DisableUserUpgradePlugin(OrganizationService service, InitParams initParams) { super(initParams); if (initParams.containsKey(THREAD_CONFIG)) { int tn = threadNum; try { tn = Integer.parseInt(initParams.getValueParam(THREAD_CONFIG).getValue()); } catch (Exception ex) { } if (tn > 0) { threadNum = tn; } } if (initParams.containsKey(BATCH_CONFIG)) { int b = threadNum; try { b = Integer.parseInt(initParams.getValueParam(BATCH_CONFIG).getValue()); } catch (Exception ex) { } if (b > 0) { batchSize = b; } } this.service = service; }
@SuppressWarnings("unchecked") public ModuleRegistry(InitParams initParams) { if (initParams.containsKey("portlets.managed.by.profile")) { portletsManagedByProfile = initParams.getValuesParam("portlets.managed.by.profile").getValues(); } else { portletsManagedByProfile = new ArrayList<String>(); } Iterator<Module> iterator = initParams.getObjectParamValues(Module.class).iterator(); while (iterator.hasNext()) { Module module = iterator.next(); if (LOG.isDebugEnabled()) { LOG.debug(module.toString()); } modulesByName.put(module.getName(), module); } }
if (initParams.containsKey("workspace")) { Util.WORKSPACE = initParams.getValueParam("workspace").getValue(); } else { LOG.warn("'workspace' init param is empty, use default value: " + Util.WORKSPACE); if (initParams.containsKey("synchronizeGroups")) { synchronizeGroups = Boolean.parseBoolean(initParams.getValueParam("synchronizeGroups").getValue()); } else { LOG.warn("'synchronizeGroups' init param is empty, use default value: false"); if (initParams.containsKey("homePath")) { Util.HOME_PATH = initParams.getValueParam("homePath").getValue(); } else {