empire-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From doeb...@apache.org
Subject svn commit: r1184789 - in /incubator/empire-db/trunk: empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/ empire-db-struts2/src/main/java/org/apache/empire/struts2/exceptions/ empire-db/src/main/java/org/apache/empire/db/exceptions...
Date Sun, 16 Oct 2011 10:09:35 GMT
Author: doebele
Date: Sun Oct 16 10:09:34 2011
New Revision: 1184789

URL: http://svn.apache.org/viewvc?rev=1184789&view=rev
Log:
EMPIREDB-99
store error parameters as String[] instead of Object[] (prevents possible serialization problems)

Modified:
    incubator/empire-db/trunk/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/ActionError.java
    incubator/empire-db/trunk/empire-db-struts2/src/main/java/org/apache/empire/struts2/exceptions/WebException.java
    incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/DatabaseNotOpenException.java
    incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/FieldIllegalValueException.java
    incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/FieldIsReadOnlyException.java
    incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/FieldNotNullException.java
    incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/FieldValueException.java
    incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/FieldValueTooLongException.java
    incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/InternalSQLException.java
    incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/InvalidKeyException.java
    incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/NoPrimaryKeyException.java
    incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/QueryFailedException.java
    incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/QueryNoResultException.java
    incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/RecordDeleteFailedException.java
    incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/RecordNotFoundException.java
    incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/RecordUpdateFailedException.java
    incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/RecordUpdateInvalidException.java
    incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/BeanIncompatibleException.java
    incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/BeanInstantiationException.java
    incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/BeanPropertyGetException.java
    incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/BeanPropertySetException.java
    incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/EmpireException.java
    incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/EmpireFileException.java
    incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/FileParseException.java
    incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/FileReadException.java
    incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/FileWriteException.java
    incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/InternalException.java
    incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/InvalidArgumentException.java
    incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/InvalidPropertyException.java
    incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/ItemExistsException.java
    incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/ItemNotFoundException.java
    incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/MiscellaneousErrorException.java
    incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/NotImplementedException.java
    incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/NotSupportedException.java
    incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/ObjectNotValidException.java
    incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/PropertyReadOnlyException.java
    incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/UnexpectedReturnValueException.java

Modified: incubator/empire-db/trunk/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/ActionError.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/trunk/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/ActionError.java?rev=1184789&r1=1184788&r2=1184789&view=diff
==============================================================================
--- incubator/empire-db/trunk/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/ActionError.java
(original)
+++ incubator/empire-db/trunk/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/ActionError.java
Sun Oct 16 10:09:34 2011
@@ -81,7 +81,7 @@ public class ActionError implements Erro
     {
         // copy other error
         errType   = e.getErrorType();
-        errParams =(String[]) e.getErrorParams();
+        errParams = e.getErrorParams();
         errMsg    = e.getMessage();
     }
 

Modified: incubator/empire-db/trunk/empire-db-struts2/src/main/java/org/apache/empire/struts2/exceptions/WebException.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/trunk/empire-db-struts2/src/main/java/org/apache/empire/struts2/exceptions/WebException.java?rev=1184789&r1=1184788&r2=1184789&view=diff
==============================================================================
--- incubator/empire-db/trunk/empire-db-struts2/src/main/java/org/apache/empire/struts2/exceptions/WebException.java
(original)
+++ incubator/empire-db/trunk/empire-db-struts2/src/main/java/org/apache/empire/struts2/exceptions/WebException.java
Sun Oct 16 10:09:34 2011
@@ -37,7 +37,7 @@ public abstract class WebException exten
      * @param params
      * @param cause
      */
-    protected WebException(final ErrorType errType, final Object[] params)
+    protected WebException(final ErrorType errType, final String[] params)
     {
         super(errType, params, null);
     }

Modified: incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/DatabaseNotOpenException.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/DatabaseNotOpenException.java?rev=1184789&r1=1184788&r2=1184789&view=diff
==============================================================================
--- incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/DatabaseNotOpenException.java
(original)
+++ incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/DatabaseNotOpenException.java
Sun Oct 16 10:09:34 2011
@@ -34,6 +34,6 @@ public class DatabaseNotOpenException ex
     
     public DatabaseNotOpenException(DBDatabase db)
     {
-        super(errorType, new Object[] { (db!=null && StringUtils.isNotEmpty(db.getSchema()))
? db.getSchema() : "{NO_SCHEMA}"  });
+        super(errorType, new String[] { (db!=null && StringUtils.isNotEmpty(db.getSchema()))
? db.getSchema() : "{NO_SCHEMA}"  });
     }
 }

Modified: incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/FieldIllegalValueException.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/FieldIllegalValueException.java?rev=1184789&r1=1184788&r2=1184789&view=diff
==============================================================================
--- incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/FieldIllegalValueException.java
(original)
+++ incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/FieldIllegalValueException.java
Sun Oct 16 10:09:34 2011
@@ -32,11 +32,11 @@ public class FieldIllegalValueException 
     
     public FieldIllegalValueException(DBColumn column, String value, Throwable cause)
     {
-        super(column, errorType, new Object[] { column.getFullName(), value }, cause);
+        super(column, errorType, new String[] { column.getFullName(), value }, cause);
     }
     
     public FieldIllegalValueException(DBColumn column, String value)
     {
-        super(column, errorType, new Object[] { column.getFullName(), value }, null);
+        super(column, errorType, new String[] { column.getFullName(), value }, null);
     }
 }

Modified: incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/FieldIsReadOnlyException.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/FieldIsReadOnlyException.java?rev=1184789&r1=1184788&r2=1184789&view=diff
==============================================================================
--- incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/FieldIsReadOnlyException.java
(original)
+++ incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/FieldIsReadOnlyException.java
Sun Oct 16 10:09:34 2011
@@ -33,6 +33,6 @@ public class FieldIsReadOnlyException ex
     
     public FieldIsReadOnlyException(DBColumn col)
     {
-        super(errorType, new Object[] { col.getFullName() });
+        super(errorType, new String[] { col.getFullName() });
     }
 }

Modified: incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/FieldNotNullException.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/FieldNotNullException.java?rev=1184789&r1=1184788&r2=1184789&view=diff
==============================================================================
--- incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/FieldNotNullException.java
(original)
+++ incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/FieldNotNullException.java
Sun Oct 16 10:09:34 2011
@@ -33,6 +33,6 @@ public class FieldNotNullException exten
     
     public FieldNotNullException(DBColumn col)
     {
-        super(errorType, new Object[] { col.getFullName() });
+        super(errorType, new String[] { col.getFullName() });
     }
 }

Modified: incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/FieldValueException.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/FieldValueException.java?rev=1184789&r1=1184788&r2=1184789&view=diff
==============================================================================
--- incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/FieldValueException.java
(original)
+++ incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/FieldValueException.java
Sun Oct 16 10:09:34 2011
@@ -31,7 +31,7 @@ public abstract class FieldValueExceptio
     
     private transient final DBColumn column;
 
-    protected FieldValueException(final DBColumn column, final ErrorType errType, final Object[]
params, final Throwable cause)
+    protected FieldValueException(final DBColumn column, final ErrorType errType, final String[]
params, final Throwable cause)
     {
         super(errType, params, cause);
         // save type and params for custom message formatting

Modified: incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/FieldValueTooLongException.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/FieldValueTooLongException.java?rev=1184789&r1=1184788&r2=1184789&view=diff
==============================================================================
--- incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/FieldValueTooLongException.java
(original)
+++ incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/FieldValueTooLongException.java
Sun Oct 16 10:09:34 2011
@@ -33,6 +33,6 @@ public class FieldValueTooLongException 
     
     public FieldValueTooLongException(DBColumn col)
     {
-        super(errorType, new Object[] { col.getFullName(), (int)col.getSize() });
+        super(errorType, new String[] { col.getFullName(), String.valueOf((int)col.getSize())
});
     }
 }

Modified: incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/InternalSQLException.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/InternalSQLException.java?rev=1184789&r1=1184788&r2=1184789&view=diff
==============================================================================
--- incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/InternalSQLException.java
(original)
+++ incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/InternalSQLException.java
Sun Oct 16 10:09:34 2011
@@ -46,7 +46,7 @@ public class InternalSQLException extend
     
     public InternalSQLException(DBDatabaseDriver driver, SQLException cause)
     {
-        super(errorType, new Object[] { messageFromSQLException(driver, cause) }, cause );
+        super(errorType, new String[] { messageFromSQLException(driver, cause) }, cause );
     }
     
     public InternalSQLException(DBObject obj, SQLException cause)
@@ -55,7 +55,7 @@ public class InternalSQLException extend
     }
     
     // Derived classes only
-    protected InternalSQLException(ErrorType type, Object[] params, SQLException cause)
+    protected InternalSQLException(ErrorType type, String[] params, SQLException cause)
     {
         super(type, params, cause);
     }

Modified: incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/InvalidKeyException.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/InvalidKeyException.java?rev=1184789&r1=1184788&r2=1184789&view=diff
==============================================================================
--- incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/InvalidKeyException.java
(original)
+++ incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/InvalidKeyException.java
Sun Oct 16 10:09:34 2011
@@ -34,6 +34,6 @@ public class InvalidKeyException extends
     
     public InvalidKeyException(DBRowSet rowset, Object[] key)
     {
-        super(errorType, new Object[] { StringUtils.toString(key), StringUtils.coalesce(rowset.getName(),
rowset.getAlias()) });
+        super(errorType, new String[] { StringUtils.toString(key), StringUtils.coalesce(rowset.getName(),
rowset.getAlias()) });
     }
 }

Modified: incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/NoPrimaryKeyException.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/NoPrimaryKeyException.java?rev=1184789&r1=1184788&r2=1184789&view=diff
==============================================================================
--- incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/NoPrimaryKeyException.java
(original)
+++ incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/NoPrimaryKeyException.java
Sun Oct 16 10:09:34 2011
@@ -34,6 +34,6 @@ public class NoPrimaryKeyException exten
     
     public NoPrimaryKeyException(DBRowSet rowset)
     {
-        super(errorType, new Object[] { StringUtils.coalesce(rowset.getName(), rowset.getAlias())
});
+        super(errorType, new String[] { StringUtils.coalesce(rowset.getName(), rowset.getAlias())
});
     }
 }

Modified: incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/QueryFailedException.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/QueryFailedException.java?rev=1184789&r1=1184788&r2=1184789&view=diff
==============================================================================
--- incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/QueryFailedException.java
(original)
+++ incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/QueryFailedException.java
Sun Oct 16 10:09:34 2011
@@ -40,7 +40,7 @@ public class QueryFailedException extend
     
     public QueryFailedException(DBObject obj, String sqlCmd, SQLException cause)
     {
-        super(errorType, new Object[] { sqlCmd, InternalSQLException.messageFromSQLException(InternalSQLException.driverFromObject(obj),
cause) }, cause);
+        super(errorType, new String[] { sqlCmd, InternalSQLException.messageFromSQLException(InternalSQLException.driverFromObject(obj),
cause) }, cause);
     }
     
     /**

Modified: incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/QueryNoResultException.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/QueryNoResultException.java?rev=1184789&r1=1184788&r2=1184789&view=diff
==============================================================================
--- incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/QueryNoResultException.java
(original)
+++ incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/QueryNoResultException.java
Sun Oct 16 10:09:34 2011
@@ -32,6 +32,6 @@ public class QueryNoResultException exte
     
     public QueryNoResultException(String sqlCmd)
     {
-        super(errorType, new Object[] { sqlCmd });
+        super(errorType, new String[] { sqlCmd });
     }
 }

Modified: incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/RecordDeleteFailedException.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/RecordDeleteFailedException.java?rev=1184789&r1=1184788&r2=1184789&view=diff
==============================================================================
--- incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/RecordDeleteFailedException.java
(original)
+++ incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/RecordDeleteFailedException.java
Sun Oct 16 10:09:34 2011
@@ -34,6 +34,6 @@ public class RecordDeleteFailedException
     
     public RecordDeleteFailedException(DBRowSet rowset, Object[] key)
     {
-        super(errorType, new Object[] { StringUtils.toString(key), StringUtils.coalesce(rowset.getName(),
rowset.getAlias()) });
+        super(errorType, new String[] { StringUtils.toString(key), StringUtils.coalesce(rowset.getName(),
rowset.getAlias()) });
     }
 }

Modified: incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/RecordNotFoundException.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/RecordNotFoundException.java?rev=1184789&r1=1184788&r2=1184789&view=diff
==============================================================================
--- incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/RecordNotFoundException.java
(original)
+++ incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/RecordNotFoundException.java
Sun Oct 16 10:09:34 2011
@@ -34,6 +34,6 @@ public class RecordNotFoundException ext
     
     public RecordNotFoundException(DBRowSet rowset, Object[] key)
     {
-        super(errorType, new Object[] { StringUtils.toString(key), StringUtils.coalesce(rowset.getName(),
rowset.getAlias()) });
+        super(errorType, new String[] { StringUtils.toString(key), StringUtils.coalesce(rowset.getName(),
rowset.getAlias()) });
     }
 }

Modified: incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/RecordUpdateFailedException.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/RecordUpdateFailedException.java?rev=1184789&r1=1184788&r2=1184789&view=diff
==============================================================================
--- incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/RecordUpdateFailedException.java
(original)
+++ incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/RecordUpdateFailedException.java
Sun Oct 16 10:09:34 2011
@@ -34,6 +34,6 @@ public class RecordUpdateFailedException
     
     public RecordUpdateFailedException(DBRowSet rowset, Object[] key)
     {
-        super(errorType, new Object[] { StringUtils.toString(key), StringUtils.coalesce(rowset.getName(),
rowset.getAlias()) });
+        super(errorType, new String[] { StringUtils.toString(key), StringUtils.coalesce(rowset.getName(),
rowset.getAlias()) });
     }
 }

Modified: incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/RecordUpdateInvalidException.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/RecordUpdateInvalidException.java?rev=1184789&r1=1184788&r2=1184789&view=diff
==============================================================================
--- incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/RecordUpdateInvalidException.java
(original)
+++ incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/db/exceptions/RecordUpdateInvalidException.java
Sun Oct 16 10:09:34 2011
@@ -34,6 +34,6 @@ public class RecordUpdateInvalidExceptio
     
     public RecordUpdateInvalidException(DBRowSet rowset, Object[] key)
     {
-        super(errorType, new Object[] { StringUtils.toString(key), StringUtils.coalesce(rowset.getName(),
rowset.getAlias()) });
+        super(errorType, new String[] { StringUtils.toString(key), StringUtils.coalesce(rowset.getName(),
rowset.getAlias()) });
     }
 }

Modified: incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/BeanIncompatibleException.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/BeanIncompatibleException.java?rev=1184789&r1=1184788&r2=1184789&view=diff
==============================================================================
--- incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/BeanIncompatibleException.java
(original)
+++ incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/BeanIncompatibleException.java
Sun Oct 16 10:09:34 2011
@@ -32,6 +32,6 @@ public class BeanIncompatibleException e
     
     public BeanIncompatibleException(Class<?> clazz, DBRowSet rowset)
     {
-        super(errorType, new Object[] { clazz.getName(), rowset.getName() });
+        super(errorType, new String[] { clazz.getName(), rowset.getName() });
     }
 }

Modified: incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/BeanInstantiationException.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/BeanInstantiationException.java?rev=1184789&r1=1184788&r2=1184789&view=diff
==============================================================================
--- incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/BeanInstantiationException.java
(original)
+++ incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/BeanInstantiationException.java
Sun Oct 16 10:09:34 2011
@@ -36,7 +36,7 @@ public class BeanInstantiationException 
     
     public BeanInstantiationException(Class<?> clazz, Throwable cause)
     {
-        super(errorType, new Object[] { clazz.getName() }, cause);
+        super(errorType, new String[] { clazz.getName() }, cause);
     }
     
     /**

Modified: incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/BeanPropertyGetException.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/BeanPropertyGetException.java?rev=1184789&r1=1184788&r2=1184789&view=diff
==============================================================================
--- incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/BeanPropertyGetException.java
(original)
+++ incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/BeanPropertyGetException.java
Sun Oct 16 10:09:34 2011
@@ -36,7 +36,7 @@ public class BeanPropertyGetException ex
     
     public BeanPropertyGetException(Object bean, String property, Throwable cause)
     {
-        super(errorType, new Object[] { property, (bean!=null ? bean.getClass().getName()
: "{unknown}") }, cause);
+        super(errorType, new String[] { property, (bean!=null ? bean.getClass().getName()
: "{unknown}") }, cause);
     }
     
     /**

Modified: incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/BeanPropertySetException.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/BeanPropertySetException.java?rev=1184789&r1=1184788&r2=1184789&view=diff
==============================================================================
--- incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/BeanPropertySetException.java
(original)
+++ incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/BeanPropertySetException.java
Sun Oct 16 10:09:34 2011
@@ -36,7 +36,7 @@ public class BeanPropertySetException ex
     
     public BeanPropertySetException(Object bean, String property, Throwable cause)
     {
-        super(errorType, new Object[] { property, (bean!=null ? bean.getClass().getName()
: "{unknown}") }, cause);
+        super(errorType, new String[] { property, (bean!=null ? bean.getClass().getName()
: "{unknown}") }, cause);
     }
     
     /**

Modified: incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/EmpireException.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/EmpireException.java?rev=1184789&r1=1184788&r2=1184789&view=diff
==============================================================================
--- incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/EmpireException.java
(original)
+++ incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/EmpireException.java
Sun Oct 16 10:09:34 2011
@@ -18,12 +18,9 @@
  */
 package org.apache.empire.exceptions;
 
-import java.io.IOException;
-import java.io.ObjectOutputStream;
 import java.text.MessageFormat;
 
 import org.apache.empire.commons.ErrorType;
-import org.apache.empire.commons.StringUtils;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -40,10 +37,10 @@ public class EmpireException extends Run
     private static final long serialVersionUID = 1L;
     
     private final ErrorType errorType;
-    private final Object[]  errorParams;
+    private final String[]  errorParams;
     // private final String errorSourceClassname;
     
-    private static String formatErrorMessage(final ErrorType errType, final Object[] params)
+    private static String formatErrorMessage(final ErrorType errType, final String[] params)
     {
         // Check parameter count
         int paramCount = (params!=null) ? params.length : 0;
@@ -53,7 +50,7 @@ public class EmpireException extends Run
                    + "\nArguments supplied= " + String.valueOf(paramCount) + "; Arguments
expected= " + String.valueOf(errType.getNumParams()));
         }
         // Log Error
-        String msg = MessageFormat.format(errType.getMessagePattern(), params);
+        String msg = MessageFormat.format(errType.getMessagePattern(), (Object[])params);
         return msg;
     }
     
@@ -63,7 +60,7 @@ public class EmpireException extends Run
      * @param params
      * @param cause
      */
-    protected EmpireException(final ErrorType errType, final Object[] params, final Throwable
cause)
+    protected EmpireException(final ErrorType errType, final String[] params, final Throwable
cause)
     {
         super(formatErrorMessage(errType, params), cause);
         // save type and params for custom message formatting
@@ -78,7 +75,7 @@ public class EmpireException extends Run
      * @param params
      * @param cause
      */
-    protected EmpireException(final ErrorType errType, final Object[] params)
+    protected EmpireException(final ErrorType errType, final String[] params)
     {
         this(errType, params, null);
     }
@@ -107,16 +104,15 @@ public class EmpireException extends Run
      * @see org.apache.empire.commons.Errors
      * @return the type of error
      */
-    public Object[] getErrorParams()
+    public String[] getErrorParams()
     {
         return errorParams;
     }
 
     /**
-     * when serializing, convert all params to strings
+     * when serializing, convert all params to strings (unnesessary after change from object[]
to string[]
      * @param out
      * @throws IOException
-     */
     private void writeObject(ObjectOutputStream out) throws IOException
     {
         // normalize Params
@@ -136,4 +132,5 @@ public class EmpireException extends Run
         // Serialize
         out.defaultWriteObject(); 
     }
+    */
 }

Modified: incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/EmpireFileException.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/EmpireFileException.java?rev=1184789&r1=1184788&r2=1184789&view=diff
==============================================================================
--- incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/EmpireFileException.java
(original)
+++ incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/EmpireFileException.java
Sun Oct 16 10:09:34 2011
@@ -32,7 +32,7 @@ public abstract class EmpireFileExceptio
      */
     private static final long serialVersionUID = 1L;
 
-    protected EmpireFileException(final ErrorType errType, final Object[] params, final Throwable
cause)
+    protected EmpireFileException(final ErrorType errType, final String[] params, final Throwable
cause)
     {
         super(errType, params, cause);
     }

Modified: incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/FileParseException.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/FileParseException.java?rev=1184789&r1=1184788&r2=1184789&view=diff
==============================================================================
--- incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/FileParseException.java
(original)
+++ incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/FileParseException.java
Sun Oct 16 10:09:34 2011
@@ -31,7 +31,7 @@ public class FileParseException extends 
     
     public FileParseException(String fileName, Exception cause)
     {
-        super(errorType, new Object[] { fileName }, cause);
+        super(errorType, new String[] { fileName }, cause);
     }
     
     public FileParseException(String fileName)

Modified: incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/FileReadException.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/FileReadException.java?rev=1184789&r1=1184788&r2=1184789&view=diff
==============================================================================
--- incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/FileReadException.java
(original)
+++ incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/FileReadException.java
Sun Oct 16 10:09:34 2011
@@ -33,7 +33,7 @@ public class FileReadException extends E
     
     public FileReadException(String fileName, IOException cause)
     {
-        super(errorType, new Object[] { fileName, cause.toString() }, cause);
+        super(errorType, new String[] { fileName, cause.toString() }, cause);
     }
 
 }

Modified: incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/FileWriteException.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/FileWriteException.java?rev=1184789&r1=1184788&r2=1184789&view=diff
==============================================================================
--- incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/FileWriteException.java
(original)
+++ incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/FileWriteException.java
Sun Oct 16 10:09:34 2011
@@ -33,7 +33,7 @@ public class FileWriteException extends 
     
     public FileWriteException(String fileName, IOException cause)
     {
-        super(errorType, new Object[] { fileName, cause.toString() }, cause);
+        super(errorType, new String[] { fileName, cause.toString() }, cause);
     }
 
 }

Modified: incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/InternalException.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/InternalException.java?rev=1184789&r1=1184788&r2=1184789&view=diff
==============================================================================
--- incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/InternalException.java
(original)
+++ incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/InternalException.java
Sun Oct 16 10:09:34 2011
@@ -34,7 +34,7 @@ public class InternalException extends E
     
     public static final ErrorType errorType = new ErrorType("error.exception", "An Exception
of type {0} occurred.\n-->Message is: {1}\n-->at Position: {2}");
 
-    private static Object[] paramsFromThrowable(final Throwable exptn)
+    private static String[] paramsFromThrowable(final Throwable exptn)
     {
         // Exception
         String type  = exptn.getClass().getName();
@@ -46,7 +46,7 @@ public class InternalException extends E
         StackTraceElement[] stack = exptn.getStackTrace();
         String pos = (stack!=null) ? stack[0].toString() : "{unknown}";
         // Create Error
-        return new Object[] { type, msg, pos };
+        return new String[] { type, msg, pos };
     }
     
     public InternalException(Throwable cause)

Modified: incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/InvalidArgumentException.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/InvalidArgumentException.java?rev=1184789&r1=1184788&r2=1184789&view=diff
==============================================================================
--- incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/InvalidArgumentException.java
(original)
+++ incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/InvalidArgumentException.java
Sun Oct 16 10:09:34 2011
@@ -32,12 +32,12 @@ public class InvalidArgumentException ex
     
     public InvalidArgumentException(String param, Object value)
     {
-        super(errorType, new Object[] { value, param } );
+        super(errorType, new String[] { StringUtils.valueOf(value), param } );
     }
     
     public InvalidArgumentException(String param, Object[] value)
     {
-        super(errorType, new Object[] { StringUtils.valueOf(param), param } );
+        super(errorType, new String[] { StringUtils.valueOf(value), param } );
     }
 
 }

Modified: incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/InvalidPropertyException.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/InvalidPropertyException.java?rev=1184789&r1=1184788&r2=1184789&view=diff
==============================================================================
--- incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/InvalidPropertyException.java
(original)
+++ incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/InvalidPropertyException.java
Sun Oct 16 10:09:34 2011
@@ -32,6 +32,6 @@ public class InvalidPropertyException ex
     
     public InvalidPropertyException(String property, Object value)
     {
-        super(errorType, new Object[] { property, StringUtils.valueOf(value) });
+        super(errorType, new String[] { property, StringUtils.valueOf(value) });
     }
 }

Modified: incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/ItemExistsException.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/ItemExistsException.java?rev=1184789&r1=1184788&r2=1184789&view=diff
==============================================================================
--- incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/ItemExistsException.java
(original)
+++ incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/ItemExistsException.java
Sun Oct 16 10:09:34 2011
@@ -19,6 +19,7 @@
 package org.apache.empire.exceptions;
 
 import org.apache.empire.commons.ErrorType;
+import org.apache.empire.commons.StringUtils;
 
 public class ItemExistsException extends EmpireException
 {
@@ -31,7 +32,7 @@ public class ItemExistsException extends
     
     public ItemExistsException(Object item)
     {
-       super(errorType, new Object[] { (item!=null) ? item : "{unknown}" } );
+       super(errorType, new String[] { (item!=null) ? StringUtils.valueOf(item) : "{unknown}"
} );
     }
 
 }

Modified: incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/ItemNotFoundException.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/ItemNotFoundException.java?rev=1184789&r1=1184788&r2=1184789&view=diff
==============================================================================
--- incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/ItemNotFoundException.java
(original)
+++ incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/ItemNotFoundException.java
Sun Oct 16 10:09:34 2011
@@ -19,6 +19,7 @@
 package org.apache.empire.exceptions;
 
 import org.apache.empire.commons.ErrorType;
+import org.apache.empire.commons.StringUtils;
 
 public class ItemNotFoundException extends EmpireException
 {
@@ -31,7 +32,7 @@ public class ItemNotFoundException exten
     
     public ItemNotFoundException(Object item)
     {
-       super(errorType, new Object[] { (item!=null) ? item : "{unknown}" } );
+       super(errorType, new String[] { (item!=null) ? StringUtils.valueOf(item) : "{unknown}"
} );
     }
 
 }

Modified: incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/MiscellaneousErrorException.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/MiscellaneousErrorException.java?rev=1184789&r1=1184788&r2=1184789&view=diff
==============================================================================
--- incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/MiscellaneousErrorException.java
(original)
+++ incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/MiscellaneousErrorException.java
Sun Oct 16 10:09:34 2011
@@ -31,7 +31,7 @@ public class MiscellaneousErrorException
     
     public MiscellaneousErrorException(String errorMessage)
     {
-        super(errorType, new Object[] { errorMessage });
+        super(errorType, new String[] { errorMessage });
     }
 
 }

Modified: incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/NotImplementedException.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/NotImplementedException.java?rev=1184789&r1=1184788&r2=1184789&view=diff
==============================================================================
--- incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/NotImplementedException.java
(original)
+++ incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/NotImplementedException.java
Sun Oct 16 10:09:34 2011
@@ -31,7 +31,7 @@ public class NotImplementedException ext
     
     public NotImplementedException(Object object, String functionName)
     {
-        super(errorType, new Object[] { functionName, (object!=null ? object.getClass().getName()
: "{unknown}") });
+        super(errorType, new String[] { functionName, (object!=null ? object.getClass().getName()
: "{unknown}") });
     }
 
 }

Modified: incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/NotSupportedException.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/NotSupportedException.java?rev=1184789&r1=1184788&r2=1184789&view=diff
==============================================================================
--- incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/NotSupportedException.java
(original)
+++ incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/NotSupportedException.java
Sun Oct 16 10:09:34 2011
@@ -31,7 +31,7 @@ public class NotSupportedException exten
     
     public NotSupportedException(Object object, String functionName)
     {
-        super(errorType, new Object[] { functionName, (object!=null ? object.getClass().getName()
: "{unknown}") });
+        super(errorType, new String[] { functionName, (object!=null ? object.getClass().getName()
: "{unknown}") });
     }
 
 }

Modified: incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/ObjectNotValidException.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/ObjectNotValidException.java?rev=1184789&r1=1184788&r2=1184789&view=diff
==============================================================================
--- incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/ObjectNotValidException.java
(original)
+++ incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/ObjectNotValidException.java
Sun Oct 16 10:09:34 2011
@@ -31,7 +31,7 @@ public class ObjectNotValidException ext
     
     public ObjectNotValidException(Object obj)
     {
-        super(errorType, new Object[] { (obj!=null) ? obj.getClass().getName() : "{unknown}"
} );
+        super(errorType, new String[] { (obj!=null) ? obj.getClass().getName() : "{unknown}"
} );
     }
 
 }

Modified: incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/PropertyReadOnlyException.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/PropertyReadOnlyException.java?rev=1184789&r1=1184788&r2=1184789&view=diff
==============================================================================
--- incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/PropertyReadOnlyException.java
(original)
+++ incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/PropertyReadOnlyException.java
Sun Oct 16 10:09:34 2011
@@ -31,6 +31,6 @@ public class PropertyReadOnlyException e
     
     public PropertyReadOnlyException(String property)
     {
-        super(errorType, new Object[] { property });
+        super(errorType, new String[] { property });
     }
 }

Modified: incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/UnexpectedReturnValueException.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/UnexpectedReturnValueException.java?rev=1184789&r1=1184788&r2=1184789&view=diff
==============================================================================
--- incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/UnexpectedReturnValueException.java
(original)
+++ incubator/empire-db/trunk/empire-db/src/main/java/org/apache/empire/exceptions/UnexpectedReturnValueException.java
Sun Oct 16 10:09:34 2011
@@ -19,6 +19,7 @@
 package org.apache.empire.exceptions;
 
 import org.apache.empire.commons.ErrorType;
+import org.apache.empire.commons.StringUtils;
 
 public class UnexpectedReturnValueException extends EmpireException
 {
@@ -31,7 +32,7 @@ public class UnexpectedReturnValueExcept
     
     public UnexpectedReturnValueException(Object value, String function)
     {
-        super(errorType, new Object[] { value, function } );
+        super(errorType, new String[] { StringUtils.valueOf(value), function } );
     }
 
 }



Mime
View raw message