Package org.jumpmind.symmetric
Class AbstractCommandLauncher
java.lang.Object
org.jumpmind.symmetric.AbstractCommandLauncher
- Direct Known Subclasses:
DbCompareCommand,DbExportCommand,DbFillCommand,DbImportCommand,DbSqlCommand,JmxCommand,SymmetricAdmin,SymmetricLauncher
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected Stringprotected Stringprotected static final Stringstatic final Stringprotected ISymmetricEngineprotected static final Stringprotected Stringprotected static final Stringprotected static final Stringprotected static final Stringprotected static final Stringprotected static final Stringprotected static final Stringprotected static final Stringprotected static final Stringprotected static final Stringprotected IDatabasePlatformprotected File -
Constructor Summary
ConstructorsConstructorDescriptionAbstractCommandLauncher(String app, String argSyntax, String messageKeyPrefix) -
Method Summary
Modifier and TypeMethodDescriptionprotected voidaddCommonOption(org.apache.commons.cli.Options options, String opt, boolean hasArg) protected voidaddCommonOption(org.apache.commons.cli.Options options, String opt, String longOpt, boolean hasArg) protected voidprotected voidprotected voidbuildCryptoOptions(org.apache.commons.cli.Options options) protected voidbuildOptions(org.apache.commons.cli.Options options) protected voidconfigureCrypto(org.apache.commons.cli.CommandLine line) protected voidconfigureLogging(org.apache.commons.cli.CommandLine line) protected voidconfigurePropertiesFile(org.apache.commons.cli.CommandLine line) voidprotected abstract booleanexecuteWithOptions(org.apache.commons.cli.CommandLine line) protected IDatabasePlatformgetDatabasePlatform(boolean testConnection) protected IDatabasePlatformgetDatabasePlatform(boolean testConnection, boolean symmetricPlatform) protected ISymmetricEngineprotected ISymmetricEnginegetSymmetricEngine(boolean testConnection) protected TypedPropertiesprotected static voidprotected voidprintHelp(org.apache.commons.cli.CommandLine cmd, org.apache.commons.cli.Options options) protected abstract booleanprotected voidprintUsage(org.apache.commons.cli.Options options) protected abstract booleanrequiresPropertiesFile(org.apache.commons.cli.CommandLine line) protected StringscrubCommandLine(String[] cmdArgs) protected StringscrubOptionValues(org.apache.commons.cli.Option option) protected void
-
Field Details
-
DEFAULT_SERVER_PROPERTIES
-
HELP
- See Also:
-
OPTION_PROPERTIES_FILE
- See Also:
-
OPTION_ENGINE
- See Also:
-
OPTION_VERBOSE_CONSOLE
- See Also:
-
OPTION_DEBUG
- See Also:
-
OPTION_NO_LOG_CONSOLE
- See Also:
-
OPTION_NO_LOG_FILE
- See Also:
-
OPTION_KEYSTORE_PASSWORD
- See Also:
-
OPTION_KEYSTORE_TYPE
- See Also:
-
OPTION_JCE_PROVIDER
- See Also:
-
COMMON_MESSAGE_KEY_PREFIX
- See Also:
-
app
-
argSyntax
-
messageKeyPrefix
-
propertiesFile
-
engine
-
platform
-
-
Constructor Details
-
AbstractCommandLauncher
-
-
Method Details
-
initFromServerProperties
protected static void initFromServerProperties() -
printHelpIfNoOptionsAreProvided
protected abstract boolean printHelpIfNoOptionsAreProvided() -
requiresPropertiesFile
protected abstract boolean requiresPropertiesFile(org.apache.commons.cli.CommandLine line) -
execute
-
scrubCommandLine
-
scrubOptionValues
-
printHelp
protected void printHelp(org.apache.commons.cli.CommandLine cmd, org.apache.commons.cli.Options options) -
printUsage
protected void printUsage(org.apache.commons.cli.Options options) -
configureLogging
protected void configureLogging(org.apache.commons.cli.CommandLine line) throws MalformedURLException - Throws:
MalformedURLException
-
configurePropertiesFile
protected void configurePropertiesFile(org.apache.commons.cli.CommandLine line) throws org.apache.commons.cli.ParseException - Throws:
org.apache.commons.cli.ParseException
-
findSingleEnginesPropertiesFile
-
configureCrypto
- Throws:
Exception
-
getSymmetricEngine
-
getSymmetricEngine
-
testConnection
protected void testConnection() -
getDatabasePlatform
-
getDatabasePlatform
-
getTypedProperties
-
buildOptions
protected void buildOptions(org.apache.commons.cli.Options options) -
buildCryptoOptions
protected void buildCryptoOptions(org.apache.commons.cli.Options options) -
addOption
-
addOption
-
addCommonOption
-
addCommonOption
-
executeWithOptions
protected abstract boolean executeWithOptions(org.apache.commons.cli.CommandLine line) throws Exception - Throws:
Exception
-