org.opends.server.admin.client.cli
Interface DsFrameworkCliSubCommandGroup

All Known Implementing Classes:
DsFrameworkCliAds, DsFrameworkCliGlobalAdmin, DsFrameworkCliServer, DsFrameworkCliServerGroup

public interface DsFrameworkCliSubCommandGroup

This Interface defines method that a group of subcommand shoud implement.


Method Summary
 java.lang.String getGroupName()
          Indicates subcommand group name.
 java.util.Set<SubCommand> getSubCommands()
          Get the subcommands list.
 void initializeCliGroup(DsFrameworkCliParser argParser, BooleanArgument verboseArg)
          Initialize subcommand related to server group management.
 boolean isHidden()
          Indicates whether this subcommand group should be hidden from the usage information.
 boolean isSubCommand(SubCommand subCmd)
          Indicates if the provided suncommand is part of this group.
 DsFrameworkCliReturnCode performSubCommand(SubCommand subCmd, java.io.OutputStream outStream, java.io.OutputStream errStream)
          Handle the subcommand.
 

Method Detail

initializeCliGroup

void initializeCliGroup(DsFrameworkCliParser argParser,
                        BooleanArgument verboseArg)
                        throws ArgumentException
Initialize subcommand related to server group management.

Parameters:
argParser - The parser in which we should be registered.
verboseArg - The verbose Argument.
Throws:
ArgumentException - If there is a problem with any of the parameters used to create this argument.

isSubCommand

boolean isSubCommand(SubCommand subCmd)
Indicates if the provided suncommand is part of this group.

Parameters:
subCmd - The actual subcommand with input parameter.
Returns:
True if the provided suncommand is part of this group.

performSubCommand

DsFrameworkCliReturnCode performSubCommand(SubCommand subCmd,
                                           java.io.OutputStream outStream,
                                           java.io.OutputStream errStream)
                                           throws ADSContextException,
                                                  ArgumentException
Handle the subcommand.

Parameters:
subCmd - The actual subcommand with input parameter
outStream - The output stream to use for standard output.
errStream - The output stream to use for standard error.
Returns:
the return code
Throws:
ADSContextException - If there is a problem with when trying to perform the operation.
ArgumentException - If there is a problem with any of the parameters used to execute this subcommand.

getSubCommands

java.util.Set<SubCommand> getSubCommands()
Get the subcommands list.

Returns:
the subcommand list.

isHidden

boolean isHidden()
Indicates whether this subcommand group should be hidden from the usage information.

Returns:
true if this subcommand group should be hidden from the usage information, or false if not.

getGroupName

java.lang.String getGroupName()
Indicates subcommand group name.

Returns:
the subcommand group name