| | |
| | | * |
| | | * |
| | | * Copyright 2006-2010 Sun Microsystems, Inc. |
| | | * Portions Copyright 2011-2014 ForgeRock AS |
| | | * Portions Copyright 2011-2015 ForgeRock AS |
| | | */ |
| | | |
| | | package org.opends.quicksetup.installer.offline; |
| | | |
| | | import org.forgerock.i18n.LocalizableMessage; |
| | |
| | | import static com.forgerock.opendj.util.OperatingSystem.isWindows; |
| | | import static com.forgerock.opendj.cli.Utils.getThrowableMsg; |
| | | |
| | | |
| | | import java.io.PrintStream; |
| | | import java.io.File; |
| | | import java.util.ArrayList; |
| | |
| | | */ |
| | | public class OfflineInstaller extends Installer |
| | | { |
| | | /* This map contains the ratio associated with each step */ |
| | | /** This map contains the ratio associated with each step. */ |
| | | private final Map<ProgressStep, Integer> hmRatio = |
| | | new HashMap<ProgressStep, Integer>(); |
| | | |
| | | /* This map contains the summary associated with each step */ |
| | | /** This map contains the summary associated with each step. */ |
| | | private final Map<ProgressStep, LocalizableMessage> hmSummary = |
| | | new HashMap<ProgressStep, LocalizableMessage>(); |
| | | |
| | |
| | | |
| | | /** |
| | | * Actually performs the install in this thread. The thread is blocked. |
| | | * |
| | | */ |
| | | @Override |
| | | public void run() |
| | |
| | | } |
| | | } |
| | | |
| | | /** |
| | | * {@inheritDoc} |
| | | */ |
| | | /** {@inheritDoc} */ |
| | | @Override |
| | | public Integer getRatio(ProgressStep status) |
| | | { |
| | | return hmRatio.get(status); |
| | | } |
| | | |
| | | /** |
| | | * {@inheritDoc} |
| | | */ |
| | | /** {@inheritDoc} */ |
| | | @Override |
| | | public LocalizableMessage getSummary(ProgressStep status) |
| | | { |
| | |
| | | hmRatio.put(InstallProgressStep.FINISHED_CANCELED, 100); |
| | | } |
| | | |
| | | /** |
| | | * {@inheritDoc} |
| | | */ |
| | | /** {@inheritDoc} */ |
| | | @Override |
| | | public String getInstallationPath() |
| | | { |
| | | return Utils.getInstallPathFromClasspath(); |
| | | } |
| | | |
| | | /** |
| | | * {@inheritDoc} |
| | | */ |
| | | /** {@inheritDoc} */ |
| | | @Override |
| | | public String getInstancePath() |
| | | { |