Package net.aifusion.utils
Class Cim2Java
java.lang.Object
net.aifusion.utils.Cim2Java
Factory class to generate Java code stubs from Cim Class definitions
- Author:
- Sharad Singhal
-
Constructor Summary
ConstructorDescriptionCim2Java
(HashMap<String, String> programArgs, Repository r) Create a CIM - java stub generator -
Method Summary
Modifier and TypeMethodDescriptionReturn a string containing the generated java class stubstatic void
Program to generate java stubs from one or more MOF files.static void
-
Constructor Details
-
Cim2Java
Create a CIM - java stub generator- Parameters:
programArgs
- - program argumentsr
- - repository to use- See Also:
-
-
Method Details
-
generateStub
Return a string containing the generated java class stub- Parameters:
c
- - CimClass to use for generating stub- Returns:
- - string containing the content of the java class
-
showHelp
-
main
Program to generate java stubs from one or more MOF files. This program accepts one or more MOF files, and generates java stubs from the MOF files. Qualifiers in the MOF files are used to create the appropriate java constructs. The program should be executed as follows:
"$ java Cim2Java [options] mofFile ..."
where options can be (defaults in [])- -h [true|false]
- put Cim2Java header in code [true]
- -s srcDirectory
- source directory used to write java files [src1]
- -v version
- default version number (should be of form nn.nn.nn) to use [0.0.1]
- -o [true|false]
- overwrite existing java files in case of conflict [false]
- -c [true|false]
- add method-level comments with MOF in generated code [false]
- -r repository
- persistent repository used to resolve input classes [none]
- -l logLevel
- logging level for messages [warning]
- -n nameSpace
- name space to use in repository (only if used with -r) [/root/local]
- -sv [true|false]
- Use StructureValue based constructor [false]
- Abstract
- Generate an abstract java class
- Interface
- Generate an interface java class
- Static
- Generate a static method or property in java
- Deprecated
- Label a java class, method, or property as @Deprecated
- Provider
- Use the value as a java class name for this MOF class
- [UML]PackagePath
- Use the value as the package name for the java class
- Version
- add the version value to the version annotation parameter in the java class
- Implements
- Add the defined interfaces to the java class
- Read
- The property is readable
- Write
- The property is writable
- Override
- annotate the property or method as overriding a superclass property or method using @Override
- Parameters:
args
- - program arguments
-