| | |
| | | import java.io.PrintStream; |
| | | import java.util.HashSet; |
| | | |
| | | import org.opends.admin.ads.DsServiceCliReturnCode.ReturnCode; |
| | | import org.opends.server.loggers.debug.DebugTracer; |
| | | import org.opends.server.types.DebugLogLevel; |
| | | import org.opends.server.util.PasswordReader; |
| | |
| | | addGlobalArgument(verboseArg); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * Get the host name which has to be used for the command. |
| | | * |
| | |
| | | { |
| | | return hostNameArg.getDefaultValue(); |
| | | } |
| | | |
| | | } |
| | | |
| | | /** |
| | |
| | | { |
| | | return portArg.getDefaultValue(); |
| | | } |
| | | |
| | | } |
| | | |
| | | /** |
| | |
| | | * If there is a problem with when trying to perform the |
| | | * operation. |
| | | */ |
| | | public int performSubCommand(ADSContext adsContext, OutputStream outStream, |
| | | OutputStream errStream) |
| | | public ReturnCode performSubCommand(ADSContext adsContext, |
| | | OutputStream outStream, OutputStream errStream) |
| | | throws ADSContextException |
| | | { |
| | | SubCommand subCmd = getSubCommand(); |
| | |
| | | |
| | | // Should never occurs: If we are here, it means that the code to |
| | | // handle to subcommand is not yet written. |
| | | return 1; |
| | | return ReturnCode.ERROR_UNEXPECTED; |
| | | } |
| | | |
| | | /** |
| | | * Indicate if the verbose mode is required. |
| | | * |
| | | * @return True if verbose mode is required |
| | | */ |
| | | public boolean isVerbose() |
| | | { |
| | | if (verboseArg.isPresent()) |
| | | { |
| | | return true; |
| | | } |
| | | else |
| | | { |
| | | return false ; |
| | | } |
| | | } |
| | | } |