Ejemplo n.º 1
0
  public boolean isImmutable() {
    Properties properties;

    if (tableConfiguration.getProperties().containsKey(PropertyRegistry.ANY_IMMUTABLE)) {
      properties = tableConfiguration.getProperties();
    } else {
      properties = context.getJavaModelGeneratorConfiguration().getProperties();
    }

    return isTrue(properties.getProperty(PropertyRegistry.ANY_IMMUTABLE));
  }
Ejemplo n.º 2
0
  public boolean isConstructorBased() {
    if (isImmutable()) {
      return true;
    }

    Properties properties;

    if (tableConfiguration.getProperties().containsKey(PropertyRegistry.ANY_CONSTRUCTOR_BASED)) {
      properties = tableConfiguration.getProperties();
    } else {
      properties = context.getJavaModelGeneratorConfiguration().getProperties();
    }

    return isTrue(properties.getProperty(PropertyRegistry.ANY_CONSTRUCTOR_BASED));
  }
Ejemplo n.º 3
0
  public void initialize() {
    calculateJavaClientAttributes();
    calculateModelAttributes();
    calculateXmlAttributes();

    if (tableConfiguration.getModelType() == ModelType.HIERARCHICAL) {
      rules = new HierarchicalModelRules(this);
    } else if (tableConfiguration.getModelType() == ModelType.FLAT) {
      rules = new FlatModelRules(this);
    } else {
      rules = new ConditionalModelRules(this);
    }

    context.getPlugins().initialized(this);
  }
Ejemplo n.º 4
0
 public String getTableConfigurationProperty(String property) {
   return tableConfiguration.getProperty(property);
 }
Ejemplo n.º 5
0
 public GeneratedKey getGeneratedKey() {
   return tableConfiguration.getGeneratedKey();
 }
Ejemplo n.º 6
0
 public String getSelectByPrimaryKeyQueryId() {
   return tableConfiguration.getSelectByPrimaryKeyQueryId();
 }
Ejemplo n.º 7
0
 public String getSelectByExampleQueryId() {
   return tableConfiguration.getSelectByExampleQueryId();
 }