Package org.jibx.schema.generator
Class SchemaGenCommandLine
java.lang.Object
org.jibx.custom.CustomizationCommandLineBase
org.jibx.custom.classes.ClassCustomizationBase
org.jibx.schema.generator.SchemaGenCommandLine
- Direct Known Subclasses:
BindGenCommandLine,WsdlGeneratorCommandLine
Command line processing specifically for the
SchemaGen class.
TODO: Split this into abstract base class which the existing subclasdses can extend directly, plus separate subclass- 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 GlobalCustomCustomizations model root.private IClassLocatorClass locator used to complete customizations.private MapNamespace URI to file name map.Fields inherited from class org.jibx.custom.CustomizationCommandLineBase
STRING_PARAMETER_ARRAY, STRING_UNMARSHALLER_PARAMETER_ARRAY -
Constructor Summary
ConstructorsModifierConstructorDescriptionConstructor for when class is used directly.protectedSchemaGenCommandLine(String[] lines) Constructor used by subclasses. -
Method Summary
Modifier and TypeMethodDescriptionprivate booleanaddUriNamePair(String text) Add uri=name pair to map.protected MapapplyOverrides(Map overmap) Apply map of override values to customizations read from file or created as default.protected booleanCheck if an extension parameter is recognized.Get customizations model root.Get class locator.Get schema namespace URI to name map.protected voidloadCustomizations(String path, IClassLocator loc, ValidationContext vctx) Load the customizations file.voidPrint usage information.protected voidsetLocator(IClassLocator locator) Set class locator.Methods inherited from class org.jibx.custom.classes.ClassCustomizationBase
finishParameters, loadCustomizations, splitItems, verboseDetailsMethods inherited from class org.jibx.custom.CustomizationCommandLineBase
getExtraArgs, getGeneratePath, getUsageLines, isVerbose, mergeUsageLines, processArgs, putKeyValue
-
Field Details
-
EXTRA_USAGE_LINES
Ordered array of extra usage lines. -
m_global
Customizations model root. -
m_uriNames
Namespace URI to file name map. -
m_locator
Class locator used to complete customizations.
-
-
Constructor Details
-
SchemaGenCommandLine
public SchemaGenCommandLine()Constructor for when class is used directly. -
SchemaGenCommandLine
Constructor used by subclasses.- Parameters:
lines-
-
-
Method Details
-
getLocator
Get class locator.- Returns:
- locator
-
setLocator
Set class locator.- Parameters:
locator-
-
getGlobal
Get customizations model root.- Returns:
- customizations
-
getUriNames
Get schema namespace URI to name map.- Returns:
- map
-
addUriNamePair
Add uri=name pair to map.- Parameters:
text-- Returns:
trueif valid,falseif not
-
checkParameter
Description copied from class:ClassCustomizationBaseCheck if an extension parameter is recognized. Subclasses which override this method should call the base class method before doing their own checks, and only perform their own checks if this method returnsfalse..- Overrides:
checkParameterin classClassCustomizationBase- Parameters:
alist- argument list- Returns:
trueif parameter processed,falseif unknown
-
loadCustomizations
protected void loadCustomizations(String path, IClassLocator loc, ValidationContext vctx) throws JiBXException, IOException Description copied from class:ClassCustomizationBaseLoad the customizations file. This method must load the specified customizations file, or create a default customizations instance, of the appropriate type.- Specified by:
loadCustomizationsin classClassCustomizationBase- Parameters:
path- customizations file path,nullif noneloc- class locatorvctx- validation context- Throws:
JiBXExceptionIOException
-
applyOverrides
Description copied from class:CustomizationCommandLineBaseApply map of override values to customizations read from file or created as default.- Specified by:
applyOverridesin classCustomizationCommandLineBase- Parameters:
overmap- override key-value map- Returns:
- map for key/values not recognized
-
printUsage
public void printUsage()Description copied from class:CustomizationCommandLineBasePrint usage information.- Specified by:
printUsagein classCustomizationCommandLineBase
-