mirror of https://github.com/OpenIdentityPlatform/OpenDJ.git

lutoff
27.12.2007 9152abd295ad89928460be58312d123861a518b5
rename dsservice to dsframework
8 files renamed
2 files modified
111 ■■■■ changed files
opendj-sdk/opends/resource/bin/dsframework 4 ●●●● patch | view | raw | blame | history
opendj-sdk/opends/resource/bin/dsframework.bat 4 ●●●● patch | view | raw | blame | history
opendj-sdk/opends/src/server/org/opends/server/admin/client/cli/DsFrameworkCliAds.java 4 ●●●● patch | view | raw | blame | history
opendj-sdk/opends/src/server/org/opends/server/admin/client/cli/DsFrameworkCliMain.java 31 ●●●● patch | view | raw | blame | history
opendj-sdk/opends/src/server/org/opends/server/admin/client/cli/DsFrameworkCliParser.java 20 ●●●● patch | view | raw | blame | history
opendj-sdk/opends/src/server/org/opends/server/admin/client/cli/DsFrameworkCliReturnCode.java 4 ●●●● patch | view | raw | blame | history
opendj-sdk/opends/src/server/org/opends/server/admin/client/cli/DsFrameworkCliServerGroup.java 4 ●●●● patch | view | raw | blame | history
opendj-sdk/opends/src/server/org/opends/server/admin/client/cli/DsFrameworkCliSubCommandGroup.java 4 ●●●● patch | view | raw | blame | history
opendj-sdk/opends/tests/unit-tests-testng/src/server/org/opends/server/admin/client/cli/CliTest.java 6 ●●●● patch | view | raw | blame | history
opendj-sdk/opends/tests/unit-tests-testng/src/server/org/opends/server/admin/client/cli/DsserviceTestCase.java 30 ●●●● patch | view | raw | blame | history
opendj-sdk/opends/resource/bin/dsframework
File was renamed from opendj-sdk/opends/resource/bin/dsservice
@@ -28,10 +28,10 @@
# This script may be used to perform LDAP add, delete, modify, and modify DN
# operations.
OPENDS_INVOKE_CLASS="org.opends.server.admin.client.cli.DsServiceCliMain"
OPENDS_INVOKE_CLASS="org.opends.server.admin.client.cli.DsFrameworkCliMain"
export OPENDS_INVOKE_CLASS
SCRIPT_NAME_ARG="-Dorg.opends.server.scriptName=dsservice"
SCRIPT_NAME_ARG="-Dorg.opends.server.scriptName=dsframework"
export SCRIPT_NAME_ARG
SCRIPT_DIR=`dirname "${0}"`
opendj-sdk/opends/resource/bin/dsframework.bat
File was renamed from opendj-sdk/opends/resource/bin/dsservice.bat
@@ -27,7 +27,7 @@
setlocal
set OPENDS_INVOKE_CLASS="org.opends.server.admin.client.cli.DsServiceCliMain"
set SCRIPT_NAME_ARG="-Dorg.opends.server.scriptName=dsservice"
set OPENDS_INVOKE_CLASS="org.opends.server.admin.client.cli.DsFrameworkCliMain"
set SCRIPT_NAME_ARG="-Dorg.opends.server.scriptName=dsframework"
call "%~dP0\..\lib\_client-script.bat" %*
opendj-sdk/opends/src/server/org/opends/server/admin/client/cli/DsFrameworkCliAds.java
File was renamed from opendj-sdk/opends/src/server/org/opends/server/admin/client/cli/DsServiceCliAds.java
@@ -36,7 +36,7 @@
import org.opends.admin.ads.ADSContext;
import org.opends.admin.ads.ADSContextException;
import org.opends.admin.ads.ADSContextHelper;
import org.opends.server.admin.client.cli.DsServiceCliReturnCode.ReturnCode;
import org.opends.server.admin.client.cli.DsFrameworkCliReturnCode.ReturnCode;
import org.opends.server.util.args.ArgumentException;
import org.opends.server.util.args.BooleanArgument;
import org.opends.server.util.args.SubCommand;
@@ -45,7 +45,7 @@
/**
 * This class is handling server group CLI.
 */
public class DsServiceCliAds implements DsServiceCliSubCommandGroup
public class DsFrameworkCliAds implements DsFrameworkCliSubCommandGroup
{
  /**
   * The enumeration containing the different subCommand names.
opendj-sdk/opends/src/server/org/opends/server/admin/client/cli/DsFrameworkCliMain.java
File was renamed from opendj-sdk/opends/src/server/org/opends/server/admin/client/cli/DsServiceCliMain.java
@@ -41,7 +41,7 @@
import org.opends.server.types.NullOutputStream;
import org.opends.server.util.args.ArgumentException;
import static org.opends.server.admin.client.cli.DsServiceCliReturnCode.*;
import static org.opends.server.admin.client.cli.DsFrameworkCliReturnCode.*;
import static org.opends.server.messages.MessageHandler.*;
import static org.opends.server.messages.AdminMessages.*;
import static org.opends.server.messages.ToolMessages.*;
@@ -50,15 +50,16 @@
/**
 * This class provides a tool that can be used to Directory Server services.
 * This class provides a tool that can be used to Directory Server framework
 * services.
 */
public class DsServiceCliMain
public class DsFrameworkCliMain
{
  /**
   * The fully-qualified name of this class.
   */
  private static final String CLASS_NAME =
      "org.opends.server.admin.client.cli.DsServiceCliMain";
      "org.opends.server.admin.client.cli.DsFrameworkCliMain";
  // The print stream to use for standard error.
  private PrintStream err;
@@ -69,19 +70,19 @@
  /**
   * Constructor for the DsServiceCLI object.
   * Constructor for the DsFrameworkCLI object.
   *
   * @param  out            The print stream to use for standard output.
   * @param  err            The print stream to use for standard error.
   */
  public DsServiceCliMain(PrintStream out, PrintStream err)
  public DsFrameworkCliMain(PrintStream out, PrintStream err)
  {
    this.out           = out;
    this.err           = err;
  }
  /**
   * The main method for dsservice tool.
   * The main method for dsframework tool.
   *
   * @param  args  The command-line arguments provided to this program.
   */
@@ -98,7 +99,7 @@
  /**
   * Parses the provided command-line arguments and uses that information to
   * run the dsservice tool.
   * run the dsframework tool.
   *
   * @param  args  The command-line arguments provided to this program.
   *
@@ -112,7 +113,7 @@
  /**
   * Parses the provided command-line arguments and uses that information to
   * run the dsservice tool.
   * run the dsframework tool.
   *
   * @param  args              The command-line arguments provided to this
   *                           program.
@@ -149,13 +150,13 @@
      err = new PrintStream(errStream);
    }
    DsServiceCliMain dsServiceCli = new DsServiceCliMain(out, err);
    return dsServiceCli.execute(args,initializeServer);
    DsFrameworkCliMain dsFrameworkCli = new DsFrameworkCliMain(out, err);
    return dsFrameworkCli.execute(args,initializeServer);
  }
  /**
   * Parses the provided command-line arguments and uses that information to
   * run the dsservice tool.
   * run the dsframework tool.
   *
   * @param  args              The command-line arguments provided to this
   *                           program.
@@ -167,11 +168,11 @@
  {
    // Create the command-line argument parser for use with this
    // program.
    DsServiceCliParser argParser ;
    DsFrameworkCliParser argParser ;
    try
    {
      String toolDescription = getMessage(MSGID_ADMIN_TOOL_DESCRIPTION);
      argParser = new DsServiceCliParser(CLASS_NAME,
      argParser = new DsFrameworkCliParser(CLASS_NAME,
          toolDescription, false);
      argParser.initializeParser(out);
    }
@@ -322,7 +323,7 @@
    catch (ADSContextException e)
    {
      adsException = e;
      returnCode = DsServiceCliReturnCode.getReturncodeFromAdsError(e
      returnCode = DsFrameworkCliReturnCode.getReturncodeFromAdsError(e
          .getError());
      if (returnCode == null)
      {
opendj-sdk/opends/src/server/org/opends/server/admin/client/cli/DsFrameworkCliParser.java
File was renamed from opendj-sdk/opends/src/server/org/opends/server/admin/client/cli/DsServiceCliParser.java
@@ -51,7 +51,7 @@
import org.opends.admin.ads.ADSContextException;
import org.opends.admin.ads.util.ApplicationKeyManager;
import org.opends.admin.ads.util.ApplicationTrustManager;
import org.opends.server.admin.client.cli.DsServiceCliReturnCode.ReturnCode;
import org.opends.server.admin.client.cli.DsFrameworkCliReturnCode.ReturnCode;
import org.opends.server.loggers.debug.DebugTracer;
import org.opends.server.types.DebugLogLevel;
import org.opends.server.util.PasswordReader;
@@ -68,7 +68,7 @@
/**
 * This class will parser CLI arguments.
 */
public class DsServiceCliParser extends SubCommandArgumentParser
public class DsFrameworkCliParser extends SubCommandArgumentParser
{
  /**
   * The tracer object for the debug logger.
@@ -164,12 +164,12 @@
   * The Logger.
   */
  static private final Logger LOG =
    Logger.getLogger(DsServiceCliParser.class.getName());
    Logger.getLogger(DsFrameworkCliParser.class.getName());
  /**
   * The diferent CLI group.
   */
  public HashSet<DsServiceCliSubCommandGroup> cliGroup;
  public HashSet<DsFrameworkCliSubCommandGroup> cliGroup;
@@ -188,11 +188,11 @@
   *          Indicates whether subcommand and long argument names
   *          should be treated in a case-sensitive manner.
   */
  public DsServiceCliParser(String mainClassName, String toolDescription,
  public DsFrameworkCliParser(String mainClassName, String toolDescription,
      boolean longArgumentsCaseSensitive)
  {
    super(mainClassName, toolDescription, longArgumentsCaseSensitive);
    cliGroup = new HashSet<DsServiceCliSubCommandGroup>();
    cliGroup = new HashSet<DsFrameworkCliSubCommandGroup>();
  }
  /**
@@ -212,13 +212,13 @@
    initializeGlobalOption(outStream);
    // ads  Group cli
    cliGroup.add(new DsServiceCliAds());
    cliGroup.add(new DsFrameworkCliAds());
    // Server Group cli
    cliGroup.add(new DsServiceCliServerGroup());
    cliGroup.add(new DsFrameworkCliServerGroup());
    // Initialization
    for (DsServiceCliSubCommandGroup oneCli : cliGroup)
    for (DsFrameworkCliSubCommandGroup oneCli : cliGroup)
    {
      oneCli.initializeCliGroup(this, verboseArg);
    }
@@ -467,7 +467,7 @@
  {
    SubCommand subCmd = getSubCommand();
    for (DsServiceCliSubCommandGroup oneCli : cliGroup)
    for (DsFrameworkCliSubCommandGroup oneCli : cliGroup)
    {
      if (oneCli.isSubCommand(subCmd))
      {
opendj-sdk/opends/src/server/org/opends/server/admin/client/cli/DsFrameworkCliReturnCode.java
File was renamed from opendj-sdk/opends/src/server/org/opends/server/admin/client/cli/DsServiceCliReturnCode.java
@@ -36,7 +36,7 @@
/**
 * This class is handling server group CLI.
 */
public final class DsServiceCliReturnCode
public final class DsFrameworkCliReturnCode
{
  /**
   *
@@ -185,7 +185,7 @@
  private static boolean initialized = false ;
  // Prevent instantiation.
  private void DsServiceCliReturnCode()
  private void DsFrameworkCliReturnCode()
  {
    // Do nothing.
  }
opendj-sdk/opends/src/server/org/opends/server/admin/client/cli/DsFrameworkCliServerGroup.java
File was renamed from opendj-sdk/opends/src/server/org/opends/server/admin/client/cli/DsServiceCliServerGroup.java
@@ -44,7 +44,7 @@
import org.opends.admin.ads.ADSContext;
import org.opends.admin.ads.ADSContextException;
import org.opends.admin.ads.ADSContext.ServerGroupProperty;
import org.opends.server.admin.client.cli.DsServiceCliReturnCode.ReturnCode;
import org.opends.server.admin.client.cli.DsFrameworkCliReturnCode.ReturnCode;
import org.opends.server.util.args.ArgumentException;
import org.opends.server.util.args.BooleanArgument;
import org.opends.server.util.args.StringArgument;
@@ -54,7 +54,7 @@
/**
 * This class is handling server group CLI.
 */
public class DsServiceCliServerGroup implements DsServiceCliSubCommandGroup
public class DsFrameworkCliServerGroup implements DsFrameworkCliSubCommandGroup
{
  /**
opendj-sdk/opends/src/server/org/opends/server/admin/client/cli/DsFrameworkCliSubCommandGroup.java
File was renamed from opendj-sdk/opends/src/server/org/opends/server/admin/client/cli/DsServiceCliSubCommandGroup.java
@@ -30,7 +30,7 @@
import org.opends.admin.ads.ADSContext;
import org.opends.admin.ads.ADSContextException;
import org.opends.server.admin.client.cli.DsServiceCliReturnCode.ReturnCode;
import org.opends.server.admin.client.cli.DsFrameworkCliReturnCode.ReturnCode;
import org.opends.server.util.args.ArgumentException;
import org.opends.server.util.args.BooleanArgument;
import org.opends.server.util.args.SubCommand;
@@ -39,7 +39,7 @@
/**
 * This Interface defines method that a group of subcommand shoud implement.
 */
public interface DsServiceCliSubCommandGroup
public interface DsFrameworkCliSubCommandGroup
{
  /**
opendj-sdk/opends/tests/unit-tests-testng/src/server/org/opends/server/admin/client/cli/CliTest.java
@@ -32,7 +32,7 @@
import org.testng.annotations.*;
import org.opends.admin.ads.ADSContext.ServerGroupProperty;
import org.opends.admin.ads.ADSContextException.ErrorType;
import org.opends.server.admin.client.cli.DsServiceCliReturnCode.ReturnCode;
import org.opends.server.admin.client.cli.DsFrameworkCliReturnCode.ReturnCode;
import org.opends.server.util.args.ArgumentException;
import org.opends.server.util.args.SubCommandArgumentParser;
@@ -91,7 +91,7 @@
  {
    for (ErrorType error: ErrorType.values())
    {
      assertNotNull(DsServiceCliReturnCode.getReturncodeFromAdsError(error),
      assertNotNull(DsFrameworkCliReturnCode.getReturncodeFromAdsError(error),
          "ErrorType." + error + " is not associated with a return code");
    }
  }
@@ -102,7 +102,7 @@
  @Test
  public void testServerGroupAttributeDisplayName()
  {
    DsServiceCliServerGroup cli = new DsServiceCliServerGroup();
    DsFrameworkCliServerGroup cli = new DsFrameworkCliServerGroup();
    
    try
    {
opendj-sdk/opends/tests/unit-tests-testng/src/server/org/opends/server/admin/client/cli/DsserviceTestCase.java
@@ -40,7 +40,7 @@
import static org.testng.Assert.*;
import static org.opends.server.admin.client.cli.DsServiceCliReturnCode.*;
import static org.opends.server.admin.client.cli.DsFrameworkCliReturnCode.*;
@@ -92,7 +92,7 @@
      "admin"
    };
    assertEquals(DsServiceCliMain.mainCLI(args, false, System.out, System.err),
    assertEquals(DsFrameworkCliMain.mainCLI(args, false, System.out, System.err),
        ReturnCode.SUCCESSFUL.getReturnCode());
  }
@@ -112,7 +112,7 @@
      "admin"
    };
    assertEquals(DsServiceCliMain.mainCLI(args, false, System.out, System.err),
    assertEquals(DsFrameworkCliMain.mainCLI(args, false, System.out, System.err),
        ReturnCode.SUCCESSFUL.getReturnCode());
  }
@@ -130,7 +130,7 @@
      "-w", "password"
    };
    assertFalse(DsServiceCliMain.mainCLI(args, false, null, null)
    assertFalse(DsFrameworkCliMain.mainCLI(args, false, null, null)
        == ReturnCode.SUCCESSFUL.getReturnCode());
  }
  
@@ -148,7 +148,7 @@
      "-w", "password"
    };
    assertFalse(DsServiceCliMain.mainCLI(args, false, System.out, System.err)
    assertFalse(DsFrameworkCliMain.mainCLI(args, false, System.out, System.err)
        == ReturnCode.SUCCESSFUL.getReturnCode());
  }
@@ -166,7 +166,7 @@
      "-w", "wrongPassword"
    };
    assertFalse(DsServiceCliMain.mainCLI(args, false, System.out, System.err)
    assertFalse(DsFrameworkCliMain.mainCLI(args, false, System.out, System.err)
        == ReturnCode.SUCCESSFUL.getReturnCode());
  }
@@ -190,7 +190,7 @@
      "-j", validPasswordFile,
    };
    assertEquals(DsServiceCliMain.mainCLI(args, false, System.out, System.err),
    assertEquals(DsFrameworkCliMain.mainCLI(args, false, System.out, System.err),
        ReturnCode.SUCCESSFUL.getReturnCode());
  }
  
@@ -211,7 +211,7 @@
      "-j",invalidPasswordFile
    };
    assertFalse(DsServiceCliMain.mainCLI(args, false, System.out, System.err)
    assertFalse(DsFrameworkCliMain.mainCLI(args, false, System.out, System.err)
        == ReturnCode.SUCCESSFUL.getReturnCode());
  }
@@ -230,7 +230,7 @@
      "-X"
    };
    assertEquals(DsServiceCliMain.mainCLI(args, false, System.out, System.err),
    assertEquals(DsFrameworkCliMain.mainCLI(args, false, System.out, System.err),
        ReturnCode.SUCCESSFUL.getReturnCode());
  }
@@ -254,7 +254,7 @@
      "-P", trustStorePath
    };
    assertEquals(DsServiceCliMain.mainCLI(args, false, System.out, System.err),
    assertEquals(DsFrameworkCliMain.mainCLI(args, false, System.out, System.err),
        ReturnCode.SUCCESSFUL.getReturnCode());
  }
@@ -275,7 +275,7 @@
      "-X"
    };
    assertEquals(DsServiceCliMain.mainCLI(args, false, null, System.err),
    assertEquals(DsFrameworkCliMain.mainCLI(args, false, null, System.err),
        ReturnCode.SUCCESSFUL.getReturnCode());
  }
@@ -299,7 +299,7 @@
      "-P", trustStorePath
    };
    assertEquals(DsServiceCliMain.mainCLI(args, false, null, System.err),
    assertEquals(DsFrameworkCliMain.mainCLI(args, false, null, System.err),
        ReturnCode.SUCCESSFUL.getReturnCode());
  }
  
@@ -310,15 +310,15 @@
  public void testHelp()
  {
    String[] args = { "--help" };
    assertEquals(DsServiceCliMain.mainCLI(args, false, null, null),
    assertEquals(DsFrameworkCliMain.mainCLI(args, false, null, null),
        ReturnCode.SUCCESSFUL.getReturnCode());
    args = new String[] { "-H" };
    assertEquals(DsServiceCliMain.mainCLI(args, false, null, null),
    assertEquals(DsFrameworkCliMain.mainCLI(args, false, null, null),
        ReturnCode.SUCCESSFUL.getReturnCode());
    args = new String[] { "-?" };
    assertEquals(DsServiceCliMain.mainCLI(args, false, null, null),
    assertEquals(DsFrameworkCliMain.mainCLI(args, false, null, null),
        ReturnCode.SUCCESSFUL.getReturnCode());
  }
}