Search in sources :

Example 11 with DfBasicProperties

use of org.dbflute.properties.DfBasicProperties in project dbflute-core by dbflute.

the class DfSchemaXmlReader method doCreateAs.

public static DfSchemaXmlReader doCreateAs(String schemaXml, DfGenetateXmlReadingFilter readingFilter) {
    final DfBasicProperties basicProp = DfBuildProperties.getInstance().getBasicProperties();
    final DfDatabaseTypeFacadeProp facadeProp = basicProp.getDatabaseTypeFacadeProp();
    final String databaseType = facadeProp.getTargetDatabase();
    return new DfSchemaXmlReader(schemaXml, databaseType, readingFilter);
}
Also used : DfDatabaseTypeFacadeProp(org.dbflute.properties.facade.DfDatabaseTypeFacadeProp) DfBasicProperties(org.dbflute.properties.DfBasicProperties)

Example 12 with DfBasicProperties

use of org.dbflute.properties.DfBasicProperties in project dbflute-core by dbflute.

the class DfBasicPropertiesTest method test_extendedConditionBeanPackage_witn_conditionBeanPackage.

public void test_extendedConditionBeanPackage_witn_conditionBeanPackage() {
    // ## Arrange ##
    Properties prop = new Properties();
    prop.setProperty("torque.packageBase", "test.base");
    prop.setProperty("torque.conditionBeanPackage", "test.cbean");
    prop.setProperty("torque.extendedConditionBeanPackage", "extended.cbean");
    DfBasicProperties packageProperties = new DfBasicProperties(prop);
    // ## Act ##
    String conditionBeanPackage = packageProperties.getConditionBeanPackage();
    String extendedConditionBeanPackage = packageProperties.getExtendedConditionBeanPackage();
    // ## Assert ##
    assertEquals("test.base.test.cbean", conditionBeanPackage);
    assertEquals("test.base.extended.cbean", extendedConditionBeanPackage);
}
Also used : Properties(java.util.Properties) DfBasicProperties(org.dbflute.properties.DfBasicProperties) DfBasicProperties(org.dbflute.properties.DfBasicProperties)

Example 13 with DfBasicProperties

use of org.dbflute.properties.DfBasicProperties in project dbflute-core by dbflute.

the class DfBasicPropertiesTest method test_conditionBeanPackage.

public void test_conditionBeanPackage() {
    // ## Arrange ##
    Properties prop = new Properties();
    prop.setProperty("torque.packageBase", "test.base");
    prop.setProperty("torque.conditionBeanPackage", "test.cbean");
    DfBasicProperties packageProperties = new DfBasicProperties(prop);
    // ## Act ##
    String conditionBeanPackage = packageProperties.getConditionBeanPackage();
    // ## Assert ##
    assertEquals("test.base.test.cbean", conditionBeanPackage);
}
Also used : Properties(java.util.Properties) DfBasicProperties(org.dbflute.properties.DfBasicProperties) DfBasicProperties(org.dbflute.properties.DfBasicProperties)

Example 14 with DfBasicProperties

use of org.dbflute.properties.DfBasicProperties in project dbflute-core by dbflute.

the class DfBasicPropertiesTest method test_extendedConditionBeanPackage_default_same_as_conditionBeanPackage.

public void test_extendedConditionBeanPackage_default_same_as_conditionBeanPackage() {
    // ## Arrange ##
    Properties prop = new Properties();
    prop.setProperty("torque.packageBase", "test.base");
    prop.setProperty("torque.conditionBeanPackage", "test.cbean");
    DfBasicProperties packageProperties = new DfBasicProperties(prop);
    // ## Act ##
    String conditionBeanPackage = packageProperties.getConditionBeanPackage();
    String extendedConditionBeanPackage = packageProperties.getExtendedConditionBeanPackage();
    // ## Assert ##
    assertEquals("test.base.test.cbean", conditionBeanPackage);
    assertEquals(conditionBeanPackage, extendedConditionBeanPackage);
}
Also used : Properties(java.util.Properties) DfBasicProperties(org.dbflute.properties.DfBasicProperties) DfBasicProperties(org.dbflute.properties.DfBasicProperties)

Example 15 with DfBasicProperties

use of org.dbflute.properties.DfBasicProperties in project dbflute-core by dbflute.

the class DfSchemaHistory method createAsCore.

public static DfSchemaHistory createAsCore() {
    // pure HistoryHTML
    final DfBasicProperties basicProp = DfBuildProperties.getInstance().getBasicProperties();
    final DfSchemaXmlFacadeProp facadeProp = basicProp.getSchemaXmlFacadeProp();
    return new DfSchemaHistory(facadeProp.getProjectSchemaHistoryFile());
}
Also used : DfBasicProperties(org.dbflute.properties.DfBasicProperties) DfSchemaXmlFacadeProp(org.dbflute.properties.facade.DfSchemaXmlFacadeProp)

Aggregations

DfBasicProperties (org.dbflute.properties.DfBasicProperties)20 Properties (java.util.Properties)4 DfLanguageDependency (org.dbflute.logic.generate.language.DfLanguageDependency)3 DfSchemaXmlFacadeProp (org.dbflute.properties.facade.DfSchemaXmlFacadeProp)3 File (java.io.File)2 DfOutsideSqlFile (org.dbflute.logic.sql2entity.analyzer.DfOutsideSqlFile)2 DfDatabaseTypeFacadeProp (org.dbflute.properties.facade.DfDatabaseTypeFacadeProp)2 FileNotFoundException (java.io.FileNotFoundException)1 HashMap (java.util.HashMap)1 LinkedHashMap (java.util.LinkedHashMap)1 Map (java.util.Map)1 DfBuildProperties (org.dbflute.DfBuildProperties)1 StringKeyMap (org.dbflute.helper.StringKeyMap)1 DfLanguageGrammar (org.dbflute.logic.generate.language.grammar.DfLanguageGrammar)1 DfLanguageClassPackage (org.dbflute.logic.generate.language.pkgstyle.DfLanguageClassPackage)1 DfDocumentProperties (org.dbflute.properties.DfDocumentProperties)1 DfLittleAdjustmentProperties (org.dbflute.properties.DfLittleAdjustmentProperties)1 DfSequenceIdentityProperties (org.dbflute.properties.DfSequenceIdentityProperties)1