|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.jomc.cli.commands.AbstractCommand
org.jomc.cli.commands.AbstractModletCommand
org.jomc.cli.commands.AbstractModelCommand
org.jomc.cli.commands.AbstractJomcToolCommand
@Generated(value="org.jomc.tools.SourceFileProcessor 1.2.2", comments="See http://jomc.sourceforge.net/jomc/1.2/jomc-tools-1.2.2") public abstract class AbstractJomcToolCommand
JOMC CLI JomcTool
based command implementation.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class org.jomc.cli.commands.AbstractModletCommand |
---|
AbstractModletCommand.CommandLineClassLoader |
Nested classes/interfaces inherited from interface org.jomc.cli.Command |
---|
Command.Listener |
Field Summary |
---|
Fields inherited from interface org.jomc.cli.Command |
---|
STATUS_FAILURE, STATUS_SUCCESS |
Constructor Summary | |
---|---|
AbstractJomcToolCommand()
Creates a new AbstractJomcToolCommand instance. |
Method Summary | ||
---|---|---|
protected
|
createJomcTool(String className,
Class<T> type,
CommandLine commandLine)
Creates a new JomcTool object for a given class name and type. |
|
protected
|
createObject(String className,
Class<T> type)
Creates a new object for a given class name and type. |
|
protected Implementation |
getImplementation(CommandLine commandLine,
Model model)
Gets the implementation to process from a given model. |
|
protected Locale |
getLocale(CommandLine commandLine)
Gets a locale from a command line. |
|
protected Module |
getModule(CommandLine commandLine,
Model model)
Gets the module to process from a given model. |
|
Options |
getOptions()
Gets the options of the command. |
|
protected Specification |
getSpecification(CommandLine commandLine,
Model model)
Gets the specification to process from a given model. |
|
protected boolean |
isModulesProcessingRequested(CommandLine commandLine)
Gets a flag indicating that all modules are requested to be processed. |
|
protected void |
postExecuteCommand(CommandLine commandLine)
Called by the execute method after the preExecuteCommand /executeCommand methods even if
those methods threw an exception. |
Methods inherited from class org.jomc.cli.commands.AbstractModelCommand |
---|
createModelContext, getModel |
Methods inherited from class org.jomc.cli.commands.AbstractModletCommand |
---|
createTransformer, getDocumentFiles, getModel, log |
Methods inherited from class org.jomc.cli.commands.AbstractCommand |
---|
execute, executeCommand, getAbbreviatedName, getDefaultLogLevel, getExceptionMessage, getListeners, getLogLevel, getLongDescription, getName, getShortDescription, isLoggable, log, preExecuteCommand, setDefaultLogLevel, setLogLevel |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
@Generated(value="org.jomc.tools.SourceFileProcessor 1.2.2", comments="See http://jomc.sourceforge.net/jomc/1.2/jomc-tools-1.2.2") public AbstractJomcToolCommand()
AbstractJomcToolCommand
instance.
Method Detail |
---|
protected void postExecuteCommand(CommandLine commandLine) throws CommandExecutionException
execute
method after the preExecuteCommand
/executeCommand
methods even if
those methods threw an exception.
postExecuteCommand
in class AbstractCommand
commandLine
- The command line to execute.
CommandExecutionException
- if executing the command fails.AbstractCommand.execute(org.apache.commons.cli.CommandLine)
protected <T> T createObject(String className, Class<T> type) throws CommandExecutionException
T
- The type of the object to create.className
- The name of the class to create an object of.type
- The class of the type of object to create.
className
.
NullPointerException
- if className
or type
is null
.
CommandExecutionException
- if creating a new object fails.protected <T extends JomcTool> T createJomcTool(String className, Class<T> type, CommandLine commandLine) throws CommandExecutionException
JomcTool
object for a given class name and type.
T
- The type of the object to create.commandLine
- The CommandLine
to configure the new JomcTool
object with.className
- The name of the class to create an object of.type
- The class of the type of object to create.
className
configured using commandLine
.
NullPointerException
- if commandLine
, className
or type
is null
.
CommandExecutionException
- if creating a new object fails.createObject(java.lang.String, java.lang.Class)
protected final Specification getSpecification(CommandLine commandLine, Model model)
commandLine
- The command line specifying the specification to process.model
- The model to get the specification to process from.
null
.
NullPointerException
- if commandLine
or model
is null
.protected final Implementation getImplementation(CommandLine commandLine, Model model)
commandLine
- The command line specifying the implementation to process.model
- The model to get the implementation to process from.
null
.
NullPointerException
- if commandLine
or model
is null
.protected final Module getModule(CommandLine commandLine, Model model)
commandLine
- The command line specifying the implementation to process.model
- The model to get the module to process from.
null
.
NullPointerException
- if model
is null
.protected final boolean isModulesProcessingRequested(CommandLine commandLine)
commandLine
- The command line to process.
true
, if processing of all modules is requested; false
, else.
NullPointerException
- if commandLine
is null
.getSpecification(org.apache.commons.cli.CommandLine, org.jomc.modlet.Model)
,
getImplementation(org.apache.commons.cli.CommandLine, org.jomc.modlet.Model)
,
getModule(org.apache.commons.cli.CommandLine, org.jomc.modlet.Model)
protected final Locale getLocale(CommandLine commandLine)
commandLine
- The command line to get a locale from.
commandLine
or null
, if commandLine
does not hold options
specifying a locale.@Generated(value="org.jomc.tools.SourceFileProcessor 1.2.2", comments="See http://jomc.sourceforge.net/jomc/1.2/jomc-tools-1.2.2") public Options getOptions()
Options:
Specification | Implementation |
---|---|
JOMC CLI Command Option (org.apache.commons.cli.Option) @ 1.2 |
JOMC CLI Classpath Option |
JOMC CLI Command Option (org.apache.commons.cli.Option) @ 1.2 |
JOMC CLI Country Option |
JOMC CLI Command Option (org.apache.commons.cli.Option) @ 1.2 |
JOMC CLI Default Template Profile Option |
JOMC CLI Command Option (org.apache.commons.cli.Option) @ 1.2 |
JOMC CLI Documents Option |
JOMC CLI Command Option (org.apache.commons.cli.Option) @ 1.2 |
JOMC CLI Implementation Option |
JOMC CLI Command Option (org.apache.commons.cli.Option) @ 1.2 |
JOMC CLI Indentation String Option |
JOMC CLI Command Option (org.apache.commons.cli.Option) @ 1.2 |
JOMC CLI Input Encoding Option |
JOMC CLI Command Option (org.apache.commons.cli.Option) @ 1.2 |
JOMC CLI Language Option |
JOMC CLI Command Option (org.apache.commons.cli.Option) @ 1.2 |
JOMC CLI Line Separator Option |
JOMC CLI Command Option (org.apache.commons.cli.Option) @ 1.2 |
JOMC CLI Locale Variant Option |
JOMC CLI Command Option (org.apache.commons.cli.Option) @ 1.2 |
JOMC CLI ModelContextFactory Class Name Option |
JOMC CLI Command Option (org.apache.commons.cli.Option) @ 1.2 |
JOMC CLI Model Option |
JOMC CLI Command Option (org.apache.commons.cli.Option) @ 1.2 |
JOMC CLI Modlet Location Option |
JOMC CLI Command Option (org.apache.commons.cli.Option) @ 1.2 |
JOMC CLI Modlet Schema System Id Option |
JOMC CLI Command Option (org.apache.commons.cli.Option) @ 1.2 |
JOMC CLI Module Location Option |
JOMC CLI Command Option (org.apache.commons.cli.Option) @ 1.2 |
JOMC CLI Module Name Option |
JOMC CLI Command Option (org.apache.commons.cli.Option) @ 1.2 |
JOMC CLI No Classpath Resolution Option |
JOMC CLI Command Option (org.apache.commons.cli.Option) @ 1.2 |
JOMC CLI No Model Processing Option |
JOMC CLI Command Option (org.apache.commons.cli.Option) @ 1.2 |
JOMC CLI No Model Resource Validation Option |
JOMC CLI Command Option (org.apache.commons.cli.Option) @ 1.2 |
JOMC CLI No Modlet Resource Validation Option |
JOMC CLI Command Option (org.apache.commons.cli.Option) @ 1.2 |
JOMC CLI Output Encoding Option |
JOMC CLI Command Option (org.apache.commons.cli.Option) @ 1.2 |
JOMC CLI Platform Provider Location Option |
JOMC CLI Command Option (org.apache.commons.cli.Option) @ 1.2 |
JOMC CLI Provider Location Option |
JOMC CLI Command Option (org.apache.commons.cli.Option) @ 1.2 |
JOMC CLI Specification Option |
JOMC CLI Command Option (org.apache.commons.cli.Option) @ 1.2 |
JOMC CLI Template Encoding Option |
JOMC CLI Command Option (org.apache.commons.cli.Option) @ 1.2 |
JOMC CLI Template Location Option |
JOMC CLI Command Option (org.apache.commons.cli.Option) @ 1.2 |
JOMC CLI Template Profile Option |
JOMC CLI Command Option (org.apache.commons.cli.Option) @ 1.2 |
JOMC CLI Transformer Location Option |
getOptions
in interface Command
getOptions
in class AbstractModelCommand
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Copyright © 2005-2012 The JOMC Project. All Rights Reserved. |