From 81909cf43111e8499c583395b66e96b6b74e6ab9 Mon Sep 17 00:00:00 2001
From: Violette Roche-Montane <violette.roche-montane@forgerock.com>
Date: Fri, 21 Feb 2014 13:50:22 +0000
Subject: [PATCH] Checkpoint OPENDJ-1343 Migrate dsconfig / OPENDJ-1303 "opendj-cli" - replaced arguments by CLI sdk CommonArguments.(Basic only, riskless to conflicting arguments) - reverted modifications on InstallDS/InstallDSArgumentParser about getDirectoryManagerPassword. - removed from toolconstants 'description' / 'memberName' (unused)
---
opendj3-server-dev/src/server/org/opends/server/tools/upgrade/UpgradeCli.java | 32 ++++++++------------------------
1 files changed, 8 insertions(+), 24 deletions(-)
diff --git a/opendj3-server-dev/src/server/org/opends/server/tools/upgrade/UpgradeCli.java b/opendj3-server-dev/src/server/org/opends/server/tools/upgrade/UpgradeCli.java
index c46c65b..7220bf7 100644
--- a/opendj3-server-dev/src/server/org/opends/server/tools/upgrade/UpgradeCli.java
+++ b/opendj3-server-dev/src/server/org/opends/server/tools/upgrade/UpgradeCli.java
@@ -54,6 +54,7 @@
import com.forgerock.opendj.cli.ArgumentException;
import com.forgerock.opendj.cli.BooleanArgument;
+import com.forgerock.opendj.cli.CommonArguments;
import com.forgerock.opendj.cli.StringArgument;
import com.forgerock.opendj.cli.SubCommandArgumentParser;
import com.forgerock.opendj.cli.ClientException;
@@ -231,29 +232,15 @@
if (!globalArgumentsInitialized)
{
configClass =
- new StringArgument("configclass", OPTION_SHORT_CONFIG_CLASS,
- OPTION_LONG_CONFIG_CLASS, true, false, true,
- INFO_CONFIGCLASS_PLACEHOLDER.get(), ConfigFileHandler.class
- .getName(), null, INFO_DESCRIPTION_CONFIG_CLASS.get());
- configClass.setHidden(true);
+ CommonArguments.getConfigClass(ConfigFileHandler.class.getName());
- configFile =
- new StringArgument("configfile", 'f', "configFile", true, false,
- true, INFO_CONFIGFILE_PLACEHOLDER.get(), null, null,
- INFO_DESCRIPTION_CONFIG_FILE.get());
- configFile.setHidden(true);
+ configFile = CommonArguments.getConfigFile();
- noPrompt =
- new BooleanArgument(OPTION_LONG_NO_PROMPT, OPTION_SHORT_NO_PROMPT,
- OPTION_LONG_NO_PROMPT, INFO_UPGRADE_DESCRIPTION_NO_PROMPT.get());
+ noPrompt = CommonArguments.getNoPrompt();
- verbose =
- new BooleanArgument(OPTION_LONG_VERBOSE, OPTION_SHORT_VERBOSE,
- OPTION_LONG_VERBOSE, INFO_DESCRIPTION_VERBOSE.get());
+ verbose = CommonArguments.getVerbose();
- quietMode =
- new BooleanArgument(OPTION_LONG_QUIET, OPTION_SHORT_QUIET,
- OPTION_LONG_QUIET, INFO_DESCRIPTION_QUIET.get());
+ quietMode = CommonArguments.getQuiet();
ignoreErrors =
new BooleanArgument(OPTION_LONG_IGNORE_ERRORS, null,
@@ -264,12 +251,9 @@
OPTION_LONG_FORCE_UPGRADE,
INFO_UPGRADE_OPTION_FORCE.get(OPTION_LONG_NO_PROMPT));
- acceptLicense = new BooleanArgument(OPTION_LONG_ACCEPT_LICENSE, null,
- OPTION_LONG_ACCEPT_LICENSE, INFO_OPTION_ACCEPT_LICENSE.get());
+ acceptLicense = CommonArguments.getAcceptLicense();
- showUsageArgument =
- new BooleanArgument("help", OPTION_SHORT_HELP, OPTION_LONG_HELP,
- INFO_DESCRIPTION_USAGE.get());
+ showUsageArgument = CommonArguments.getShowUsage();
// Register the global arguments.
--
Gitblit v1.10.0