/** * Parses the text for special variables. */ protected String parseText(String string_to_parse) { string_to_parse = installData.getVariables().replace(string_to_parse); return string_to_parse; }
/** * Returns the current value of the specified variable. This is short hand for * {@code getVariables().get(name)}. * * @param name the name of the variable * @return the value of the variable or null if not set * @see #setVariable */ @Override public String getVariable(String name) { return variables.get(name); }
public Debugger(GUIInstallData installdata, IconsDatabase icons, RulesEngine rules) { idata = installdata; this.rules = rules; lasttimevariables = (Properties) idata.getVariables().getProperties().clone(); this.icons = icons; this.variableshistory = new HashMap<String, VariableHistory>(); this.conditionhistory = new HashMap<String, ConditionHistory>(); this.init(); }
value = variables.replace(value); blockedVariablesList.add(variable); idata.getVariables().registerBlockedVariableNames(blockedVariablesList, panelRoot.getName());
Set<String> originalBlockedNames = installData.getVariables().getBlockedVariableNames(metadata); Set<String> addedBlockedNames = new HashSet<String>(); Set<String> removedBlockedNames = new HashSet<String>(); if (!installData.getVariables().isBlockedVariableName(blockedName)) installData.getVariables().registerBlockedVariableNames(addedBlockedNames, metadata); installData.getVariables().unregisterBlockedVariableNames(removedBlockedNames, metadata);
variables.refresh(); futurePanel.setVisited(false); Set<String> blockedNames = futurePanel.getAffectedVariableNames(); variables.unregisterBlockedVariableNames(futurePanel.getAffectedVariableNames(), futurePanel); if( logger.isLoggable(Level.FINE)) variables.registerBlockedVariableNames(blockedNames, newPanel); if( logger.isLoggable(Level.FINE)) variables.refresh();
if (!getInstallData().getVariables().isBlockedVariableName(getVariable())) result = getInstallData().getVariables().replace(format(initialValues));
logger.fine("Unblocked variables on panel '" + panel.getPanelId() +"': " + createListAsString(installData.getVariables().getBlockedVariableNames(panel))); installData.getVariables().unregisterBlockedVariableNames(installData.getVariables().getBlockedVariableNames(panel), panel); printHeadLine(installData, console); installData.getVariables().registerBlockedVariableNames(variables, panel);
installData.getVariables().registerBlockedVariableNames(newPanel.getPanel().getAffectedVariableNames(), newPanel.getPanelId()); result = executeValidationActions(newPanel, true); view.processOptions(installData, installData.getVariables().getOverrides()); installData.getVariables().registerBlockedVariableNames(newPanel.getPanel().getAffectedVariableNames(), newPanel.getPanelId()); result = executeValidationActions(newPanel, true);
/** * Refreshes dynamic variables. This is short hand for {@code getVariables().refresh()}. */ @Override public void refreshVariables() { variables.refresh(); }
/** * Determines if installation requirements are met. * * @return <tt>true</tt> if requirements are met, otherwise <tt>false</tt> */ @Override public boolean check() { variables.refresh(); return langChecker.check() && versionChecker.check() && jdkChecker.check() && lockChecker.check() && expiredChecker.check() && installerRequirementChecker.check(); } }
/** * @return the suggested program group */ public String getSuggestedProgramGroup() { return installData.getVariables().replace(suggestedProgramGroup); }
/** * Returns the uninstall name, used to initialise the {@link RegistryHandler#setUninstallName(String)}. * <p/> * This implementation returns a concatenation of the <em>APP_NAME</em> and <em>APP_VER</em> variables, * separated by a space. * * @return the uninstall name */ protected String getUninstallName() { Variables variables = getInstallData().getVariables(); return variables.get("APP_NAME") + " " + variables.get("APP_VER"); }
private void debugVariables(Panel nextpanelmetadata, Panel lastpanelmetadata) { getChangedVariables(nextpanelmetadata, lastpanelmetadata); lasttimevariables = (Properties) idata.getVariables().getProperties().clone(); }
variables.refresh(); panel.executePreValidationActions(); panel.executePostValidationActions();
/** * Parses the text for special variables. */ private void parseText() { // Parses the info text info = installData.getVariables().replace(info); }
varValue = variables.get(name);
/** * Print list of variables names and value, as well as the list * of packages and their status (selected or not). */ private void printDebugInfo() { int i = 0; String sInfo = "GUIInstallData Variables:\n"; System.out.println("------------------------Data Check Panel Instance " + instanceNumber + "------------------------"); System.out.println("GUIInstallData Variables:"); Properties varList = installDataGUI.getVariables().getProperties(); String[] alphaName = new String[varList.size()]; Enumeration<String> varNames = (Enumeration<String>) varList.propertyNames(); while (varNames.hasMoreElements()) { alphaName[i++] = varNames.nextElement(); } java.util.Arrays.sort(alphaName); for (i = 0; i < alphaName.length; i++) { sInfo = sInfo + "\tName: " + alphaName[i] + ", Value: " + varList.getProperty(alphaName[i]) + "\n"; } sInfo = sInfo + "\nAvailable Packs: \n" + getPackNames(installDataGUI.getAllPacks()) + "\n"; System.out.println(sInfo); staticText.setText(sInfo); }
/** * Translates a relative path to a local system path. * * @param destination the path to translate * @param variables used to replaces variables in the path * @return the translated path */ public static String translatePath(String destination, Variables variables) { destination = variables.replace(destination); return translatePath(destination); }