Package org.jibx.schema.codegen
Class SchemaCommandLineBase
java.lang.Object
org.jibx.custom.CustomizationCommandLineBase
org.jibx.schema.codegen.SchemaCommandLineBase
- Direct Known Subclasses:
RefactoryCommandLine
Command line processing for tools working with schemas.
TODO: take schema root directory handling from CodeGenCommandLine
- Author:
- Dennis M. Sosnoski
-
Nested Class Summary
Nested classes/interfaces inherited from class org.jibx.custom.CustomizationCommandLineBase
CustomizationCommandLineBase.ArgList
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final String[]
Ordered array of extra usage lines.private SchemasetCustom
Customizations model root.private String
Schema root URL path.private File
Root directory for schemas (null
if not a file system root).private URL
Root URL for schemas.Fields inherited from class org.jibx.custom.CustomizationCommandLineBase
STRING_PARAMETER_ARRAY, STRING_UNMARSHALLER_PARAMETER_ARRAY
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected Map
applyOverrides
(Map overmap) Apply map of override values to customizations read from file or created as default.protected boolean
Check extension parameter.protected void
Finish processing of command line parameters.Get customizations model root.Get root directory for schemas.Get root URL for schemas.protected boolean
loadCustomizations
(String path) Load the customizations file.protected void
Print any extension details.Methods inherited from class org.jibx.custom.CustomizationCommandLineBase
getExtraArgs, getGeneratePath, getUsageLines, isVerbose, mergeUsageLines, printUsage, processArgs, putKeyValue
-
Field Details
-
EXTRA_USAGE_LINES
Ordered array of extra usage lines. -
m_rootPath
Schema root URL path. -
m_schemaRoot
Root URL for schemas. -
m_schemaDir
Root directory for schemas (null
if not a file system root). -
m_customRoot
Customizations model root.
-
-
Constructor Details
-
SchemaCommandLineBase
public SchemaCommandLineBase()Constructor.
-
-
Method Details
-
getSchemaRoot
Get root URL for schemas.- Returns:
- directory
-
getSchemaDir
Get root directory for schemas.- Returns:
- directory (
null
if root is not a directory)
-
getCustomRoot
Get customizations model root.- Returns:
- customizations
-
checkParameter
Description copied from class:CustomizationCommandLineBase
Check extension parameter. This method may be overridden by subclasses to process parameters beyond those known to this base class.- Overrides:
checkParameter
in classCustomizationCommandLineBase
- Parameters:
alist
- argument list- Returns:
true
if parameter processed,false
if unknown
-
verboseDetails
protected void verboseDetails()Description copied from class:CustomizationCommandLineBase
Print any extension details. This method may be overridden by subclasses to print extension parameter values for verbose output.- Overrides:
verboseDetails
in classCustomizationCommandLineBase
-
finishParameters
Finish processing of command line parameters. This just sets up the schema directory.- Overrides:
finishParameters
in classCustomizationCommandLineBase
- Parameters:
alist
-
-
loadCustomizations
Load the customizations file. This method must load the specified customizations file, or create a default customizations instance, of the appropriate type.- Specified by:
loadCustomizations
in classCustomizationCommandLineBase
- Parameters:
path
- customization file path- Returns:
true
if successful,false
if an error- Throws:
JiBXException
IOException
-
applyOverrides
Description copied from class:CustomizationCommandLineBase
Apply map of override values to customizations read from file or created as default.- Specified by:
applyOverrides
in classCustomizationCommandLineBase
- Parameters:
overmap
- override key-value map- Returns:
- map for key/values not recognized
-