public AbstractTransactionService(InitParams params) { if (params != null && params.getValueParam("timeout") != null) { this.defaultTimeout = Integer.parseInt(params.getValueParam("timeout").getValue()); this.forceTimeout = true; } else { this.defaultTimeout = DEFAULT_TIME_OUT; this.forceTimeout = false; } }
public PopulateGadgetRegisryService(GadgetRegistryService gadgetRegistryService, ApplicationRegistryService applicationRegistryService, InitParams initParams) { categoryName = initParams.getValueParam("gadgetsCategoryName").getValue(); if (categoryName == null) { categoryName = DEFAULT_GADGETS_CATEGORY_NAME; LOG.warn("Failed to retrieve " + initParams.getValueParam("gadgetsCategoryName").getName() + " init param. Default category name will be used: " + DEFAULT_GADGETS_CATEGORY_NAME); } gadgetsCategoryAccessPermission = initParams.getValueParam("gadgetsCategoryAccessPermission").getValue(); if (gadgetsCategoryAccessPermission == null) { gadgetsCategoryAccessPermission = UserACL.EVERYONE; LOG.warn("Failed to retrieve " + initParams.getValueParam("gadgetsCategoryAccessPermission").getName() + " init param. Default access permission will be used: " + UserACL.EVERYONE); } gadgets = initParams.getObjectParamValues(Gadget.class); this.gadgetRegistryService = gadgetRegistryService; this.applicationRegistryService = applicationRegistryService; }
public ChromatticLifeCycle(InitParams params) { Map<String, String> options = new HashMap<String, String>(); PropertiesParam pp = params.getPropertiesParam("options"); if (pp != null) { options.putAll(pp.getProperties()); } this.domainName = params.getValueParam("domain-name").getValue(); this.workspaceName = params.getValueParam("workspace-name").getValue(); this.entityClassNames = params.getValuesParam("entities").getValues(); this.optionMap = options; }
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 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."); } }
/** * Default constructor */ public DistributedCacheManager(InitParams params, ConfigurationManager configManager, TransactionService ts) { ValueParam vp; final String result; if (params != null && (vp = params.getValueParam(CONFIG_FILE_PARAMETER_NAME)) != null && (result = vp.getValue()) != null && !result.isEmpty()) { PropertiesParam pp = params.getPropertiesParam(PARAMS_PARAMETER_NAME); this.manager = init(result, pp == null ? null : pp.getProperties(), configManager, ts == null ? null : ts.getTransactionManager()); } else { throw new IllegalArgumentException("The parameter '" + CONFIG_FILE_PARAMETER_NAME + "' must be set"); } }
if (params != null) ValueParam param = params.getValueParam(PARAM_CHECK_TX); if (param != null) param = params.getValueParam(PARAM_ALWAYS_MANAGED); if (param != null && Boolean.valueOf(param.getValue())) return; ValuesParam vp = params.getValuesParam(PARAM_MANAGED_DS); if (vp != null && vp.getValues() != null)
public UnlockService(ProductInformations productInformations, PingBackService pingBackService, InitParams params) throws MissingProductInformationException { this.productInformations = productInformations; this.pingBackService = pingBackService; registrationFormUrl = ((ValueParam) params.get("registrationFormUrl")).getValue(); defaultPingBackUrl = ((ValueParam) params.get("defaultPingBackUrl")).getValue(); extendFormUrl = ((ValueParam) params.get("extendFormUrl")).getValue(); subscriptionUrl = ((ValueParam) params.get("subscriptionUrl")).getValue(); keyContent = ((ValueParam) params.get("KeyContent")).getValue().trim(); String tmpValue = ((ValueParam) params.get("delayPeriod")).getValue(); delayPeriod = (tmpValue == null || tmpValue.isEmpty()) ? Utils.DEFAULT_DELAY_PERIOD : Integer.parseInt(tmpValue); String licensePath = params.getValueParam("exo.license.path").getValue(); Utils.HOME_CONFIG_LOCATION = Utils.EXO_HOME_FOLDER + "/" + Utils.PRODUCT_NAME; Utils.HOME_CONFIG_FILE_LOCATION = Utils.HOME_CONFIG_LOCATION + "/" + Utils.LICENSE_FILE; if(StringUtils.isNotBlank(licensePath) && !StringUtils.equals(licensePath, Utils.HOME_CONFIG_FILE_LOCATION)) { checkCustomizeFolder(licensePath); } }
(LDAPAttributeMapping)params.getObjectParam("ldap.attribute.mapping").getObject(); membershipTypeDAO_ = new MembershipTypeDAOImpl(ldapAttrMapping, ldapService, cacheHandler); ValueParam param = params.getValueParam("ldap.userDN.key"); if (param != null) ldapAttrMapping.userDNKey = param.getValue(); param = params.getValueParam("ldap.groupDN.key"); if (param != null) ldapAttrMapping.groupDNKey = param.getValue();
ValueParam locationParam = initParams.getValueParam("storedLocation"); String storedLocation = locationParam.getValue(); ValueParam param = initParams.getValueParam("autoCreateInNewRepository"); boolean autoCreateInNewRepository = false; if (param != null) { Iterator<?> iter = initParams.getObjectParamIterator(); while (iter.hasNext()) { Object object = ((ObjectParameter) iter.next()).getObject(); ValueParam valueParam = initParams.getValueParam("repository"); String repository = valueParam != null ? valueParam.getValue() : repositoryService.getCurrentRepository() .getConfiguration().getName();
FileNotFoundException, XMLStreamException for (Iterator propsParams = params.getPropertiesParamIterator(); propsParams.hasNext();) ValueParam bindingStorePathParam = params.getValueParam(BINDINGS_STORE_PATH); ValueParam overloadContextFactoryParam = params.getValueParam(OVERLOAD_CONTEXT_FACTORY); if (overloadContextFactoryParam != null && overloadContextFactoryParam.getValue() != null && Boolean.valueOf(overloadContextFactoryParam.getValue()))
@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); } }
public HelpServiceImpl(InitParams params) { if (params == null) { throw new IllegalStateException("given params are null in helpService"); } this.props = params.getPropertiesParam("help.pages"); if (props == null) { throw new IllegalStateException("params.getPropertiesParam() returns null in helpService"); } }
public DataPlugin(OrganizationService organizationService, InitParams params) throws Exception { config = (OrganizationConfig) params.getObjectParamValues(OrganizationConfig.class).get(0); this.organizationService = organizationService; }
public UserNavigationHandlerServiceImpl(InitParams initParams) { userNavigationuri = initParams.getValuesParam("user.navigation.uri").getValues(); }
/** * The default constructor of the plugin * @param params the init parameter from which we extract the * object parameter <i>actions</i> that contains the * {@link ActionConfiguration} objects */ public AddActionsPlugin(InitParams params) { ObjectParameter param = params.getObjectParam("actions"); if (param != null) { actionsConfig = (ActionsConfig)param.getObject(); } }
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); } } }
ValueParam bnParam = params.getValueParam("bind-name"); if (bnParam == null) ValueParam cnParam = params.getValueParam("class-name"); if (cnParam == null) ValueParam factoryParam = params.getValueParam("factory"); if (factoryParam == null) ValueParam flParam = params.getValueParam("factory-location"); String factoryLocation; if (flParam != null) reference = new Reference(cnParam.getValue(), factoryParam.getValue(), factoryLocation); PropertiesParam addrsParam = params.getPropertiesParam("ref-addresses"); if (addrsParam != null)
this.txService = txService; this.portalContainer = portalContainer; ValueParam workspaceValueParam = initParams.getValueParam("workspace"); if (workspaceValueParam != null) { workspaceName = workspaceValueParam.getValue(); workspaceName = DEFAULT_WORKSPACE_NAME; ValueParam pathParam = initParams.getValueParam("path"); if (pathParam != null) { jcrRootPath = pathParam.getValue(); ValuesParam mixinsValueParam = initParams.getValuesParam("mixinsCleanup.includes"); if (mixinsValueParam != null) { List<String> mixins = mixinsValueParam.getValues(); LOG.warn("No mixins to cleanup, the mixins list is empty."); ValueParam maxNodesParam = initParams.getValueParam("mixinsCleanup.maxNodes"); if (maxNodesParam != null) { try { ValuesParam mixinsExceptionsValueParam = initParams.getValuesParam("mixinsCleanup.excludes"); if (mixinsExceptionsValueParam != null) { List<String> mixins = mixinsExceptionsValueParam.getValues();