db-ddlutils-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From to...@apache.org
Subject svn commit: r383130 [2/2] - in /db/ddlutils/trunk/src: java/org/apache/ddlutils/ java/org/apache/ddlutils/platform/ java/org/apache/ddlutils/platform/axion/ java/org/apache/ddlutils/platform/cloudscape/ java/org/apache/ddlutils/platform/db2/ java/org/a...
Date Sat, 04 Mar 2006 15:09:02 GMT
Modified: db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/mssql/MSSqlBuilder.java
URL: http://svn.apache.org/viewcvs/db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/mssql/MSSqlBuilder.java?rev=383130&r1=383129&r2=383130&view=diff
==============================================================================
--- db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/mssql/MSSqlBuilder.java (original)
+++ db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/mssql/MSSqlBuilder.java Sat Mar  4 07:08:59 2006
@@ -22,7 +22,7 @@
 import java.sql.Types;
 import java.util.Map;
 
-import org.apache.ddlutils.PlatformInfo;
+import org.apache.ddlutils.Platform;
 import org.apache.ddlutils.model.Column;
 import org.apache.ddlutils.model.Database;
 import org.apache.ddlutils.model.ForeignKey;
@@ -43,11 +43,11 @@
     /**
      * Creates a new builder instance.
      * 
-     * @param info The platform info
+     * @param platform The plaftform this builder belongs to
      */
-    public MSSqlBuilder(PlatformInfo info)
+    public MSSqlBuilder(Platform platform)
     {
-        super(info);
+        super(platform);
         addEscapedCharSequence("'", "''");
     }
 
@@ -204,7 +204,7 @@
      */
     private void writeQuotationOnStatement() throws IOException
     {
-        if (getPlatformInfo().isUseDelimitedIdentifiers())
+        if (getPlatform().isDelimitedIdentifierModeOn())
         {
             print("SET quoted_identifier on");
             printEndOfStatement();
@@ -242,7 +242,7 @@
      */
     private String getQuotationOnStatement()
     {
-        if (getPlatformInfo().isUseDelimitedIdentifiers())
+        if (getPlatform().isDelimitedIdentifierModeOn())
         {
             return "SET quoted_identifier on" + getPlatformInfo().getSqlCommandDelimiter() + "\n";
         }

Modified: db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/mssql/MSSqlModelReader.java
URL: http://svn.apache.org/viewcvs/db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/mssql/MSSqlModelReader.java?rev=383130&r1=383129&r2=383130&view=diff
==============================================================================
--- db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/mssql/MSSqlModelReader.java (original)
+++ db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/mssql/MSSqlModelReader.java Sat Mar  4 07:08:59 2006
@@ -24,7 +24,7 @@
 import java.util.Map;
 
 import org.apache.ddlutils.DdlUtilsException;
-import org.apache.ddlutils.PlatformInfo;
+import org.apache.ddlutils.Platform;
 import org.apache.ddlutils.model.Column;
 import org.apache.ddlutils.model.Index;
 import org.apache.ddlutils.model.Table;
@@ -53,11 +53,11 @@
 	/**
      * Creates a new model reader for Microsoft Sql Server databases.
      * 
-     * @param platformInfo The platform specific settings
+     * @param platform The platform that this model reader belongs to
      */
-    public MSSqlModelReader(PlatformInfo platformInfo)
+    public MSSqlModelReader(Platform platform)
     {
-        super(platformInfo);
+        super(platform);
         setDefaultCatalogPattern(null);
         setDefaultSchemaPattern(null);
         setDefaultTablePattern("%");

Modified: db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/mssql/MSSqlPlatform.java
URL: http://svn.apache.org/viewcvs/db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/mssql/MSSqlPlatform.java?rev=383130&r1=383129&r2=383130&view=diff
==============================================================================
--- db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/mssql/MSSqlPlatform.java (original)
+++ db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/mssql/MSSqlPlatform.java Sat Mar  4 07:08:59 2006
@@ -47,10 +47,10 @@
      */
     public MSSqlPlatform()
     {
-        PlatformInfo info = new PlatformInfo();
+        PlatformInfo info = getPlatformInfo();
 
         info.setMaxIdentifierLength(128);
-        info.setRequiringNullAsDefaultValue(false);
+        info.setNullAsDefaultValueRequired(false);
         info.setPrimaryKeyEmbedded(true);
         info.setForeignKeysEmbedded(false);
         info.setIndicesEmbedded(false);
@@ -78,13 +78,13 @@
         info.addNativeTypeMapping("BOOLEAN",  "BIT",   "BIT");
         info.addNativeTypeMapping("DATALINK", "IMAGE", "LONGVARBINARY");
 
-        info.addDefaultSize(Types.CHAR,       254);
-        info.addDefaultSize(Types.VARCHAR,    254);
-        info.addDefaultSize(Types.BINARY,     254);
-        info.addDefaultSize(Types.VARBINARY,  254);
+        info.setDefaultSize(Types.CHAR,       254);
+        info.setDefaultSize(Types.VARCHAR,    254);
+        info.setDefaultSize(Types.BINARY,     254);
+        info.setDefaultSize(Types.VARBINARY,  254);
 
-        setSqlBuilder(new MSSqlBuilder(info));
-        setModelReader(new MSSqlModelReader(info));
+        setSqlBuilder(new MSSqlBuilder(this));
+        setModelReader(new MSSqlModelReader(this));
     }
 
     /**

Modified: db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/mysql/MySql50ModelReader.java
URL: http://svn.apache.org/viewcvs/db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/mysql/MySql50ModelReader.java?rev=383130&r1=383129&r2=383130&view=diff
==============================================================================
--- db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/mysql/MySql50ModelReader.java (original)
+++ db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/mysql/MySql50ModelReader.java Sat Mar  4 07:08:59 2006
@@ -19,7 +19,7 @@
 import java.sql.SQLException;
 import java.util.Map;
 
-import org.apache.ddlutils.PlatformInfo;
+import org.apache.ddlutils.Platform;
 import org.apache.ddlutils.model.Column;
 import org.apache.ddlutils.platform.DatabaseMetaDataWrapper;
 
@@ -34,11 +34,11 @@
     /**
      * Creates a new model reader for MySql 5 databases.
      * 
-     * @param platformInfo The platform specific settings
+     * @param platform The platform that this model reader belongs to
      */
-    public MySql50ModelReader(PlatformInfo platformInfo)
+    public MySql50ModelReader(Platform platform)
     {
-        super(platformInfo);
+        super(platform);
     }
 
     /**

Modified: db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/mysql/MySql50Platform.java
URL: http://svn.apache.org/viewcvs/db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/mysql/MySql50Platform.java?rev=383130&r1=383129&r2=383130&view=diff
==============================================================================
--- db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/mysql/MySql50Platform.java (original)
+++ db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/mysql/MySql50Platform.java Sat Mar  4 07:08:59 2006
@@ -43,19 +43,19 @@
      */
     public MySql50Platform()
     {
-        PlatformInfo info = new PlatformInfo();
+        PlatformInfo info = getPlatformInfo();
 
         info.setMaxIdentifierLength(64);
-        info.setRequiringNullAsDefaultValue(true);
-        info.setSupportingDefaultValuesForLongTypes(false);
+        info.setNullAsDefaultValueRequired(true);
+        info.setDefaultValuesForLongTypesSupported(false);
         info.setPrimaryKeyEmbedded(true);
         info.setForeignKeysEmbedded(false);
         info.setIndicesEmbedded(false);
         // see http://dev.mysql.com/doc/refman/4.1/en/example-auto-increment.html
-        info.setSupportingNonPKIdentityColumns(false);
+        info.setNonPKIdentityColumnsSupported(false);
         // MySql 5.0 returns an empty string for default values for pk columns
         // which is different from the mysql 4 behaviour
-        info.setReturningDefaultValueForRequired(false);
+        info.setSyntheticDefaultValueForRequiredReturned(false);
         info.setCommentPrefix("#");
         // Double quotes are only allowed for delimiting identifiers if the server SQL mode includes ANSI_QUOTES 
         info.setDelimiterToken("`");
@@ -84,13 +84,13 @@
         info.addNativeTypeMapping("BOOLEAN",  "TINYINT(1)", "BIT");
         info.addNativeTypeMapping("DATALINK", "MEDIUMBLOB");
 
-        info.addDefaultSize(Types.CHAR,      254);
-        info.addDefaultSize(Types.VARCHAR,   254);
-        info.addDefaultSize(Types.BINARY,    254);
-        info.addDefaultSize(Types.VARBINARY, 254);
+        info.setDefaultSize(Types.CHAR,      254);
+        info.setDefaultSize(Types.VARCHAR,   254);
+        info.setDefaultSize(Types.BINARY,    254);
+        info.setDefaultSize(Types.VARBINARY, 254);
         
-        setSqlBuilder(new MySqlBuilder(info));
-        setModelReader(new MySql50ModelReader(info));
+        setSqlBuilder(new MySqlBuilder(this));
+        setModelReader(new MySql50ModelReader(this));
     }
 
     /**

Modified: db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/mysql/MySqlBuilder.java
URL: http://svn.apache.org/viewcvs/db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/mysql/MySqlBuilder.java?rev=383130&r1=383129&r2=383130&view=diff
==============================================================================
--- db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/mysql/MySqlBuilder.java (original)
+++ db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/mysql/MySqlBuilder.java Sat Mar  4 07:08:59 2006
@@ -20,7 +20,7 @@
 import java.util.Iterator;
 import java.util.Map;
 
-import org.apache.ddlutils.PlatformInfo;
+import org.apache.ddlutils.Platform;
 import org.apache.ddlutils.model.Column;
 import org.apache.ddlutils.model.ForeignKey;
 import org.apache.ddlutils.model.Table;
@@ -39,11 +39,11 @@
     /**
      * Creates a new builder instance.
      * 
-     * @param info The platform info
+     * @param platform The plaftform this builder belongs to
      */
-    public MySqlBuilder(PlatformInfo info)
+    public MySqlBuilder(Platform platform)
     {
-        super(info);
+        super(platform);
         // we need to handle the backslash first otherwise the other
         // already escaped sequences would be affected
         addEscapedCharSequence("\\",     "\\\\");

Modified: db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/mysql/MySqlModelReader.java
URL: http://svn.apache.org/viewcvs/db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/mysql/MySqlModelReader.java?rev=383130&r1=383129&r2=383130&view=diff
==============================================================================
--- db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/mysql/MySqlModelReader.java (original)
+++ db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/mysql/MySqlModelReader.java Sat Mar  4 07:08:59 2006
@@ -20,7 +20,7 @@
 import java.sql.Types;
 import java.util.Map;
 
-import org.apache.ddlutils.PlatformInfo;
+import org.apache.ddlutils.Platform;
 import org.apache.ddlutils.model.Column;
 import org.apache.ddlutils.model.ForeignKey;
 import org.apache.ddlutils.model.Index;
@@ -39,11 +39,11 @@
     /**
      * Creates a new model reader for MySql databases.
      * 
-     * @param platformInfo The platform specific settings
+     * @param platform The platform that this model reader belongs to
      */
-    public MySqlModelReader(PlatformInfo platformInfo)
+    public MySqlModelReader(Platform platform)
     {
-        super(platformInfo);
+        super(platform);
         setDefaultCatalogPattern(null);
         setDefaultSchemaPattern(null);
         setDefaultTablePattern(null);
@@ -98,6 +98,6 @@
     protected boolean isInternalForeignKeyIndex(Table table, ForeignKey fk, Index index)
     {
         // MySql defines a non-unique index of the same name as the fk
-        return new MySqlBuilder(getPlatformInfo()).getForeignKeyName(table, fk).equals(index.getName());
+        return getPlatform().getSqlBuilder().getForeignKeyName(table, fk).equals(index.getName());
     }
 }

Modified: db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/mysql/MySqlPlatform.java
URL: http://svn.apache.org/viewcvs/db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/mysql/MySqlPlatform.java?rev=383130&r1=383129&r2=383130&view=diff
==============================================================================
--- db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/mysql/MySqlPlatform.java (original)
+++ db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/mysql/MySqlPlatform.java Sat Mar  4 07:08:59 2006
@@ -43,18 +43,18 @@
      */
     public MySqlPlatform()
     {
-        PlatformInfo info = new PlatformInfo();
+        PlatformInfo info = getPlatformInfo();
 
         info.setMaxIdentifierLength(64);
-        info.setRequiringNullAsDefaultValue(true);
-        info.setSupportingDefaultValuesForLongTypes(false);
+        info.setNullAsDefaultValueRequired(true);
+        info.setDefaultValuesForLongTypesSupported(false);
         info.setPrimaryKeyEmbedded(true);
         info.setForeignKeysEmbedded(false);
         info.setIndicesEmbedded(false);
         // see http://dev.mysql.com/doc/refman/4.1/en/example-auto-increment.html
-        info.setSupportingNonPKIdentityColumns(false);
+        info.setNonPKIdentityColumnsSupported(false);
         // MySql returns synthetic default values for pk columns
-        info.setReturningDefaultValueForRequired(true);
+        info.setSyntheticDefaultValueForRequiredReturned(true);
         info.setCommentPrefix("#");
         // Double quotes are only allowed for delimiting identifiers if the server SQL mode includes ANSI_QUOTES 
         info.setDelimiterToken("`");
@@ -83,13 +83,13 @@
         info.addNativeTypeMapping("BOOLEAN",  "TINYINT(1)", "BIT");
         info.addNativeTypeMapping("DATALINK", "MEDIUMBLOB");
 
-        info.addDefaultSize(Types.CHAR,      254);
-        info.addDefaultSize(Types.VARCHAR,   254);
-        info.addDefaultSize(Types.BINARY,    254);
-        info.addDefaultSize(Types.VARBINARY, 254);
+        info.setDefaultSize(Types.CHAR,      254);
+        info.setDefaultSize(Types.VARCHAR,   254);
+        info.setDefaultSize(Types.BINARY,    254);
+        info.setDefaultSize(Types.VARBINARY, 254);
         
-        setSqlBuilder(new MySqlBuilder(info));
-        setModelReader(new MySqlModelReader(info));
+        setSqlBuilder(new MySqlBuilder(this));
+        setModelReader(new MySqlModelReader(this));
     }
 
     /**

Modified: db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/oracle/Oracle10Builder.java
URL: http://svn.apache.org/viewcvs/db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/oracle/Oracle10Builder.java?rev=383130&r1=383129&r2=383130&view=diff
==============================================================================
--- db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/oracle/Oracle10Builder.java (original)
+++ db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/oracle/Oracle10Builder.java Sat Mar  4 07:08:59 2006
@@ -18,7 +18,7 @@
 
 import java.io.IOException;
 
-import org.apache.ddlutils.PlatformInfo;
+import org.apache.ddlutils.Platform;
 import org.apache.ddlutils.model.Column;
 import org.apache.ddlutils.model.Table;
 
@@ -33,11 +33,11 @@
     /**
      * Creates a new builder instance.
      * 
-     * @param info The platform info
+     * @param platform The plaftform this builder belongs to
      */
-    public Oracle10Builder(PlatformInfo info)
+    public Oracle10Builder(Platform platform)
     {
-        super(info);
+        super(platform);
     }
 
     /**

Modified: db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/oracle/Oracle10ModelReader.java
URL: http://svn.apache.org/viewcvs/db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/oracle/Oracle10ModelReader.java?rev=383130&r1=383129&r2=383130&view=diff
==============================================================================
--- db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/oracle/Oracle10ModelReader.java (original)
+++ db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/oracle/Oracle10ModelReader.java Sat Mar  4 07:08:59 2006
@@ -21,7 +21,7 @@
 import java.sql.SQLException;
 import java.util.Map;
 
-import org.apache.ddlutils.PlatformInfo;
+import org.apache.ddlutils.Platform;
 import org.apache.ddlutils.model.Table;
 import org.apache.ddlutils.platform.DatabaseMetaDataWrapper;
 
@@ -36,11 +36,11 @@
     /**
      * Creates a new model reader for Oracle 10 databases.
      * 
-     * @param platformInfo The platform specific settings
+     * @param platform The platform that this model reader belongs to
      */
-    public Oracle10ModelReader(PlatformInfo platformInfo)
+    public Oracle10ModelReader(Platform platform)
     {
-        super(platformInfo);
+        super(platform);
     }
 
     /**

Modified: db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/oracle/Oracle10Platform.java
URL: http://svn.apache.org/viewcvs/db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/oracle/Oracle10Platform.java?rev=383130&r1=383129&r2=383130&view=diff
==============================================================================
--- db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/oracle/Oracle10Platform.java (original)
+++ db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/oracle/Oracle10Platform.java Sat Mar  4 07:08:59 2006
@@ -34,8 +34,8 @@
     public Oracle10Platform()
     {
         super();
-        setSqlBuilder(new Oracle10Builder(getPlatformInfo()));
-        setModelReader(new Oracle10ModelReader(getPlatformInfo()));
+        setSqlBuilder(new Oracle10Builder(this));
+        setModelReader(new Oracle10ModelReader(this));
     }
 
     /**

Modified: db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/oracle/Oracle8Builder.java
URL: http://svn.apache.org/viewcvs/db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/oracle/Oracle8Builder.java?rev=383130&r1=383129&r2=383130&view=diff
==============================================================================
--- db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/oracle/Oracle8Builder.java (original)
+++ db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/oracle/Oracle8Builder.java Sat Mar  4 07:08:59 2006
@@ -21,7 +21,7 @@
 import java.util.Map;
 
 import org.apache.ddlutils.DdlUtilsException;
-import org.apache.ddlutils.PlatformInfo;
+import org.apache.ddlutils.Platform;
 import org.apache.ddlutils.model.Column;
 import org.apache.ddlutils.model.Database;
 import org.apache.ddlutils.model.Table;
@@ -53,11 +53,11 @@
 	/**
      * Creates a new builder instance.
      * 
-     * @param info The platform info
+     * @param platform The plaftform this builder belongs to
      */
-    public Oracle8Builder(PlatformInfo info)
+    public Oracle8Builder(Platform platform)
     {
-        super(info);
+        super(platform);
         addEscapedCharSequence("'", "''");
 
         PatternCompiler compiler = new Perl5Compiler();

Modified: db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/oracle/Oracle8ModelReader.java
URL: http://svn.apache.org/viewcvs/db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/oracle/Oracle8ModelReader.java?rev=383130&r1=383129&r2=383130&view=diff
==============================================================================
--- db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/oracle/Oracle8ModelReader.java (original)
+++ db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/oracle/Oracle8ModelReader.java Sat Mar  4 07:08:59 2006
@@ -30,7 +30,7 @@
 
 import org.apache.commons.collections.map.ListOrderedMap;
 import org.apache.ddlutils.DdlUtilsException;
-import org.apache.ddlutils.PlatformInfo;
+import org.apache.ddlutils.Platform;
 import org.apache.ddlutils.model.Column;
 import org.apache.ddlutils.platform.DatabaseMetaDataWrapper;
 import org.apache.ddlutils.platform.JdbcModelReader;
@@ -59,11 +59,11 @@
 	/**
      * Creates a new model reader for Oracle 8 databases.
      * 
-     * @param platformInfo The platform specific settings
+     * @param platform The platform that this model reader belongs to
      */
-    public Oracle8ModelReader(PlatformInfo platformInfo)
+    public Oracle8ModelReader(Platform platform)
     {
-        super(platformInfo);
+        super(platform);
         setDefaultCatalogPattern(null);
         setDefaultSchemaPattern(null);
         setDefaultTablePattern("%");
@@ -218,7 +218,7 @@
         try
         {
     		stmt = getConnection().prepareStatement(query.toString());
-    		stmt.setString(1, getPlatformInfo().isUseDelimitedIdentifiers() ? tableName : tableName.toUpperCase());
+    		stmt.setString(1, getPlatform().isDelimitedIdentifierModeOn() ? tableName : tableName.toUpperCase());
     		stmt.setString(2, "N");
     		stmt.setString(3, "TABLE");
     		if (metaData.getSchemaPattern() != null)

Modified: db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/oracle/Oracle8Platform.java
URL: http://svn.apache.org/viewcvs/db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/oracle/Oracle8Platform.java?rev=383130&r1=383129&r2=383130&view=diff
==============================================================================
--- db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/oracle/Oracle8Platform.java (original)
+++ db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/oracle/Oracle8Platform.java Sat Mar  4 07:08:59 2006
@@ -51,14 +51,14 @@
      */
     public Oracle8Platform()
     {
-        PlatformInfo info = new PlatformInfo();
+        PlatformInfo info = getPlatformInfo();
 
         info.setMaxIdentifierLength(30);
-        info.setRequiringNullAsDefaultValue(false);
+        info.setNullAsDefaultValueRequired(false);
         info.setPrimaryKeyEmbedded(true);
         info.setForeignKeysEmbedded(false);
         info.setIndicesEmbedded(false);
-        info.setCanReadAutoIncrementStatus(false);
+        info.setAutoIncrementStatusReadingSupported(false);
 
         // Note that the back-mappings are partially done by the model reader, not the driver
         info.addNativeTypeMapping(Types.ARRAY,         "BLOB",             Types.BLOB);
@@ -90,13 +90,13 @@
         info.addNativeTypeMapping("BOOLEAN",  "NUMBER(1)", "BIT");
         info.addNativeTypeMapping("DATALINK", "BLOB",      "BLOB");
 
-        info.addDefaultSize(Types.CHAR,       254);
-        info.addDefaultSize(Types.VARCHAR,    254);
-        info.addDefaultSize(Types.BINARY,     254);
-        info.addDefaultSize(Types.VARBINARY,  254);
+        info.setDefaultSize(Types.CHAR,       254);
+        info.setDefaultSize(Types.VARCHAR,    254);
+        info.setDefaultSize(Types.BINARY,     254);
+        info.setDefaultSize(Types.VARBINARY,  254);
 
-        setSqlBuilder(new Oracle8Builder(info));
-        setModelReader(new Oracle8ModelReader(info));
+        setSqlBuilder(new Oracle8Builder(this));
+        setModelReader(new Oracle8ModelReader(this));
     }
 
     /**

Modified: db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/postgresql/PostgreSqlBuilder.java
URL: http://svn.apache.org/viewcvs/db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/postgresql/PostgreSqlBuilder.java?rev=383130&r1=383129&r2=383130&view=diff
==============================================================================
--- db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/postgresql/PostgreSqlBuilder.java (original)
+++ db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/postgresql/PostgreSqlBuilder.java Sat Mar  4 07:08:59 2006
@@ -19,7 +19,7 @@
 import java.io.IOException;
 import java.util.Map;
 
-import org.apache.ddlutils.PlatformInfo;
+import org.apache.ddlutils.Platform;
 import org.apache.ddlutils.model.Column;
 import org.apache.ddlutils.model.Database;
 import org.apache.ddlutils.model.Index;
@@ -38,11 +38,11 @@
     /**
      * Creates a new builder instance.
      * 
-     * @param info The platform info
+     * @param platform The plaftform this builder belongs to
      */
-    public PostgreSqlBuilder(PlatformInfo info)
+    public PostgreSqlBuilder(Platform platform)
     {
-        super(info);
+        super(platform);
         // we need to handle the backslash first otherwise the other
         // already escaped sequences would be affected
         addEscapedCharSequence("\\", "\\\\");

Modified: db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/postgresql/PostgreSqlModelReader.java
URL: http://svn.apache.org/viewcvs/db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/postgresql/PostgreSqlModelReader.java?rev=383130&r1=383129&r2=383130&view=diff
==============================================================================
--- db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/postgresql/PostgreSqlModelReader.java (original)
+++ db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/postgresql/PostgreSqlModelReader.java Sat Mar  4 07:08:59 2006
@@ -21,7 +21,7 @@
 import java.util.HashMap;
 import java.util.Map;
 
-import org.apache.ddlutils.PlatformInfo;
+import org.apache.ddlutils.Platform;
 import org.apache.ddlutils.model.Column;
 import org.apache.ddlutils.model.ForeignKey;
 import org.apache.ddlutils.model.Index;
@@ -40,11 +40,11 @@
     /**
      * Creates a new model reader for PostgreSql databases.
      * 
-     * @param platformInfo The platform specific settings
+     * @param platform The platform that this model reader belongs to
      */
-    public PostgreSqlModelReader(PlatformInfo platformInfo)
+    public PostgreSqlModelReader(Platform platform)
     {
-        super(platformInfo);
+        super(platform);
         setDefaultCatalogPattern(null);
         setDefaultSchemaPattern(null);
         setDefaultTablePattern(null);

Modified: db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/postgresql/PostgreSqlPlatform.java
URL: http://svn.apache.org/viewcvs/db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/postgresql/PostgreSqlPlatform.java?rev=383130&r1=383129&r2=383130&view=diff
==============================================================================
--- db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/postgresql/PostgreSqlPlatform.java (original)
+++ db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/postgresql/PostgreSqlPlatform.java Sat Mar  4 07:08:59 2006
@@ -51,12 +51,12 @@
      */
     public PostgreSqlPlatform()
     {
-        PlatformInfo info = new PlatformInfo();
+        PlatformInfo info = getPlatformInfo();
 
         // this is the default length though it might be changed when building PostgreSQL
         // in file src/include/postgres_ext.h
         info.setMaxIdentifierLength(31);
-        info.setRequiringNullAsDefaultValue(false);
+        info.setNullAsDefaultValueRequired(false);
         info.setPrimaryKeyEmbedded(true);
         info.setForeignKeysEmbedded(false);
         info.setIndicesEmbedded(false);
@@ -85,8 +85,8 @@
         info.setHasSize(Types.BINARY, false);
         info.setHasSize(Types.VARBINARY, false);
 
-        setSqlBuilder(new PostgreSqlBuilder(info));
-        setModelReader(new PostgreSqlModelReader(info));
+        setSqlBuilder(new PostgreSqlBuilder(this));
+        setModelReader(new PostgreSqlModelReader(this));
     }
 
     /**

Modified: db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/sapdb/SapDbBuilder.java
URL: http://svn.apache.org/viewcvs/db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/sapdb/SapDbBuilder.java?rev=383130&r1=383129&r2=383130&view=diff
==============================================================================
--- db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/sapdb/SapDbBuilder.java (original)
+++ db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/sapdb/SapDbBuilder.java Sat Mar  4 07:08:59 2006
@@ -18,7 +18,7 @@
 
 import java.io.IOException;
 
-import org.apache.ddlutils.PlatformInfo;
+import org.apache.ddlutils.Platform;
 import org.apache.ddlutils.model.Column;
 import org.apache.ddlutils.model.Table;
 import org.apache.ddlutils.platform.SqlBuilder;
@@ -35,11 +35,11 @@
     /**
      * Creates a new builder instance.
      * 
-     * @param info The platform info
+     * @param platform The plaftform this builder belongs to
      */
-    public SapDbBuilder(PlatformInfo info)
+    public SapDbBuilder(Platform platform)
     {
-        super(info);
+        super(platform);
         addEscapedCharSequence("'", "''");
     }
 

Modified: db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/sapdb/SapDbModelReader.java
URL: http://svn.apache.org/viewcvs/db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/sapdb/SapDbModelReader.java?rev=383130&r1=383129&r2=383130&view=diff
==============================================================================
--- db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/sapdb/SapDbModelReader.java (original)
+++ db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/sapdb/SapDbModelReader.java Sat Mar  4 07:08:59 2006
@@ -20,7 +20,7 @@
 import java.sql.Types;
 import java.util.Map;
 
-import org.apache.ddlutils.PlatformInfo;
+import org.apache.ddlutils.Platform;
 import org.apache.ddlutils.model.Column;
 import org.apache.ddlutils.platform.DatabaseMetaDataWrapper;
 import org.apache.ddlutils.platform.JdbcModelReader;
@@ -36,11 +36,11 @@
     /**
      * Creates a new model reader for SapDb databases.
      * 
-     * @param platformInfo The platform specific settings
+     * @param platform The platform that this model reader belongs to
      */
-    public SapDbModelReader(PlatformInfo platformInfo)
+    public SapDbModelReader(Platform platform)
     {
-        super(platformInfo);
+        super(platform);
         setDefaultCatalogPattern(null);
         setDefaultSchemaPattern(null);
         setDefaultTablePattern("%");

Modified: db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/sapdb/SapDbPlatform.java
URL: http://svn.apache.org/viewcvs/db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/sapdb/SapDbPlatform.java?rev=383130&r1=383129&r2=383130&view=diff
==============================================================================
--- db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/sapdb/SapDbPlatform.java (original)
+++ db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/sapdb/SapDbPlatform.java Sat Mar  4 07:08:59 2006
@@ -41,10 +41,10 @@
      */
     public SapDbPlatform()
     {
-        PlatformInfo info = new PlatformInfo();
+        PlatformInfo info = getPlatformInfo();
 
         info.setMaxIdentifierLength(32);
-        info.setRequiringNullAsDefaultValue(false);
+        info.setNullAsDefaultValueRequired(false);
         info.setPrimaryKeyEmbedded(true);
         info.setForeignKeysEmbedded(false);
         info.setIndicesEmbedded(false);
@@ -79,13 +79,13 @@
         info.addNativeTypeMapping("BOOLEAN",  "BOOLEAN",   "BIT");
         info.addNativeTypeMapping("DATALINK", "LONG BYTE", "LONGVARBINARY");
 
-        info.addDefaultSize(Types.CHAR,      254);
-        info.addDefaultSize(Types.VARCHAR,   254);
-        info.addDefaultSize(Types.BINARY,    254);
-        info.addDefaultSize(Types.VARBINARY, 254);
+        info.setDefaultSize(Types.CHAR,      254);
+        info.setDefaultSize(Types.VARCHAR,   254);
+        info.setDefaultSize(Types.BINARY,    254);
+        info.setDefaultSize(Types.VARBINARY, 254);
 
-        setSqlBuilder(new SapDbBuilder(info));
-        setModelReader(new SapDbModelReader(info));
+        setSqlBuilder(new SapDbBuilder(this));
+        setModelReader(new SapDbModelReader(this));
     }
 
     /**

Modified: db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/sybase/SybaseBuilder.java
URL: http://svn.apache.org/viewcvs/db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/sybase/SybaseBuilder.java?rev=383130&r1=383129&r2=383130&view=diff
==============================================================================
--- db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/sybase/SybaseBuilder.java (original)
+++ db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/sybase/SybaseBuilder.java Sat Mar  4 07:08:59 2006
@@ -23,7 +23,7 @@
 import java.util.Map;
 
 import org.apache.ddlutils.DynaSqlException;
-import org.apache.ddlutils.PlatformInfo;
+import org.apache.ddlutils.Platform;
 import org.apache.ddlutils.model.Column;
 import org.apache.ddlutils.model.Database;
 import org.apache.ddlutils.model.ForeignKey;
@@ -43,11 +43,11 @@
     /**
      * Creates a new builder instance.
      * 
-     * @param info The platform info
+     * @param platform The plaftform this builder belongs to
      */
-    public SybaseBuilder(PlatformInfo info)
+    public SybaseBuilder(Platform platform)
     {
-        super(info);
+        super(platform);
         addEscapedCharSequence("'", "''");
     }
 
@@ -71,7 +71,7 @@
 
         if (column.getDefaultValue() != null)
         {
-            if (!getPlatformInfo().isSupportingDefaultValuesForLongTypes() && 
+            if (!getPlatformInfo().isDefaultValuesForLongTypesSupported() && 
                 ((column.getTypeCode() == Types.LONGVARBINARY) || (column.getTypeCode() == Types.LONGVARCHAR)))
             {
                 throw new DynaSqlException("The platform does not support default values for LONGVARCHAR or LONGVARBINARY columns");
@@ -182,7 +182,7 @@
      */
     private void writeQuotationOnStatement() throws IOException
     {
-        if (getPlatformInfo().isUseDelimitedIdentifiers())
+        if (getPlatform().isDelimitedIdentifierModeOn())
         {
             print("SET quoted_identifier on");
             printEndOfStatement();

Modified: db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/sybase/SybaseModelReader.java
URL: http://svn.apache.org/viewcvs/db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/sybase/SybaseModelReader.java?rev=383130&r1=383129&r2=383130&view=diff
==============================================================================
--- db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/sybase/SybaseModelReader.java (original)
+++ db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/sybase/SybaseModelReader.java Sat Mar  4 07:08:59 2006
@@ -24,7 +24,7 @@
 import java.util.Map;
 
 import org.apache.ddlutils.DdlUtilsException;
-import org.apache.ddlutils.PlatformInfo;
+import org.apache.ddlutils.Platform;
 import org.apache.ddlutils.model.Column;
 import org.apache.ddlutils.model.Index;
 import org.apache.ddlutils.model.Table;
@@ -53,11 +53,11 @@
 	/**
      * Creates a new model reader for Sybase databases.
      * 
-     * @param platformInfo The platform specific settings
+     * @param platform The platform that this model reader belongs to
      */
-    public SybaseModelReader(PlatformInfo platformInfo)
+    public SybaseModelReader(Platform platform)
     {
-        super(platformInfo);
+        super(platform);
         setDefaultCatalogPattern(null);
         setDefaultSchemaPattern(null);
         setDefaultTablePattern("%");
@@ -130,7 +130,7 @@
 	 */
 	protected void readIndex(DatabaseMetaDataWrapper metaData, Map values, Map knownIndices) throws SQLException
 	{
-		if (getPlatformInfo().isUseDelimitedIdentifiers())
+		if (getPlatform().isDelimitedIdentifierModeOn())
 		{
 	        String indexName = (String)values.get("INDEX_NAME");
 

Modified: db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/sybase/SybasePlatform.java
URL: http://svn.apache.org/viewcvs/db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/sybase/SybasePlatform.java?rev=383130&r1=383129&r2=383130&view=diff
==============================================================================
--- db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/sybase/SybasePlatform.java (original)
+++ db/ddlutils/trunk/src/java/org/apache/ddlutils/platform/sybase/SybasePlatform.java Sat Mar  4 07:08:59 2006
@@ -61,10 +61,10 @@
      */
     public SybasePlatform()
     {
-        PlatformInfo info = new PlatformInfo();
+        PlatformInfo info = getPlatformInfo();
 
         info.setMaxIdentifierLength(28);
-        info.setRequiringNullAsDefaultValue(false);
+        info.setNullAsDefaultValueRequired(false);
         info.setPrimaryKeyEmbedded(true);
         info.setForeignKeysEmbedded(false);
         info.setIndicesEmbedded(false);
@@ -96,13 +96,13 @@
         info.addNativeTypeMapping("BOOLEAN",  "SMALLINT", "SMALLINT");
         info.addNativeTypeMapping("DATALINK", "IMAGE",    "LONGVARBINARY");
 
-        info.addDefaultSize(Types.BINARY,    254);
-        info.addDefaultSize(Types.VARBINARY, 254);
-        info.addDefaultSize(Types.CHAR,      254);
-        info.addDefaultSize(Types.VARCHAR,   254);
+        info.setDefaultSize(Types.BINARY,    254);
+        info.setDefaultSize(Types.VARBINARY, 254);
+        info.setDefaultSize(Types.CHAR,      254);
+        info.setDefaultSize(Types.VARCHAR,   254);
 
-        setSqlBuilder(new SybaseBuilder(info));
-        setModelReader(new SybaseModelReader(info));
+        setSqlBuilder(new SybaseBuilder(this));
+        setModelReader(new SybaseModelReader(this));
     }
 
     /**

Modified: db/ddlutils/trunk/src/java/org/apache/ddlutils/task/PlatformConfiguration.java
URL: http://svn.apache.org/viewcvs/db/ddlutils/trunk/src/java/org/apache/ddlutils/task/PlatformConfiguration.java?rev=383130&r1=383129&r2=383130&view=diff
==============================================================================
--- db/ddlutils/trunk/src/java/org/apache/ddlutils/task/PlatformConfiguration.java (original)
+++ db/ddlutils/trunk/src/java/org/apache/ddlutils/task/PlatformConfiguration.java Sat Mar  4 07:08:59 2006
@@ -179,7 +179,7 @@
             throw new BuildException("Database type "+_databaseType+" is not supported.");
         }
         platform.setDataSource(_dataSource);
-        platform.getPlatformInfo().setUseDelimitedIdentifiers(isUseDelimitedSqlIdentifiers());
+        platform.setDelimitedIdentifierModeOn(isUseDelimitedSqlIdentifiers());
 
         return platform;
     }

Modified: db/ddlutils/trunk/src/java/org/apache/ddlutils/task/WriteSchemaSqlToFileCommand.java
URL: http://svn.apache.org/viewcvs/db/ddlutils/trunk/src/java/org/apache/ddlutils/task/WriteSchemaSqlToFileCommand.java?rev=383130&r1=383129&r2=383130&view=diff
==============================================================================
--- db/ddlutils/trunk/src/java/org/apache/ddlutils/task/WriteSchemaSqlToFileCommand.java (original)
+++ db/ddlutils/trunk/src/java/org/apache/ddlutils/task/WriteSchemaSqlToFileCommand.java Sat Mar  4 07:08:59 2006
@@ -108,7 +108,7 @@
         }
 
         Platform           platform        = getPlatform();
-        boolean            isCaseSensitive = platform.getPlatformInfo().isUseDelimitedIdentifiers();
+        boolean            isCaseSensitive = platform.isDelimitedIdentifierModeOn();
         CreationParameters params          = getFilteredParameters(model, platform.getName(), isCaseSensitive);
         Connection         connection      = null;
 

Modified: db/ddlutils/trunk/src/java/org/apache/ddlutils/task/WriteSchemaToDatabaseCommand.java
URL: http://svn.apache.org/viewcvs/db/ddlutils/trunk/src/java/org/apache/ddlutils/task/WriteSchemaToDatabaseCommand.java?rev=383130&r1=383129&r2=383130&view=diff
==============================================================================
--- db/ddlutils/trunk/src/java/org/apache/ddlutils/task/WriteSchemaToDatabaseCommand.java (original)
+++ db/ddlutils/trunk/src/java/org/apache/ddlutils/task/WriteSchemaToDatabaseCommand.java Sat Mar  4 07:08:59 2006
@@ -87,7 +87,7 @@
         }
 
         Platform           platform        = getPlatform();
-        boolean            isCaseSensitive = platform.getPlatformInfo().isUseDelimitedIdentifiers();
+        boolean            isCaseSensitive = platform.isDelimitedIdentifierModeOn();
         CreationParameters params          = getFilteredParameters(model, platform.getName(), isCaseSensitive);
 
         // we're disabling the comment generation as it is not interesting in this case anyway

Modified: db/ddlutils/trunk/src/java/org/apache/ddlutils/util/DatabaseTestHelper.java
URL: http://svn.apache.org/viewcvs/db/ddlutils/trunk/src/java/org/apache/ddlutils/util/DatabaseTestHelper.java?rev=383130&r1=383129&r2=383130&view=diff
==============================================================================
--- db/ddlutils/trunk/src/java/org/apache/ddlutils/util/DatabaseTestHelper.java (original)
+++ db/ddlutils/trunk/src/java/org/apache/ddlutils/util/DatabaseTestHelper.java Sat Mar  4 07:08:59 2006
@@ -18,16 +18,17 @@
 
 import java.util.Collection;
 import java.util.Iterator;
+
+import junit.framework.Assert;
+import junit.framework.AssertionFailedError;
+
 import org.apache.commons.beanutils.DynaBean;
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.LogFactory;
 import org.apache.ddlutils.Platform;
-import org.apache.ddlutils.PlatformInfo;
 import org.apache.ddlutils.model.Column;
 import org.apache.ddlutils.model.Database;
 import org.apache.ddlutils.model.Table;
-import junit.framework.Assert;
-import junit.framework.AssertionFailedError;
 
 /**
  * Class that provides utility stuff for cpmaring data in databases.
@@ -75,10 +76,10 @@
             Table    table  = model.getTable(idx);
             Column[] pkCols = table.getPrimaryKeyColumns();
 
-            for (Iterator it = origDbPlatform.query(model, buildQueryString(origDbPlatform.getPlatformInfo(), table, null, null), new Table[] { table }); it.hasNext();)
+            for (Iterator it = origDbPlatform.query(model, buildQueryString(origDbPlatform, table, null, null), new Table[] { table }); it.hasNext();)
             {
                 DynaBean   obj    = (DynaBean)it.next();
-                Collection result = testedDbPlatform.fetch(model, buildQueryString(origDbPlatform.getPlatformInfo(), table, pkCols, obj), new Table[] { table });
+                Collection result = testedDbPlatform.fetch(model, buildQueryString(origDbPlatform, table, pkCols, obj), new Table[] { table });
 
                 if (result.isEmpty())
                 {
@@ -144,25 +145,25 @@
     /**
      * Helper method for build a SELECT statement.
      * 
-     * @param targetPlatformInfo The platform info for the queried database
-     * @param table              The queried table
-     * @param whereCols          The optional columns that make up the WHERE clause
-     * @param whereValues        The optional column value that make up the WHERE clause
+     * @param targetPlatform The platform for the queried database
+     * @param table          The queried table
+     * @param whereCols      The optional columns that make up the WHERE clause
+     * @param whereValues    The optional column value that make up the WHERE clause
      * @return The query string
      */
-    private String buildQueryString(PlatformInfo targetPlatformInfo, Table table, Column[] whereCols, DynaBean whereValues)
+    private String buildQueryString(Platform targetPlatform, Table table, Column[] whereCols, DynaBean whereValues)
     {
         StringBuffer result = new StringBuffer();
 
         result.append("SELECT * FROM ");
-        if (targetPlatformInfo.isUseDelimitedIdentifiers())
+        if (targetPlatform.isDelimitedIdentifierModeOn())
         {
-            result.append(targetPlatformInfo.getDelimiterToken());
+            result.append(targetPlatform.getPlatformInfo().getDelimiterToken());
         }
         result.append(table.getName());
-        if (targetPlatformInfo.isUseDelimitedIdentifiers())
+        if (targetPlatform.isDelimitedIdentifierModeOn())
         {
-            result.append(targetPlatformInfo.getDelimiterToken());
+            result.append(targetPlatform.getPlatformInfo().getDelimiterToken());
         }
         if ((whereCols != null) && (whereCols.length > 0))
         {
@@ -175,14 +176,14 @@
                 {
                     result.append(" AND ");
                 }
-                if (targetPlatformInfo.isUseDelimitedIdentifiers())
+                if (targetPlatform.isDelimitedIdentifierModeOn())
                 {
-                    result.append(targetPlatformInfo.getDelimiterToken());
+                    result.append(targetPlatform.getPlatformInfo().getDelimiterToken());
                 }
                 result.append(whereCols[idx].getName());
-                if (targetPlatformInfo.isUseDelimitedIdentifiers())
+                if (targetPlatform.isDelimitedIdentifierModeOn())
                 {
-                    result.append(targetPlatformInfo.getDelimiterToken());
+                    result.append(targetPlatform.getPlatformInfo().getDelimiterToken());
                 }
                 result.append(" = ");
                 if (value == null)
@@ -193,12 +194,12 @@
                 {
                     if (!whereCols[idx].isOfNumericType())
                     {
-                        result.append(targetPlatformInfo.getValueQuoteToken());
+                        result.append(targetPlatform.getPlatformInfo().getValueQuoteToken());
                     }
                     result.append(value.toString());
                     if (!whereCols[idx].isOfNumericType())
                     {
-                        result.append(targetPlatformInfo.getValueQuoteToken());
+                        result.append(targetPlatform.getPlatformInfo().getValueQuoteToken());
                     }
                 }
             }

Modified: db/ddlutils/trunk/src/test/org/apache/ddlutils/TestDatabaseWriterBase.java
URL: http://svn.apache.org/viewcvs/db/ddlutils/trunk/src/test/org/apache/ddlutils/TestDatabaseWriterBase.java?rev=383130&r1=383129&r2=383130&view=diff
==============================================================================
--- db/ddlutils/trunk/src/test/org/apache/ddlutils/TestDatabaseWriterBase.java (original)
+++ db/ddlutils/trunk/src/test/org/apache/ddlutils/TestDatabaseWriterBase.java Sat Mar  4 07:08:59 2006
@@ -343,7 +343,7 @@
      */
     protected Object getPropertyValue(DynaBean bean, String propName)
     {
-        if (getPlatform().getPlatformInfo().isCaseSensitive())
+        if (getPlatform().isDelimitedIdentifierModeOn())
         {
             return bean.get(propName);
         }

Modified: db/ddlutils/trunk/src/test/org/apache/ddlutils/io/RoundtripTestBase.java
URL: http://svn.apache.org/viewcvs/db/ddlutils/trunk/src/test/org/apache/ddlutils/io/RoundtripTestBase.java?rev=383130&r1=383129&r2=383130&view=diff
==============================================================================
--- db/ddlutils/trunk/src/test/org/apache/ddlutils/io/RoundtripTestBase.java (original)
+++ db/ddlutils/trunk/src/test/org/apache/ddlutils/io/RoundtripTestBase.java Sat Mar  4 07:08:59 2006
@@ -88,7 +88,7 @@
                     {
                         info = PlatformFactory.createNewPlatformInstance(newTest.getDatabaseName()).getPlatformInfo();
                     }
-                    if (info.isSupportingDelimitedIdentifiers())
+                    if (info.isDelimitedIdentifiersSupported())
                     {
                         newTest = (RoundtripTestBase)testedClass.newInstance();
                         newTest.setName(methods[idx].getName());
@@ -125,7 +125,7 @@
     protected void setUp() throws Exception
     {
         super.setUp();
-        getPlatformInfo().setUseDelimitedIdentifiers(_useDelimitedIdentifiers);
+        getPlatform().setDelimitedIdentifierModeOn(_useDelimitedIdentifiers);
     }
 
     /**
@@ -156,16 +156,16 @@
      */
     protected List getRows(String tableName)
     {
-        Table        table = getModel().findTable(tableName, getPlatformInfo().isCaseSensitive());
+        Table        table = getModel().findTable(tableName, getPlatform().isDelimitedIdentifierModeOn());
         StringBuffer query = new StringBuffer();
 
         query.append("SELECT * FROM ");
-        if (getPlatformInfo().isUseDelimitedIdentifiers())
+        if (getPlatform().isDelimitedIdentifierModeOn())
         {
             query.append(getPlatformInfo().getDelimiterToken());
         }
         query.append(table.getName());
-        if (getPlatformInfo().isUseDelimitedIdentifiers())
+        if (getPlatform().isDelimitedIdentifierModeOn())
         {
             query.append(getPlatformInfo().getDelimiterToken());
         }
@@ -221,7 +221,7 @@
                     }
                     // finally the platform might return a synthetic default value if the column
                     // is a primary key column
-                    if (getPlatformInfo().isReturningDefaultValueForRequired() &&
+                    if (getPlatformInfo().isSyntheticDefaultValueForRequiredReturned() &&
                         (column.getDefaultValue() == null) && column.isRequired() && !column.isAutoIncrement())
                     {
                         switch (column.getTypeCode())
@@ -423,7 +423,7 @@
         assertEquals("Required status not the same for column "+actual.getName()+".",
                      expected.isRequired(),
                      actual.isRequired());
-        if (getPlatformInfo().getCanReadAutoIncrementStatus())
+        if (getPlatformInfo().getAutoIncrementStatusReadingSupported())
         {
         	// we're only comparing this if the platform can actually read the
         	// auto-increment status back from an existing database

Modified: db/ddlutils/trunk/src/test/org/apache/ddlutils/io/TestConstraints.java
URL: http://svn.apache.org/viewcvs/db/ddlutils/trunk/src/test/org/apache/ddlutils/io/TestConstraints.java?rev=383130&r1=383129&r2=383130&view=diff
==============================================================================
--- db/ddlutils/trunk/src/test/org/apache/ddlutils/io/TestConstraints.java (original)
+++ db/ddlutils/trunk/src/test/org/apache/ddlutils/io/TestConstraints.java Sat Mar  4 07:08:59 2006
@@ -235,10 +235,10 @@
     public void testAutoIncrementIntegerColumn()
     {
         // only test this if the platform supports it
-        if (getPlatformInfo().isSupportingNonPKIdentityColumns())
+        if (getPlatformInfo().isNonPKIdentityColumnsSupported())
         {
             performConstraintsTest(TEST_AUTO_INCREMENT_INTEGER_MODEL,
-            		               getPlatformInfo().getCanReadAutoIncrementStatus());
+            		               getPlatformInfo().getAutoIncrementStatusReadingSupported());
         }
     }
 
@@ -248,7 +248,7 @@
     public void testPrimaryKeyAutoIncrementColumn()
     {
         performConstraintsTest(TEST_PRIMARY_KEY_AUTO_INCREMENT_MODEL,
-	                           getPlatformInfo().getCanReadAutoIncrementStatus());
+	                           getPlatformInfo().getAutoIncrementStatusReadingSupported());
     }
 
     /**
@@ -256,7 +256,7 @@
      */
     public void testIndex()
     {
-        if (getPlatformInfo().isSupportingNonUniqueIndices())
+        if (getPlatformInfo().isNonUniqueIndicesSupported())
         {
             performConstraintsTest(TEST_INDEX_MODEL, true);
         }
@@ -275,7 +275,7 @@
      */
     public void testPrimaryKeyIndex()
     {
-        if (getPlatformInfo().isSupportingNonUniqueIndices())
+        if (getPlatformInfo().isNonUniqueIndicesSupported())
         {
             performConstraintsTest(TEST_PRIMARY_KEY_INDEX_MODEL, true);
         }

Modified: db/ddlutils/trunk/src/test/org/apache/ddlutils/io/TestDatatypes.java
URL: http://svn.apache.org/viewcvs/db/ddlutils/trunk/src/test/org/apache/ddlutils/io/TestDatatypes.java?rev=383130&r1=383129&r2=383130&view=diff
==============================================================================
--- db/ddlutils/trunk/src/test/org/apache/ddlutils/io/TestDatatypes.java (original)
+++ db/ddlutils/trunk/src/test/org/apache/ddlutils/io/TestDatatypes.java Sat Mar  4 07:08:59 2006
@@ -760,7 +760,7 @@
      */
     public void testLongVarCharWithDefault()
     {
-        if (getPlatformInfo().isSupportingDefaultValuesForLongTypes())
+        if (getPlatformInfo().isDefaultValuesForLongTypesSupported())
         {
             String value = "1234567890123456789012345678901234567890123456789012345678901234"+
                            "1234567890123456789012345678901234567890123456789012345678901234"+

Modified: db/ddlutils/trunk/src/test/org/apache/ddlutils/platform/SqlBuilderTest.java
URL: http://svn.apache.org/viewcvs/db/ddlutils/trunk/src/test/org/apache/ddlutils/platform/SqlBuilderTest.java?rev=383130&r1=383129&r2=383130&view=diff
==============================================================================
--- db/ddlutils/trunk/src/test/org/apache/ddlutils/platform/SqlBuilderTest.java (original)
+++ db/ddlutils/trunk/src/test/org/apache/ddlutils/platform/SqlBuilderTest.java Sat Mar  4 07:08:59 2006
@@ -19,7 +19,7 @@
 import java.util.HashMap;
 import java.util.Map;
 
-import org.apache.ddlutils.PlatformInfo;
+import org.apache.ddlutils.Platform;
 import org.apache.ddlutils.TestPlatformBase;
 import org.apache.ddlutils.model.Database;
 
@@ -53,7 +53,7 @@
      */
     public void testUpdateSql()
     {
-        SqlBuilder sqlBuilder = new SqlBuilderImpl(new PlatformInfo());
+        SqlBuilder sqlBuilder = new SqlBuilderImpl(getPlatform());
         Database   database   = parseDatabaseFromString(TEST_MODEL);
         Map        map        = new HashMap();
 
@@ -82,11 +82,11 @@
         /**
          * Creates a new instance.
          * 
-         * @param info The platform info
+         * @param platform The plaftform this builder belongs to
          */
-        public SqlBuilderImpl(PlatformInfo info)
+        public SqlBuilderImpl(Platform platform)
         {
-            super(info);
+            super(platform);
         }
     }
 }



Mime
View raw message