public class Backup extends Tool
Constructor and Description |
---|
Backup() |
Modifier and Type | Method and Description |
---|---|
static void |
execute(String zipFileName,
String directory,
String db,
boolean quiet)
Backs up database files.
|
static void |
main(String... args)
Options are case sensitive.
|
void |
runTool(String... args)
Run the tool with the given output stream and arguments.
|
isOption, printNoDatabaseFilesFound, setOut, showUsage, throwUnsupportedOption
public static void main(String... args) throws SQLException
[-help] or [-?] | Print the list of options |
[-file <filename>] | The target file name (default: backup.zip) |
[-dir <dir>] | The source directory (default: .) |
[-db <database>] | Source database; not required if there is only one |
[-quiet] | Do not print progress information |
args
- the command line argumentsSQLException
public void runTool(String... args) throws SQLException
Tool
runTool
in class Tool
args
- the argument listSQLException
public static void execute(String zipFileName, String directory, String db, boolean quiet) throws SQLException
zipFileName
- the name of the target backup file (including path)directory
- the source directory namedb
- the source database name (null if there is only one database, and
and empty string to backup all files in this directory)quiet
- don't print progress informationSQLException
Copyright © 2012 JBoss by Red Hat. All Rights Reserved.