| java.lang.Object com.completex.objective.tools.generators.CompositePoGenerator
All known Subclasses: com.completex.objective.tools.generators.CompositeBeanGenerator,
CompositePoGenerator | public class CompositePoGenerator (Code) | | author: Gennady Krizhevsky |
Inner Class :protected static class LineStruct implements Cloneable | |
Inner Class :static class LineStructBlock implements Cloneable | |
Inner Class :protected class ClassStruct | |
Method Summary | |
protected void | addCompoundExtraImports(Map baseTemplate, Map templateObjectReference) | protected void | addToImports(String extraImports, ArrayList imports) | protected ClassStruct | baseClassNameByDependency(MetaObjectReference metaObjectReference, Referencing child, MetaObjectModel metaObjectModel, String objectKey) | protected ClassStruct | baseInterfaceNameByDependency(MetaObjectReference metaObjectReference, Referencing child, MetaObjectModel metaObjectModel, String objectKey) | protected String | buildConstructorArgs(MetaMultipleResultFactory multipleResultFactory) | protected String | className(MetaObjectReference metaObjectReference, String objectKey, LineStruct lineStruct) | public Map | extractProperties(String propertiesPath) | public Map | extractProperties(String propertiesPath, Properties env) | protected MetaModelsExtractor.ExtractStructEntry | extractStructEntryByRef(MetaRef metaRef, MetaObjectModel metaObjectModel, Set seen) | protected String | fullConstName(String className, String columnName) | protected void | generateClasses(MetaObjectModel metaObjectModel, LineStructBlock block) | protected void | generateInterfaces(MetaObjectModel metaObjectModel, LineStructBlock block) | protected PropertyMap | getAllPropertyMap() | protected String | getDefaultClassTemplatePath() | protected String | getDefaultInterfaceTemplatePath() | public MetaModelsExtractor.ExtractStruct | getExtractStruct() | protected List | getImports(Map templateObjectReference) | public Log | getLogger() | public MetaObjectModel | getMetaObjectModel() | public static String | getOrIs(MetaColumn column) | protected ClassStruct | getParentClassName(MetaObjectReference metaObjectReference, MetaObjectModel metaObjectModel, String objectKey, LineStruct classLineStruct, LineStruct intfLineStruct) | protected ClassStruct | getParentInterfaceName(MetaObjectReference metaObjectReference, MetaObjectModel metaObjectModel, String objectKey, LineStruct classLineStruct, LineStruct intfLineStruct) | protected Template | getTemplate(String templatePath, String defaultTemplateFileName) | protected LineStructBlock | initializeExtractStruct(Map map, Properties env) | protected LineStructBlock | initializeFromSdl(Map properties) | protected String | interfaceName(MetaObjectReference metaObjectReference, String objectKey, LineStruct lineStruct) | public boolean | isGenerateIntefaces() | protected static boolean | isMainPattern(MetaTable metaTable) | protected boolean | isMainPattern(String name) | static boolean | isMixedCase(String name) | protected boolean | isReversedInsertOrder(MetaTable parentTable, MetaTable childTable) | public static String | javaConstName(String prefix, String name) | public static String | javaName(String name, String prefix, String suffix, boolean calitalizeFirstChar) | public static String | javaName(String name, String prefix, String suffix, boolean calitalizeFirstChar, boolean mainPattern) | public String | javaType(ColumnType type) | protected void | loadMetaObjectModel(String complexModelPath) | protected MetaModel | loadModelFromFile(ModelLoaderAdapter modelFileLoaderAdapter) | public static String | lowerFirstChar(String name) | public static void | main(String[] args) | protected MetaTable | metaTableByRef(MetaRef metaRef, MetaObjectModel metaObjectModel, Set seen) | protected void | populateIndexConsts(ForeignKeys foreignKeys, MetaTable parentTable, MetaTable childTable, String parentClassName, String childClassName, ArrayList parentIndexConsts, ArrayList childIndexConsts) | protected void | populateInterfaceTemplate(MetaObjectModel metaObjectModel, LineStruct lineStruct, String templateName) | protected void | populatePks(MetaTable table, Map templateModel) | protected String | populatePks(MetaTable table, ArrayList pkVars, String pkArgs) | protected void | postGenerateAll(MetaObjectModel metaObjectModel, LineStructBlock lineStructBlock) | protected void | postGenerateClasses(MetaObjectModel metaObjectModel, LineStructBlock block) | protected void | postGenerateInterfaces(MetaObjectModel metaObjectModel, LineStructBlock lineStructBlock) | protected static void | printGeneratedClassFileInfo(String classFileName) | protected static void | printGeneratedClassFileInfo(String classFileName, String outputDir) | protected static void | printGeneratedIn(String outputDir) | protected static void | println(String s) | public void | process(String propertiesPath) | public void | process(String propertiesPath, String envPath) | public void | process(Map map) | public void | process(Map map, Properties env) | public void | process(LineStructBlock lineStructBlock) | protected void | processClassTemplate(Template template, Map templateObjectReference, MetaObjectReference metaObjectReference, MetaObjectModel metaObjectModel, MetaModelsExtractor.ExtractStruct extractStruct, boolean root, Writer writer, boolean generateClasses) | protected void | processClassTemplate0(Template template, Map templateObjectReference, Writer writer) | protected void | processComplex(MetaObjectReference metaObjectReference, Map templateObjectReference, MetaObjectModel metaObjectModel, ArrayList imports, MetaTable parentTable, String parentClassName, boolean classes, String objectKey, LineStruct classLineStruct, LineStruct intfLineStruct) | protected void | processComplexClass(MetaObjectReference metaObjectReference, Map templateObjectReference, MetaObjectModel metaObjectModel, ArrayList imports, MetaTable parentTable, String parentClassName, String objectKey, LineStruct classLineStruct, LineStruct intfLineStruct) | protected void | processComplexInterface(MetaObjectReference metaObjectReference, Map templateObjectReference, MetaObjectModel metaObjectModel, ArrayList imports, MetaTable parentTable, String parentClassName, String objectKey, LineStruct lineStruct) | protected void | processCompound(MetaObjectReference metaObjectReference, Map templateObjectReference, MetaObjectModel metaObjectModel, boolean classes, String objectKey, LineStruct classLineStruct, LineStruct intfLineStruct) | protected void | processCompoundClass(MetaObjectReference metaObjectReference, Map templateObjectReference, MetaObjectModel metaObjectModel, String objectKey, LineStruct classLineStruct, LineStruct intfLineStruct) | protected void | processCompoundInterface(MetaObjectReference metaObjectReference, Map templateObjectReference, MetaObjectModel metaObjectModel, String objectKey, LineStruct childLineStruct) | protected String | resolveChildInterfaceName(MetaObjectReference metaObjectReference, Referencing child, MetaObjectModel metaObjectModel, String childClassName, String objectKey, LineStruct childLineStruct) | protected LineStruct | resolveChildLineStruct(ComplexChildHandler handler, LineStruct intfLineStruct, LineStruct classLineStruct) | protected String | resolveCollectionImpl(Class multiClass, ArrayList imports) | protected String | resolveType(Class multiClass, ArrayList imports, String type) | protected String | resolveType(Object instance, ArrayList imports) | public void | setGenerateIntefaces(boolean generateIntefaces) | public void | setLogger(Log logger) | protected LineStruct | toLineStruct(PropertyMap propertyMap, boolean interfaces, boolean validatePoProperties) | protected LineStruct | toLineStruct(PropertyMap generic, PropertyMap classes, boolean interfaces, boolean validatePoProperties) | protected String | typedName(String childName, boolean mixedCase, Link.RelationshipType relationshipType) |
CMP_CONFIG_PATH | final public static String CMP_CONFIG_PATH(Code) | | |
COLLECTION_FACTORY_SUFFIX | final public static String COLLECTION_FACTORY_SUFFIX(Code) | | |
CPD_CHILD_PREFIX | final public static String CPD_CHILD_PREFIX(Code) | | |
CPX_CHILD_PREFIX | final public static String CPX_CHILD_PREFIX(Code) | | |
FILTER_PATTERN | final public static String FILTER_PATTERN(Code) | | |
GENERATE_INTERFACES | final public static String GENERATE_INTERFACES(Code) | | |
GENERATE_MAPPER | final public static String GENERATE_MAPPER(Code) | | |
GENERATE_TO_STRING | final public static String GENERATE_TO_STRING(Code) | | |
PO_CONFIG_PATH | final public static String PO_CONFIG_PATH(Code) | | |
TAG_CLASS_NAME | final public static String TAG_CLASS_NAME(Code) | | |
TAG_INTERFACE_NAME | final public static String TAG_INTERFACE_NAME(Code) | | |
debug | protected boolean debug(Code) | | |
CompositePoGenerator | public CompositePoGenerator()(Code) | | |
addCompoundExtraImports | protected void addCompoundExtraImports(Map baseTemplate, Map templateObjectReference)(Code) | | |
getDefaultClassTemplatePath | protected String getDefaultClassTemplatePath()(Code) | | |
getDefaultInterfaceTemplatePath | protected String getDefaultInterfaceTemplatePath()(Code) | | |
getImports | protected List getImports(Map templateObjectReference)(Code) | | |
initializeFromSdl | protected LineStructBlock initializeFromSdl(Map properties) throws IOException(Code) | | |
isGenerateIntefaces | public boolean isGenerateIntefaces()(Code) | | |
isMainPattern | protected static boolean isMainPattern(MetaTable metaTable)(Code) | | |
isMainPattern | protected boolean isMainPattern(String name)(Code) | | |
isReversedInsertOrder | protected boolean isReversedInsertOrder(MetaTable parentTable, MetaTable childTable)(Code) | | Returns true if one of the "parent link" foreign keys coincides with
one of the "child link"
primary keys
Parameters: parentTable - Parameters: childTable - true if isReversedInsertOrder |
postGenerateInterfaces | protected void postGenerateInterfaces(MetaObjectModel metaObjectModel, LineStructBlock lineStructBlock) throws IOException, TemplateException(Code) | | |
printGeneratedClassFileInfo | protected static void printGeneratedClassFileInfo(String classFileName)(Code) | | |
printGeneratedClassFileInfo | protected static void printGeneratedClassFileInfo(String classFileName, String outputDir)(Code) | | |
printGeneratedIn | protected static void printGeneratedIn(String outputDir)(Code) | | |
process | public void process(LineStructBlock lineStructBlock) throws Exception(Code) | | |
processClassTemplate0 | protected void processClassTemplate0(Template template, Map templateObjectReference, Writer writer) throws TemplateException, IOException(Code) | | |
processComplex | protected void processComplex(MetaObjectReference metaObjectReference, Map templateObjectReference, MetaObjectModel metaObjectModel, ArrayList imports, MetaTable parentTable, String parentClassName, boolean classes, String objectKey, LineStruct classLineStruct, LineStruct intfLineStruct) throws ClassNotFoundException, InstantiationException, IllegalAccessException(Code) | | |
processComplexClass | protected void processComplexClass(MetaObjectReference metaObjectReference, Map templateObjectReference, MetaObjectModel metaObjectModel, ArrayList imports, MetaTable parentTable, String parentClassName, String objectKey, LineStruct classLineStruct, LineStruct intfLineStruct) throws ClassNotFoundException, InstantiationException, IllegalAccessException(Code) | | |
resolveChildLineStruct | protected LineStruct resolveChildLineStruct(ComplexChildHandler handler, LineStruct intfLineStruct, LineStruct classLineStruct)(Code) | | |
setGenerateIntefaces | public void setGenerateIntefaces(boolean generateIntefaces)(Code) | | |
setLogger | public void setLogger(Log logger)(Code) | | |
toLineStruct | protected LineStruct toLineStruct(PropertyMap propertyMap, boolean interfaces, boolean validatePoProperties) throws IOException(Code) | | |
|
|