Package org.opends.server.tools
Class WaitForFileDelete
- java.lang.Object
-
- com.forgerock.opendj.cli.Tool
-
- org.opends.server.tools.WaitForFileDelete
-
- All Implemented Interfaces:
Closeable
,AutoCloseable
public final class WaitForFileDelete extends com.forgerock.opendj.cli.Tool
This program provides a simple tool that will wait for a specified file to be deleted before exiting. It can be used in the process of confirming that the server has completed its startup or shutdown process.
-
-
Constructor Summary
Constructors Constructor Description WaitForFileDelete(OutputStream out, OutputStream err)
Constructor for the WaitForFileDelete object.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static void
main(String[] args)
Processes the command-line arguments and initiates the process of waiting for the file to be removed.com.forgerock.opendj.cli.ReturnCode
run(String... args)
Processes the command-line arguments and then waits for the specified file to be removed.-
Methods inherited from class com.forgerock.opendj.cli.Tool
askPort, close, confirmAction, enableConsoleLoggingIfVerbose, errPrintln, errPrintln, errPrintln, errPrintlnSurroundedByBlankLines, errPrintVerboseMessage, flush, flushLogStream, getErrorStream, getErrStream, getInputStream, getOutputStream, isFullyInteractive, isQuiet, isScriptFriendly, isVerbose, logVerboseMessage, mayPrompt, parseArguments, pressReturnToContinue, print, println, println, println, printlnNoWrap, printlnSurroundedByBlankLines, printNoWrap, readInput, readInput, readInputAllowEmpty, readLineOfInput, readPassword, readValidatedInput, readValidatedInputOrThrow, report
-
-
-
-
Constructor Detail
-
WaitForFileDelete
public WaitForFileDelete(OutputStream out, OutputStream err)
Constructor for the WaitForFileDelete object.- Parameters:
out
- the print stream to use for standard output.err
- the print stream to use for standard error.
-
-
Method Detail
-
main
public static void main(String[] args)
Processes the command-line arguments and initiates the process of waiting for the file to be removed.- Parameters:
args
- The command-line arguments provided to this program.
-
run
public com.forgerock.opendj.cli.ReturnCode run(String... args) throws com.forgerock.opendj.cli.ClientException
Processes the command-line arguments and then waits for the specified file to be removed.- Overrides:
run
in classcom.forgerock.opendj.cli.Tool
- Parameters:
args
- The command-line arguments provided to this program.- Returns:
- An integer value of zero if the file was deleted successfully, or some other value if a problem occurred.
- Throws:
com.forgerock.opendj.cli.ClientException
- If an error occurs while running the tool.
-
-