empire-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From doeb...@apache.org
Subject svn commit: r1158228 - in /incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2: action/ actionsupport/ exceptions/ jsp/components/ jsp/controls/ jsp/tags/ web/
Date Tue, 16 Aug 2011 12:23:54 GMT
Author: doebele
Date: Tue Aug 16 12:23:53 2011
New Revision: 1158228

URL: http://svn.apache.org/viewvc?rev=1158228&view=rev
Log:
EMPIREDB-99

Added:
    incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/action/ErrorInfo.java   (with props)
    incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/exceptions/   (with props)
    incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/exceptions/InvalidFormDataException.java   (with props)
    incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/exceptions/WebException.java   (with props)
    incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/web/FieldErrors.java   (contents, props changed)
      - copied, changed from r1153783, incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/web/WebErrors.java
Removed:
    incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/web/WebErrors.java
Modified:
    incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/action/ActionErrorProvider.java
    incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/action/RequestParamProvider.java
    incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/action/WebAction.java
    incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/ActionBase.java
    incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/ActionError.java
    incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/BeanActionSupport.java
    incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/BeanListActionSupport.java
    incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/FormActionSupport.java
    incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/ListActionSupport.java
    incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/ReaderListActionSupport.java
    incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/RecordActionSupport.java
    incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/RecordFormActionSupport.java
    incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/TextProviderActionSupport.java
    incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/components/CalendarComponent.java
    incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/components/ControlComponent.java
    incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/components/InputControlComponent.java
    incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/controls/InputControl.java
    incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/controls/PasswordInputControl.java
    incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/controls/TextAreaInputControl.java
    incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/controls/TextInputControl.java
    incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/tags/ActionErrorsTag.java
    incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/tags/EmpireTagSupport.java
    incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/tags/EmpireValueTagSupport.java

Modified: incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/action/ActionErrorProvider.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/action/ActionErrorProvider.java?rev=1158228&r1=1158227&r2=1158228&view=diff
==============================================================================
--- incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/action/ActionErrorProvider.java (original)
+++ incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/action/ActionErrorProvider.java Tue Aug 16 12:23:53 2011
@@ -20,8 +20,6 @@ package org.apache.empire.struts2.action
 
 import java.util.Map;
 
-import org.apache.empire.commons.ErrorInfo;
-
 
 public interface ActionErrorProvider
 {

Added: incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/action/ErrorInfo.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/action/ErrorInfo.java?rev=1158228&view=auto
==============================================================================
--- incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/action/ErrorInfo.java (added)
+++ incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/action/ErrorInfo.java Tue Aug 16 12:23:53 2011
@@ -0,0 +1,31 @@
+/*
+ * ESTEAM Software GmbH, 04.08.2011
+ */
+package org.apache.empire.struts2.action;
+
+import org.apache.empire.commons.ErrorType;
+
+public interface ErrorInfo
+{
+    /**
+     * Returns the last error code.
+     * 
+     * @return the error code of ERR_NONE if no error has been set.
+     */
+    ErrorType getErrorType();
+
+    /**
+     * Returns the parameters used to build the error text.
+     * 
+     * @return the error message or null if no error has been set.
+     */
+    String[] getErrorParams();
+
+    /**
+     * Returns the message associated with the last error.
+     *
+     * @return the error message or an empty string if no error has been set.
+     */
+    String getErrorMessage();
+
+}

Propchange: incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/action/ErrorInfo.java
------------------------------------------------------------------------------
    eol-style = native

Propchange: incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/action/ErrorInfo.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Modified: incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/action/RequestParamProvider.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/action/RequestParamProvider.java?rev=1158228&r1=1158227&r2=1158228&view=diff
==============================================================================
--- incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/action/RequestParamProvider.java (original)
+++ incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/action/RequestParamProvider.java Tue Aug 16 12:23:53 2011
@@ -22,7 +22,7 @@ import java.util.Map;
 
 public interface RequestParamProvider
 {
-    Map getRequestParameters();
+    Map<String,Object> getRequestParameters();
 
     boolean hasRequestParam(String param);
     

Modified: incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/action/WebAction.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/action/WebAction.java?rev=1158228&r1=1158227&r2=1158228&view=diff
==============================================================================
--- incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/action/WebAction.java (original)
+++ incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/action/WebAction.java Tue Aug 16 12:23:53 2011
@@ -25,12 +25,7 @@ import java.util.Locale;
 import java.util.Map;
 import java.util.ResourceBundle;
 
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-import org.apache.empire.commons.ErrorInfo;
-import org.apache.empire.commons.ErrorObject;
 import org.apache.empire.commons.ErrorType;
-import org.apache.empire.commons.Errors;
 import org.apache.empire.commons.ObjectUtils;
 import org.apache.empire.commons.StringUtils;
 import org.apache.empire.data.Column;
@@ -40,8 +35,10 @@ import org.apache.empire.struts2.actions
 import org.apache.empire.struts2.actionsupport.TextProviderActionSupport;
 import org.apache.empire.struts2.web.EmpireThreadManager;
 import org.apache.empire.struts2.web.UrlHelperEx;
-import org.apache.empire.struts2.web.WebErrors;
+import org.apache.empire.struts2.web.FieldErrors;
 import org.apache.empire.struts2.web.WebRequest;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 
 import com.opensymphony.xwork2.ActionContext;
 import com.opensymphony.xwork2.TextProvider;
@@ -190,7 +187,7 @@ public abstract class WebAction extends 
      */
     public String getLocalizedErrorMessage(ErrorInfo error)
     {   // Get the message
-        if (error==null || !error.hasError())
+        if (error==null) //  || !error.hasError())
             return "";
         // Translate the error
         String msgKey = error.getErrorType().getKey();
@@ -206,10 +203,12 @@ public abstract class WebAction extends 
             actionError = null;
             return; 
         }
+        /*
         if (error.hasError()==false)
         {   log.warn("setActionError: No error information supplied.");
             error = new ActionError(Errors.Internal, "No error information available!");
         }
+        */
         // We have an error
         if (error instanceof ActionError)
             actionError = ((ActionError)error);
@@ -225,12 +224,13 @@ public abstract class WebAction extends 
         setActionError(new ActionError(errType));
     }
 
-    protected final void setActionError(ErrorType errType, Object param)
+    protected final void setActionError(ErrorType errType, String param)
     {
         setActionError(new ActionError(errType, param));
     }
 
-    protected final void setActionError(Exception exception)
+    @Override
+    public final void setActionError(Exception exception)
     {
         setActionError(new ActionError(exception));
     }
@@ -253,14 +253,14 @@ public abstract class WebAction extends 
             fieldErrors = new LinkedHashMap<String, ErrorInfo>();
         // Error Message
         if (log.isWarnEnabled())
-            log.warn("Invlalid value for item or field " + item + " Message= " + ErrorObject.getMessage(error));
+            log.warn("Invlalid value for item or field " + item + " Message= " + error.getErrorMessage());
         // Map of errors
         fieldErrors.put(item, error);
     }
 
     protected void addItemError(String item, ErrorType errorType, String title, ErrorInfo error)
     {   // Check error
-        if (error.hasError()==false)
+        if (error==null) // .hasError()==false)
         {   log.error("addItemError has been called without an error provided!");
             return;
         }
@@ -278,7 +278,7 @@ public abstract class WebAction extends 
     @Override
     protected void addFieldError(String name, Column column, ErrorInfo error)
     {
-        addItemError(name, WebErrors.FieldError, column.getTitle(), error);
+        addItemError(name, FieldErrors.FieldError, column.getTitle(), error);
     }
     
     // ------- Action Message -------
@@ -425,7 +425,7 @@ public abstract class WebAction extends 
     
     // ------- Request Param accessors -------
     
-    public final Map getRequestParameters()
+    public final Map<String,Object> getRequestParameters()
     {
         ActionContext context = ActionContext.getContext();
         return (context!=null) ? context.getParameters() : null;
@@ -438,7 +438,7 @@ public abstract class WebAction extends 
     
     public final String getRequestParam(String param)
     {
-        Map params = getRequestParameters();
+        Map<String,Object> params = getRequestParameters();
         Object value = params.get( param );
         // Is the error provided?
         if (value==null)
@@ -452,7 +452,7 @@ public abstract class WebAction extends 
     
     public final String[] getRequestArrayParam(String param)
     {
-        Map params = getRequestParameters();
+        Map<String,Object> params = getRequestParameters();
         Object value = params.get( param );
         if (value==null)
             return null; // null is default
@@ -508,7 +508,7 @@ public abstract class WebAction extends 
      * @deprecated
      */
     @Deprecated
-    public String getActionURL(String action, Map parameters)
+    public String getActionURL(String action, Map<String,Object> parameters)
     {
         Object request = EmpireThreadManager.getCurrentRequest();
         if ((request instanceof WebRequest)==false)

Modified: incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/ActionBase.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/ActionBase.java?rev=1158228&r1=1158227&r2=1158228&view=diff
==============================================================================
--- incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/ActionBase.java (original)
+++ incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/ActionBase.java Tue Aug 16 12:23:53 2011
@@ -20,9 +20,6 @@ package org.apache.empire.struts2.action
 
 import java.sql.Connection;
 
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-import org.apache.empire.commons.ErrorInfo;
 import org.apache.empire.commons.StringUtils;
 import org.apache.empire.data.Column;
 import org.apache.empire.data.Record;
@@ -30,7 +27,10 @@ import org.apache.empire.db.DBColumn;
 import org.apache.empire.db.DBColumnExpr;
 import org.apache.empire.db.DBRowSet;
 import org.apache.empire.struts2.action.ActionItemProperty;
+import org.apache.empire.struts2.action.ErrorInfo;
 import org.apache.empire.struts2.action.RequestParamProvider;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 
 import com.opensymphony.xwork2.ActionContext;
 import com.opensymphony.xwork2.ActionInvocation;
@@ -51,6 +51,8 @@ public abstract class ActionBase
     
     protected abstract Connection getConnection(); 
 
+    public abstract void setActionError(Exception exception);
+
     protected abstract void addFieldError(String name, Column column, ErrorInfo error);
 
     public abstract int getListPageSize();
@@ -111,7 +113,7 @@ public abstract class ActionBase
         return proxy;
     }
     
-    protected String getActionBeanName(ActionContext context, Class objClass, String ownerProperty)
+    protected String getActionBeanName(ActionContext context, Class<?> objClass, String ownerProperty)
     {
         ActionProxy proxy = getActionProxy(context);
         if (proxy==null)
@@ -122,7 +124,7 @@ public abstract class ActionBase
         return proxy.getActionName()+ "." + ownerProperty + "." + objClass.getName();
     }
     
-    public Object getActionBean(Class objClass, boolean create, String ownerProperty)
+    public Object getActionBean(Class<?> objClass, boolean create, String ownerProperty)
     {
         if (objClass==null)
             return null;
@@ -144,7 +146,7 @@ public abstract class ActionBase
         return obj;
     }
 
-    public Object getActionBean(Class objClass, boolean create)
+    public Object getActionBean(Class<?> objClass, boolean create)
     {
         return getActionBean(objClass, create, null);
     }
@@ -168,7 +170,7 @@ public abstract class ActionBase
         putActionBean(obj, null);
     }
     
-    public void removeActionBean(Class objClass, String propertyName)
+    public void removeActionBean(Class<?> objClass, String propertyName)
     {
         if (objClass==null)
             return;
@@ -178,7 +180,7 @@ public abstract class ActionBase
             context.getSession().remove(key);
     }
 
-    public void removeActionBean(Class objClass)
+    public void removeActionBean(Class<?> objClass)
     {
         removeActionBean(objClass, null);
     }

Modified: incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/ActionError.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/ActionError.java?rev=1158228&r1=1158227&r2=1158228&view=diff
==============================================================================
--- incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/ActionError.java (original)
+++ incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/ActionError.java Tue Aug 16 12:23:53 2011
@@ -18,29 +18,42 @@
  */
 package org.apache.empire.struts2.actionsupport;
 
-import org.apache.empire.commons.ErrorInfo;
-import org.apache.empire.commons.ErrorObject;
+import java.text.MessageFormat;
+
 import org.apache.empire.commons.ErrorType;
-import org.apache.empire.commons.Errors;
+import org.apache.empire.exceptions.EmpireException;
+import org.apache.empire.exceptions.InternalException;
+import org.apache.empire.struts2.action.ErrorInfo;
 
-public class ActionError extends ErrorObject
+public class ActionError implements ErrorInfo
 {
-    private ObjectErrorInfo errorInfo = null;
+    private ErrorType errType;  // Type of error
+    private String[]  errParams;  // Error message params
+    private String    errMsg;
 
-    @Override
-    protected ObjectErrorInfo getErrorInfo(boolean create)
+    protected void clear()
     {
-        if (errorInfo==null && create)
-            errorInfo = new ObjectErrorInfo();
-        return errorInfo;
+        errType = null;
     }
-
-    @Override
-    protected void clearErrorInfo()
+    
+    public boolean hasError()
     {
-        errorInfo = null;
+        return (errType!=null);
     }
 
+    public ErrorType getErrorType()
+    {
+        return errType;
+    }
+    public String[] getErrorParams()
+    {
+        return errParams;
+    }
+    public String getErrorMessage()
+    {
+        return errMsg;
+    }
+    
     /**
      * Private constructor to prevent inheritance.
      * Other classes should not be derived from Action Error
@@ -59,56 +72,80 @@ public class ActionError extends ErrorOb
     public ActionError(ErrorInfo other)
     {
         // copy other error
-        error(other);
+        errType   = other.getErrorType();
+        errParams = other.getErrorParams();
+        errMsg    = other.getErrorMessage();
+    }
+
+    public ActionError(EmpireException e)
+    {
+        // copy other error
+        errType   = e.getErrorType();
+        errParams =(String[]) e.getErrorParams();
+        errMsg    = e.getMessage();
     }
 
+    public ActionError(Throwable e)
+    {
+        // copy other error
+        this(new InternalException(e));
+    }
+    
     /**
      * @see ErrorObject#error(ErrorType, Object[])
      */
-    public ActionError(ErrorType errType, Object[] params)
+    public ActionError(ErrorType errType, String[] params)
     {   // Set the Error
-        error(errType, params);
+        this.errType = errType;
+        this.errParams = params;
+        this.errMsg = MessageFormat.format(errType.getMessagePattern(), (Object[])params);
     }
 
     /**
-     * @see ErrorObject#error(ErrorType)
+     * @see ErrorObject#error(ErrorType, Object)
      */
-    public ActionError(ErrorType errType)
+    public ActionError(ErrorType errType, String param)
     {
-        error(errType);
+        this(errType, new String[] { param });
     }
 
     /**
-     * @see ErrorObject#error(ErrorType, Object)
+     * @see ErrorObject#error(ErrorType)
      */
-    public ActionError(ErrorType errType, Object param)
+    public ActionError(ErrorType errType)
     {
-        error(errType, param);
+        this(errType, (String[])null);
     }
 
     /**
      * @see ErrorObject#error(ErrorType, Object, Object)
      */
+    /*
     public ActionError(ErrorType errType, Object param1, Object param2)
     {
         error(errType, param1, param2);
     }
+    */
 
     /**
      * @see ErrorObject#error(ErrorType, Throwable)
      */
+    /*
     public ActionError(ErrorType errType, Exception exptn)
     {
         error(errType,  exptn);
     }
+    */
 
     /**
      * @see ErrorObject#error(Throwable)
      */
+    /*
     public ActionError(Throwable exptn)
     {
         error(Errors.Exception, exptn);
     }
+    */
     
     /**
      * @return the error message for this Action Error

Modified: incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/BeanActionSupport.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/BeanActionSupport.java?rev=1158228&r1=1158227&r2=1158228&view=diff
==============================================================================
--- incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/BeanActionSupport.java (original)
+++ incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/BeanActionSupport.java Tue Aug 16 12:23:53 2011
@@ -20,12 +20,12 @@ package org.apache.empire.struts2.action
 
 import java.util.List;
 
-import org.apache.empire.commons.Errors;
 import org.apache.empire.data.Column;
 import org.apache.empire.data.Record;
 import org.apache.empire.data.bean.BeanClass;
 import org.apache.empire.data.bean.BeanRecordProxy;
-import org.apache.empire.struts2.web.WebErrors;
+import org.apache.empire.exceptions.ObjectNotValidException;
+import org.apache.empire.struts2.exceptions.InvalidFormDataException;
 
 
 /**
@@ -171,27 +171,24 @@ public class BeanActionSupport<T> extend
      * Initializes the key columns of the current record from the action parameters. 
      * @return true if the key columns were set successfully of false otherwise
      */
-    public boolean initKeyColumns()
+    public void initKeyColumns()
     {
         // Action parameters
         Object[] keyValues = getActionParamKey();
         if (isValid()==false || keyValues==null)
-            return error(WebErrors.InvalidFormData);
+            throw new InvalidFormDataException();
         // Check Record
         if (record==null || !record.isValid())
-            return error(Errors.ObjectNotValid, "record");
+            throw new ObjectNotValidException(record);
         // Check Key Length
         Column[] keyColumns = record.getKeyColumns();
         if (keyValues.length!=keyColumns.length)
-            return error(WebErrors.InvalidFormData);
+            throw new InvalidFormDataException();
         // Copy values
         for (int i=0; i<keyColumns.length; i++)
         {   
-            if (!record.setValue(keyColumns[i], keyValues[i]))
-                return error(record);
+            record.setValue(keyColumns[i], keyValues[i]);
         }
-        // done
-        return success();
     }
     
 }

Modified: incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/BeanListActionSupport.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/BeanListActionSupport.java?rev=1158228&r1=1158227&r2=1158228&view=diff
==============================================================================
--- incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/BeanListActionSupport.java (original)
+++ incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/BeanListActionSupport.java Tue Aug 16 12:23:53 2011
@@ -58,25 +58,23 @@ public class BeanListActionSupport<T> ex
         DBReader reader = new DBReader();
         try {
             // Open Suppier Reader
-            if (!reader.open(cmd, action.getConnection() ))
-            {   return error(reader);
-            }
+            reader.open(cmd, action.getConnection());
             // Move to desired Position
             int first = this.getFirstItemIndex();
             if (first>0 && !reader.skipRows(first))
             {   // Page is not valid. Try again from beginning
                 reader.close();
                 setFirstItem(0);
-                return initBeanList(cmd);
+                initBeanList(cmd);
             }
             // Read List
             list = reader.getBeanList(beanClass, getPageSize());
-            if (list==null)
-            {   return error(reader);
-            }
-            // done
             return true;
             
+        } catch(Exception e ) {
+            action.setActionError(e);
+            return false;
+            
         } finally {
             reader.close();
         }

Modified: incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/FormActionSupport.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/FormActionSupport.java?rev=1158228&r1=1158227&r2=1158228&view=diff
==============================================================================
--- incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/FormActionSupport.java (original)
+++ incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/FormActionSupport.java Tue Aug 16 12:23:53 2011
@@ -18,15 +18,14 @@
  */
 package org.apache.empire.struts2.actionsupport;
 
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-import org.apache.empire.commons.ErrorInfo;
-import org.apache.empire.commons.ErrorObject;
 import org.apache.empire.commons.StringUtils;
 import org.apache.empire.data.Column;
+import org.apache.empire.struts2.action.ErrorInfo;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 
 
-public abstract class FormActionSupport extends ErrorObject
+public abstract class FormActionSupport
 {
     protected static Logger log = LoggerFactory.getLogger(FormActionSupport.class);
 

Modified: incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/ListActionSupport.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/ListActionSupport.java?rev=1158228&r1=1158227&r2=1158228&view=diff
==============================================================================
--- incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/ListActionSupport.java (original)
+++ incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/ListActionSupport.java Tue Aug 16 12:23:53 2011
@@ -18,12 +18,11 @@
  */
 package org.apache.empire.struts2.actionsupport;
 
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-import org.apache.empire.commons.ErrorObject;
 import org.apache.empire.data.ColumnExpr;
 import org.apache.empire.struts2.action.ListPagingInfo;
 import org.apache.empire.struts2.action.ListSortingInfo;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 
 
 /**
@@ -34,7 +33,7 @@ import org.apache.empire.struts2.action.
  * </p>
  * @author Rainer
  */
-public abstract class ListActionSupport extends ErrorObject
+public abstract class ListActionSupport
     implements ListPagingInfo, ListSortingInfo
 {
     protected static Logger log = LoggerFactory.getLogger(ListActionSupport.class);

Modified: incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/ReaderListActionSupport.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/ReaderListActionSupport.java?rev=1158228&r1=1158227&r2=1158228&view=diff
==============================================================================
--- incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/ReaderListActionSupport.java (original)
+++ incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/ReaderListActionSupport.java Tue Aug 16 12:23:53 2011
@@ -48,31 +48,27 @@ public class ReaderListActionSupport ext
         return reader;
     }
     
-    public boolean initReader(DBCommandExpr cmd, boolean scrollable)
+    public void initReader(DBCommandExpr cmd, boolean scrollable)
     {
         // Make sure previous reader is closed
         if (reader!=null)
             reader.close();
         // Create a new reader
         reader = new DBReader();
-        if (!reader.open(cmd, scrollable, action.getConnection() ))
-        {   return error(reader);
-        }
+        reader.open(cmd, scrollable, action.getConnection() );
         // Move to desired Position
         int first = this.getFirstItemIndex();
         if (first>0 && !reader.skipRows(first))
         {   // Page is not valid. Try again from beginning
             reader.close();
             setFirstItem(0);
-            return initReader(cmd);
+            initReader(cmd);
         }
-        // done
-        return true;
     }
     
-    public boolean initReader(DBCommandExpr cmd)
+    public void initReader(DBCommandExpr cmd)
     {
-        return initReader(cmd, false);
+        initReader(cmd, false);
     }
 
 }

Modified: incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/RecordActionSupport.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/RecordActionSupport.java?rev=1158228&r1=1158227&r2=1158228&view=diff
==============================================================================
--- incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/RecordActionSupport.java (original)
+++ incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/RecordActionSupport.java Tue Aug 16 12:23:53 2011
@@ -23,21 +23,26 @@ import java.util.ArrayList;
 import java.util.List;
 import java.util.Map;
 
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-import org.apache.empire.commons.Errors;
 import org.apache.empire.commons.StringUtils;
 import org.apache.empire.data.Record;
 import org.apache.empire.db.DBColumn;
 import org.apache.empire.db.DBCommand;
-import org.apache.empire.db.DBErrors;
 import org.apache.empire.db.DBIndex;
 import org.apache.empire.db.DBReader;
 import org.apache.empire.db.DBRecord;
 import org.apache.empire.db.DBRowSet;
 import org.apache.empire.db.DBTable;
+import org.apache.empire.db.exceptions.InvalidKeyException;
+import org.apache.empire.db.exceptions.NoPrimaryKeyException;
+import org.apache.empire.db.exceptions.QueryNoResultException;
 import org.apache.empire.db.expr.compare.DBCompareExpr;
-import org.apache.empire.struts2.web.WebErrors;
+import org.apache.empire.exceptions.EmpireException;
+import org.apache.empire.exceptions.ItemNotFoundException;
+import org.apache.empire.exceptions.NotSupportedException;
+import org.apache.empire.exceptions.ObjectNotValidException;
+import org.apache.empire.struts2.exceptions.InvalidFormDataException;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 
 
 /**
@@ -153,12 +158,18 @@ public class RecordActionSupport extends
      */
     public boolean createRecord()
     {
-        // initNew
-        if (!record.create(rowset, action.getConnection()))
-            return error(record);
-        // Save Record Key Info
-        persistOnSession();
-        return success();
+        try {
+            // initNew
+            record.create(rowset, action.getConnection());
+            // Save Record Key Info
+            persistOnSession();
+            return true;
+            
+        } catch(Exception e) {
+            // Action failed
+            action.setActionError(e);
+            return false;
+        }
     }
     
     /**
@@ -166,10 +177,9 @@ public class RecordActionSupport extends
      * The foreign key values must be supplied with the request.
      * @return true if all required foreign keys have been successfully set, or false otherwise
      */
-    public boolean initReferenceColumns()
+    public void initReferenceColumns()
     {
         // set Reference Values (if provided)
-        this.clearError();
         Map<DBColumn, DBColumn> refs = rowset.getColumnReferences();
         if (refs!=null)
         {   // Get Parent Columns from Request (if provided)
@@ -179,38 +189,33 @@ public class RecordActionSupport extends
                 String value = action.getRequestParam(name);
                 if (value!=null)
                 {
-                    if (StringUtils.isValid(value))
+                    if (StringUtils.isNotEmpty(value))
                         record.setValue(column, value);
                 }
                 else if (column.isRequired())
                 {   // Reference column not provided
                     log.warn("Value for reference column has not been provided!");
-                    error(Errors.ItemNotFound, name);
+                    throw new ItemNotFoundException(name);
                 }
             }
         }
-        return (hasError()==false);
     }
     
     /**
      * loads the record identified by the supplied key from the database<BR/>
      * @return true if the record has been successfully reloaded or false otherwise
      */
-    public boolean loadRecord(Object[] recKey)
+    public void loadRecord(Object[] recKey)
     {
         // Check Key
         if (recKey==null || recKey.length==0)
         {   // Invalid Record key
-            return error(DBErrors.RecordInvalidKey, recKey);
+            throw new InvalidKeyException(rowset, recKey);
         }
         // Record laden
-        if (record.read(rowset, recKey, action.getConnection()) == false)
-        {   // error
-            return error(record);
-        }
+        record.read(rowset, recKey, action.getConnection());
         // Save Record Key Info
         persistOnSession();
-        return success();
     }
     
     /**
@@ -219,13 +224,22 @@ public class RecordActionSupport extends
      */
     public boolean loadRecord()
     {   // Load 
-        Object[] key = getActionParamKey();
-        if (key==null && (persistence==SessionPersistence.Data))
-        {   // reload session record
-            return reloadRecord();
+        try {
+            Object[] key = getActionParamKey();
+            if (key==null && (persistence==SessionPersistence.Data))
+            {   // reload session record
+                reloadRecord();
+                return true;
+            }
+            // Load Record
+            loadRecord(key);
+            return true;
+
+        } catch(Exception e) {
+            // Action failed
+            action.setActionError(e);
+            return false;
         }
-        // Load Record
-        return loadRecord(key);
     }
     
     /**
@@ -234,7 +248,7 @@ public class RecordActionSupport extends
      * is reloaded from the database. 
      * @return true if the record has been successfully reloaded or false otherwise
      */
-    public boolean reloadRecord()
+    public void reloadRecord()
     {   // Load 
         switch(persistence)
         {
@@ -243,7 +257,7 @@ public class RecordActionSupport extends
             {   // Load from session key
                 String stKey = StringUtils.toString(action.getActionObject(getRecordPropertyName()));
                 Object[] key = action.getRecordKeyFromString(stKey);
-                return loadRecord(key);
+                loadRecord(key);
             }
             // Data persistence
             case Data:
@@ -252,17 +266,16 @@ public class RecordActionSupport extends
                 if (rec!=null && (rec instanceof DBRecord))
                 {   // Check rowset
                     if (((DBRecord)rec).getRowSet()!=rowset)
-                        return error(Errors.ObjectNotValid, "record");
+                        throw new ObjectNotValidException(rec);
                     // Record restored
                     this.record = (DBRecord)rec;
-                    return success();
                 }
                 // Record not found
-                return error(Errors.ItemNotFound, rowset.getName());
+                throw new ItemNotFoundException(rowset.getName());
             }
             // Other
             default:
-                return error(Errors.NotSupported, "reloadRecord[] " + String.valueOf(persistence));
+                throw new NotSupportedException(this, "reloadRecord[] " + String.valueOf(persistence));
         }
     }
     
@@ -274,32 +287,36 @@ public class RecordActionSupport extends
      */
     public boolean deleteRecord(Object[] recKey, boolean newRec)
     {
-        // Check Key
-        if (recKey==null || recKey.length==0)
-        {   // Invalid Record Key
-            return error(DBErrors.RecordInvalidKey, recKey);
-        }
-        if (newRec)
-        { 	// Record has not been saved yet!
-            record.close();
-            return success();
-        }
-        // Delete Record
-        if (loadBeforeDelete)
-        {   // load record and delete afterwards
-            if (record.read(rowset, recKey, action.getConnection()) == false ||
-                record.delete(action.getConnection()) == false)
-            {   // error
-                return error(record);
-            }
-        }
-        else if (rowset.deleteRecord(recKey, action.getConnection()) == false)
-        {   // rowset error
-            return error(rowset);
+        try {
+            // Check Key
+            if (recKey==null || recKey.length==0)
+            {   // Invalid Record Key
+                throw new InvalidKeyException(rowset, recKey);
+            }
+            if (newRec)
+            { 	// Record has not been saved yet!
+                record.close();
+                return true;
+            }
+            // Delete Record
+            if (loadBeforeDelete)
+            {   // load record and delete afterwards
+                record.read(rowset, recKey, action.getConnection());
+                record.delete(action.getConnection());
+            }
+            else
+            {   // rowset error
+                rowset.deleteRecord(recKey, action.getConnection());
+            }
+            // Success
+            removeFromSession();
+            return true;
+
+        } catch(Exception e) {
+            // Action failed
+            action.setActionError(e);
+            return false;
         }
-        // Success
-        removeFromSession();
-        return success();
     }
 
     /**
@@ -330,27 +347,31 @@ public class RecordActionSupport extends
      */
     public boolean loadFormData(Object[] recKey, boolean insert)
     {
-        // Check Key
-        if (recKey==null || recKey.length==0)
-        {   // Invalid Record key
-            return error(DBErrors.RecordInvalidKey, recKey);
-        }
-        // Prepare Update
-        Connection conn = action.getConnection();
-        if (!initUpdateRecord(recKey, insert, conn))
-            return false;
-        // Set Update Fields
-        if (!setUpdateFields(record))
+        try {
+            // Check Key
+            if (recKey==null || recKey.length==0)
+            {   // Invalid Record key
+                throw new InvalidKeyException(rowset, recKey);
+            }
+            // Prepare Update
+            Connection conn = action.getConnection();
+            initUpdateRecord(recKey, insert, conn);
+            // Set Update Fields
+            setUpdateFields(record);
+            // Done
+            persistOnSession();
+            return true;
+
+        } catch(Exception e) {
+            // Action failed
+            action.setActionError(e);
             return false;
-        // Done
-        persistOnSession();
-        return success();
+        }
     }
 
     @Override
     public boolean loadFormData()
     {
-        clearError();
         // Get Record Key
         Object[] recKey = getActionParamKey();
         boolean  insert = getActionParamNewFlag();
@@ -359,28 +380,31 @@ public class RecordActionSupport extends
     
     /**
      * Updates the record by calling onUpdateRecord and updates the currentKey
-     * The update will not be commited, hence the caller must commit or rollback
+     * The update will not be committed, hence the caller must commit or rollback
      * the operation
      * 
      * @return true if the update was successful otherwise false
      */
     public boolean saveChanges()
     {
-        // Record is not valid
-        if (record.isValid()==false)
-        {   
-            log.error("Cannot save changes: record ist not valid");
-            return error(Errors.ObjectNotValid, record.getClass().getName());
-        }
-        // Update Record
-        if (updateRecord(action.getConnection())==false)
-        {
-            log.error("Error updating record." + getErrorMessage());
+        try {
+            // Record is not valid
+            if (record.isValid()==false)
+            {   
+                log.error("Cannot save changes: record ist not valid");
+                throw new ObjectNotValidException(record);
+            }
+            // Update Record
+            updateRecord(action.getConnection());
+            // Save Record Key Info
+            persistOnSession();
+            return true;
+
+        } catch(Exception e) {
+            // Action failed
+            action.setActionError(e);
             return false;
         }
-        // Save Record Key Info
-        persistOnSession();
-        return success();
     }
     
     /**
@@ -479,15 +503,16 @@ public class RecordActionSupport extends
             // Query now
             DBReader reader = new DBReader();
             try { 
-                if (reader.getRecordData(cmd, action.getConnection()))
-                {   // We have found a record
-                    Object[] key = new Object[keyColumns.length];
-                    for (int i=0; i<keyColumns.length; i++)
-                    {   // Check if column has changed
-                        key[i] = reader.getValue(i);
-                    }
-                    return key;
+                reader.getRecordData(cmd, action.getConnection());
+                // We have found a record
+                Object[] key = new Object[keyColumns.length];
+                for (int i=0; i<keyColumns.length; i++)
+                {   // Check if column has changed
+                    key[i] = reader.getValue(i);
                 }
+                return key;
+            } catch(QueryNoResultException e) {
+                // ignore
             } finally {
                 reader.close();
             }
@@ -501,15 +526,15 @@ public class RecordActionSupport extends
     /**
      * overridable: onUpdateRecord
      */
-    protected boolean updateRecord(Connection conn)
+    protected void updateRecord(Connection conn)
     {
         // Modified?
         if (!record.isModified())
-            return success();
+            return;
         // Missing defaults?
         record.fillMissingDefaults(null);
         // Update Record
-        return (record.update(conn) ? success() : error(record));
+        record.update(conn);
     }
 
     // --------------------------- overrides --------------------------------
@@ -519,7 +544,13 @@ public class RecordActionSupport extends
     {
         if (verify)
         {   // Set Value with checking
-            return record.setValue(i, value);
+            try {
+                record.setValue(i, value);
+                return true;
+            } catch(EmpireException e) {
+                log.info("setRecordFieldValue failed. Message is {}.", e.getMessage());
+                return false;
+            }
         }
         else
         {   // No Checking
@@ -545,22 +576,21 @@ public class RecordActionSupport extends
      *            the primary key(s)
      * @param insert
      *            true if insert sql statement
-     * @retrun true if successfull otherwise false
      */
-    private boolean initUpdateRecord(Object[] keyValues, boolean insert, Connection conn)
+    private void initUpdateRecord(Object[] keyValues, boolean insert, Connection conn)
     { // Get the record key
         DBColumn[] keyColumns = rowset.getKeyColumns();
         if (keyColumns == null || keyColumns.length < 1)
-            return error(DBErrors.NoPrimaryKey, rowset.getName());
+            throw new NoPrimaryKeyException(rowset);
         if (keyValues == null || keyValues.length != keyColumns.length)
-            return error(DBErrors.RecordInvalidKey, keyValues, "keyValues");
+            throw new InvalidKeyException(rowset, keyValues);
         // Get Persistent record
         if (persistence==SessionPersistence.Data)
         {   // Get the record from the session
             Record rec = getRecordFromSession();
             if (rec==null || (rec instanceof DBRecord)==false)
             {   // Record restored
-                return error(WebErrors.InvalidFormData);
+                throw new InvalidFormDataException();
             }
             // Record not found
             record = (DBRecord)rec;
@@ -571,28 +601,24 @@ public class RecordActionSupport extends
             Object[] currentKey = record.getKeyValues();
             if (compareKey(currentKey, keyValues)==false)
             {   // Keys don't match
-                return error(WebErrors.InvalidFormData);
+                throw new InvalidFormDataException();
             }
             // We have a valid record
-            return success();
+            return;
         }
         // Insert
         if (insert)
         { // Initialize the Record
-            if (!record.init(rowset, keyValues, insert))
-                return error(record);
+            record.init(rowset, keyValues, insert);
             // Add the record
             // rec.state = DBRecord.REC_NEW;
             log.debug("Record '" + rowset.getName() + "' prepared for Insert!");
         } else
         { // Read the record from the db
-            if (!record.read(rowset, keyValues, conn))
-                return error(record);
+            record.read(rowset, keyValues, conn);
             // Record has been reloaded
             log.debug("Record '" + rowset.getName() + "' prepared for Update!");
         }
-        // Done
-        return success();
     }
     
 }

Modified: incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/RecordFormActionSupport.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/RecordFormActionSupport.java?rev=1158228&r1=1158227&r2=1158228&view=diff
==============================================================================
--- incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/RecordFormActionSupport.java (original)
+++ incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/RecordFormActionSupport.java Tue Aug 16 12:23:53 2011
@@ -22,16 +22,17 @@ import java.text.ParseException;
 import java.text.SimpleDateFormat;
 import java.util.Locale;
 
-import org.apache.empire.commons.ErrorInfo;
-import org.apache.empire.commons.Errors;
 import org.apache.empire.commons.ObjectUtils;
 import org.apache.empire.data.Column;
 import org.apache.empire.data.DataType;
 import org.apache.empire.data.Record;
 import org.apache.empire.db.DBDatabase;
+import org.apache.empire.exceptions.EmpireException;
+import org.apache.empire.exceptions.ObjectNotValidException;
+import org.apache.empire.struts2.action.ErrorInfo;
 import org.apache.empire.struts2.jsp.controls.InputControl;
 import org.apache.empire.struts2.jsp.controls.InputControlManager;
-import org.apache.empire.struts2.web.WebErrors;
+import org.apache.empire.struts2.web.FieldErrors;
 
 
 public abstract class RecordFormActionSupport extends FormActionSupport
@@ -199,12 +200,18 @@ public abstract class RecordFormActionSu
     @Override
     public boolean loadFormData()
     {
-        Record record = getRecord();
-        if (record.isValid()==false)
-            return error(Errors.ObjectNotValid, "record");
-        // Load Data
-        clearError();
-        return setUpdateFields(record);
+        try {
+            Record record = getRecord();
+            if (record.isValid()==false)
+                throw new ObjectNotValidException(record);
+            // Load Data
+            return setUpdateFields(record);
+
+        } catch(Exception e) {
+            // Action failed
+            action.setActionError(e);
+            return false;
+        }
     }
     
     // --------------------------- protected --------------------------------
@@ -218,7 +225,13 @@ public abstract class RecordFormActionSu
         if (ObjectUtils.isEmpty(value))
             value = null;
         // Set Value
-        return getRecord().setValue(i, value);
+        try {
+            getRecord().setValue(i, value);
+            return true;
+        } catch(EmpireException e) {
+            log.info("setRecordFieldValue failed. Message is {}.", e.getMessage());
+            return false;
+        }
     }
 
     /**
@@ -267,21 +280,20 @@ public abstract class RecordFormActionSu
                 // Check Value
                 if (value.equals(InputControl.NULL_VALUE) && col.isRequired())
                 {   // Oops, columns is required
-                    InputControl.FieldValueError fieldError = new InputControl.FieldValueError(WebErrors.InputValueRequired, null, "", control.getClass());
+                    InputControl.FieldValueError fieldError = new InputControl.FieldValueError(FieldErrors.InputValueRequired, null, "");
                     addFieldError(field, col, fieldError, value);
                     valid = false;
                     continue;
                 }
-                // Set Value
+                // set field value now
                 if (log.isInfoEnabled())
                     log.info("SetUpdateFields: setting field '" + col.getName() + "' to " + String.valueOf(value));
-                // Feldwert setzen
                 if (!setRecordFieldValue(i, value, true))
                 {   // Force to set field value
                     if (record instanceof ErrorInfo)
                         addFieldError(field, col, (ErrorInfo)record, value);
                     else
-                        addFieldError(field, col, new ActionError(WebErrors.InputInvalidValue), value);
+                        addFieldError(field, col, new ActionError(FieldErrors.InputInvalidValue), value);
                     // set Value
                     setRecordFieldValue(i, value, false);
                     valid = false;
@@ -324,7 +336,7 @@ public abstract class RecordFormActionSu
                 log.info("SetUpdateFields: Failed to modify record! At least one field error!");
             return false;
         }
-        return success();
+        return true;
     }
     
     /**

Modified: incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/TextProviderActionSupport.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/TextProviderActionSupport.java?rev=1158228&r1=1158227&r2=1158228&view=diff
==============================================================================
--- incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/TextProviderActionSupport.java (original)
+++ incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/actionsupport/TextProviderActionSupport.java Tue Aug 16 12:23:53 2011
@@ -61,7 +61,7 @@ public class TextProviderActionSupport e
 
     //  ------- Singleton getInstance -------
     
-    public static TextProvider getInstance(Class clazz, LocaleProvider provider)
+    public static TextProvider getInstance(Class<?> clazz, LocaleProvider provider)
     {
         TextProvider instance=new TextProviderActionSupport(provider);
         if (instance instanceof ResourceBundleTextProvider)

Propchange: incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/exceptions/
------------------------------------------------------------------------------
    eol-style = native

Added: incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/exceptions/InvalidFormDataException.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/exceptions/InvalidFormDataException.java?rev=1158228&view=auto
==============================================================================
--- incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/exceptions/InvalidFormDataException.java (added)
+++ incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/exceptions/InvalidFormDataException.java Tue Aug 16 12:23:53 2011
@@ -0,0 +1,22 @@
+/*
+ * ESTEAM Software GmbH, 16.08.2011
+ */
+package org.apache.empire.struts2.exceptions;
+
+import org.apache.empire.commons.ErrorType;
+
+public class InvalidFormDataException extends WebException
+{
+    /**
+     * Comment for <code>serialVersionUID</code>
+     */
+    private static final long serialVersionUID = 1L;
+    
+    public static final ErrorType errorType = new ErrorType("error.web.recordsDontMatch", "The form submitted is invalid for the current context.");
+    
+    public InvalidFormDataException()
+    {
+        super(errorType, null );
+    }
+
+}

Propchange: incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/exceptions/InvalidFormDataException.java
------------------------------------------------------------------------------
    eol-style = native

Propchange: incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/exceptions/InvalidFormDataException.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Added: incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/exceptions/WebException.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/exceptions/WebException.java?rev=1158228&view=auto
==============================================================================
--- incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/exceptions/WebException.java (added)
+++ incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/exceptions/WebException.java Tue Aug 16 12:23:53 2011
@@ -0,0 +1,30 @@
+/*
+ * ESTEAM Software GmbH, 16.08.2011
+ */
+package org.apache.empire.struts2.exceptions;
+
+import org.apache.empire.commons.ErrorType;
+import org.apache.empire.exceptions.EmpireException;
+
+public abstract class WebException extends EmpireException
+{
+    /**
+     * Comment for <code>serialVersionUID</code>
+     */
+    private static final long serialVersionUID = 1L;
+
+    /**
+     * Comment for <code>serialVersionUID</code>
+     */
+    /**
+     * Constructor for derived classes
+     * @param errType
+     * @param params
+     * @param cause
+     */
+    protected WebException(final ErrorType errType, final Object[] params)
+    {
+        super(errType, params, null);
+    }
+    
+}

Propchange: incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/exceptions/WebException.java
------------------------------------------------------------------------------
    eol-style = native

Propchange: incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/exceptions/WebException.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Modified: incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/components/CalendarComponent.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/components/CalendarComponent.java?rev=1158228&r1=1158227&r2=1158228&view=diff
==============================================================================
--- incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/components/CalendarComponent.java (original)
+++ incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/components/CalendarComponent.java Tue Aug 16 12:23:53 2011
@@ -197,7 +197,7 @@ public class CalendarComponent extends U
         weekCell.addAttribute("class", this.weekOfYearClass);
         weekCell.beginBody();
 
-        if(StringUtils.isValid(bodyText) && StringUtils.isValid(selectWeekAction))
+        if(StringUtils.isNotEmpty(bodyText) && StringUtils.isNotEmpty(selectWeekAction))
             renderLink(writer, bodyText, selectWeekAction, paramName, linkItem);
         else
             weekCell.endTag("");
@@ -381,7 +381,7 @@ public class CalendarComponent extends U
 
     public void setParamName(String paramName)
     {
-        if (StringUtils.isValid(paramName))
+        if (StringUtils.isNotEmpty(paramName))
             this.paramName = paramName;
     }
 

Modified: incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/components/ControlComponent.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/components/ControlComponent.java?rev=1158228&r1=1158227&r2=1158228&view=diff
==============================================================================
--- incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/components/ControlComponent.java (original)
+++ incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/components/ControlComponent.java Tue Aug 16 12:23:53 2011
@@ -164,7 +164,7 @@ public abstract class ControlComponent e
     @Override
     public boolean usesBody()
     {
-        return StringUtils.isValid(bodyUsage);
+        return StringUtils.isNotEmpty(bodyUsage);
     }
 
     public void setColumn(Column column)

Modified: incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/components/InputControlComponent.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/components/InputControlComponent.java?rev=1158228&r1=1158227&r2=1158228&view=diff
==============================================================================
--- incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/components/InputControlComponent.java (original)
+++ incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/components/InputControlComponent.java Tue Aug 16 12:23:53 2011
@@ -25,11 +25,11 @@ import java.util.Map;
 import javax.servlet.http.HttpServletRequest;
 import javax.servlet.http.HttpServletResponse;
 
-import org.apache.empire.commons.ErrorInfo;
 import org.apache.empire.commons.ObjectUtils;
 import org.apache.empire.commons.StringUtils;
 import org.apache.empire.data.DataType;
 import org.apache.empire.struts2.action.ActionErrorProvider;
+import org.apache.empire.struts2.action.ErrorInfo;
 import org.apache.empire.struts2.html.HtmlTagDictionary;
 import org.apache.empire.struts2.html.HtmlWriter;
 import org.apache.empire.struts2.html.HtmlWriter.HtmlTag;

Modified: incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/controls/InputControl.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/controls/InputControl.java?rev=1158228&r1=1158227&r2=1158228&view=diff
==============================================================================
--- incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/controls/InputControl.java (original)
+++ incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/controls/InputControl.java Tue Aug 16 12:23:53 2011
@@ -18,12 +18,14 @@
  */
 package org.apache.empire.struts2.jsp.controls;
 
+import java.util.Locale;
+
 import org.apache.commons.lang.xwork.StringEscapeUtils;
-import org.apache.empire.commons.ErrorInfo;
 import org.apache.empire.commons.ErrorType;
 import org.apache.empire.commons.Options;
 import org.apache.empire.commons.StringUtils;
 import org.apache.empire.data.Column;
+import org.apache.empire.struts2.action.ErrorInfo;
 import org.apache.empire.struts2.action.RequestParamProvider;
 import org.apache.empire.struts2.html.HtmlTagDictionary;
 import org.apache.empire.struts2.html.HtmlWriter;
@@ -31,8 +33,6 @@ import org.apache.empire.struts2.html.Ht
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
-import java.util.Locale;
-
 
 public abstract class InputControl
 {
@@ -108,19 +108,13 @@ public abstract class InputControl
     {
         private ErrorType errType;  // Type of error
         private String[]  errParams;  // Error message params
-        private String    errSource;  // Source object's class name
         private String    errValue;
-        public FieldValueError(ErrorType errorType, String[] msgParams, String value, Class source)
+        public FieldValueError(ErrorType errorType, String[] msgParams, String value)
         {
             errType    = errorType;
             errParams  = msgParams;
-            errSource  = source.getName();
             this.errValue = value;
         }
-        public boolean hasError()
-        {
-            return true;
-        }
         public ErrorType getErrorType()
         {
             return errType;
@@ -133,10 +127,6 @@ public abstract class InputControl
         {
             return errParams;
         }
-        public String getErrorSource()
-        {
-            return errSource;
-        }
         public String getErrorMessage()
         {
             return null;
@@ -155,7 +145,7 @@ public abstract class InputControl
      */
     protected final FieldValueError error(ErrorType errorType, String[] msgParams, String value)
     {
-        return new FieldValueError(errorType, msgParams, value, getClass());
+        return new FieldValueError(errorType, msgParams, value);
     }
     
     protected final FieldValueError error(ErrorType errorType, Object msgParam, String value)

Modified: incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/controls/PasswordInputControl.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/controls/PasswordInputControl.java?rev=1158228&r1=1158227&r2=1158228&view=diff
==============================================================================
--- incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/controls/PasswordInputControl.java (original)
+++ incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/controls/PasswordInputControl.java Tue Aug 16 12:23:53 2011
@@ -24,7 +24,7 @@ import org.apache.empire.commons.StringU
 import org.apache.empire.data.Column;
 import org.apache.empire.struts2.html.HtmlWriter;
 import org.apache.empire.struts2.html.HtmlWriter.HtmlTag;
-import org.apache.empire.struts2.web.WebErrors;
+import org.apache.empire.struts2.web.FieldErrors;
 
 
 public class PasswordInputControl extends InputControl
@@ -56,7 +56,7 @@ public class PasswordInputControl extend
         int minLength = getMinPasswordLength();
         if (pwd!=null && pwd.length()<minLength)
         {
-            return error(WebErrors.InputTextTooShort, minLength, s);
+            return error(FieldErrors.InputTextTooShort, minLength, s);
         }
         // Default
         return value;
@@ -71,7 +71,7 @@ public class PasswordInputControl extend
         if (hasError)
             return "";
         // Replace by Default-Mask
-        return (StringUtils.isValid(pwd) ? PASSWORD_NOT_CHANGED : null);
+        return (StringUtils.isNotEmpty(pwd) ? PASSWORD_NOT_CHANGED : null);
     }
 
     @Override

Modified: incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/controls/TextAreaInputControl.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/controls/TextAreaInputControl.java?rev=1158228&r1=1158227&r2=1158228&view=diff
==============================================================================
--- incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/controls/TextAreaInputControl.java (original)
+++ incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/controls/TextAreaInputControl.java Tue Aug 16 12:23:53 2011
@@ -112,7 +112,7 @@ public class TextAreaInputControl extend
         if (ci.getDisabled()==false)
         {   // Get Max Length
             String checklength = getFormatOption(ci, "maxlength:");
-            if (StringUtils.isValid(checklength))
+            if (StringUtils.isNotEmpty(checklength))
             {   // Do lengthcheck via onKeyPress and onKeyUp Events
                 int maxLength = (int)ci.getColumn().getSize();
                 checklength = StringUtils.replace(checklength, "{0}", String.valueOf(maxLength)); 

Modified: incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/controls/TextInputControl.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/controls/TextInputControl.java?rev=1158228&r1=1158227&r2=1158228&view=diff
==============================================================================
--- incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/controls/TextInputControl.java (original)
+++ incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/controls/TextInputControl.java Tue Aug 16 12:23:53 2011
@@ -32,7 +32,7 @@ import org.apache.empire.data.Column;
 import org.apache.empire.data.DataType;
 import org.apache.empire.struts2.html.HtmlWriter;
 import org.apache.empire.struts2.html.HtmlWriter.HtmlTag;
-import org.apache.empire.struts2.web.WebErrors;
+import org.apache.empire.struts2.web.FieldErrors;
 import org.apache.commons.lang.xwork.StringEscapeUtils;
 
 
@@ -83,7 +83,7 @@ public class TextInputControl extends In
                 if (n.intValue()<ObjectUtils.getInteger(min) ||
                     n.intValue()>ObjectUtils.getInteger(max))
                 {   // Out of Range
-                    return error(WebErrors.InputValueOutOfRange, new String[] { min.toString(), max.toString() }, s);
+                    return error(FieldErrors.InputValueOutOfRange, new String[] { min.toString(), max.toString() }, s);
                 }
             }
         }
@@ -373,7 +373,7 @@ public class TextInputControl extends In
             // Parse String
             return Integer.parseInt(s);
         } catch(Exception e) {
-            return error(WebErrors.InputNoIntegerFormat, null, s);
+            return error(FieldErrors.InputNoIntegerFormat, null, s);
         }
     }
     
@@ -384,12 +384,12 @@ public class TextInputControl extends In
             // Check for characters
             for (int i=0; i<s.length(); i++)
             {   if (s.charAt(i)>='A')
-                    return error(WebErrors.InputNoNumberFormat, null, s);
+                    return error(FieldErrors.InputNoNumberFormat, null, s);
             }
             // Parse String
             return nf.parseObject(s);
         } catch(Exception e) {
-            return error(WebErrors.InputNoNumberFormat, null, s);
+            return error(FieldErrors.InputNoNumberFormat, null, s);
         }
     }
     
@@ -401,7 +401,7 @@ public class TextInputControl extends In
             df.setLenient(true);
             return df.parseObject(s);
         } catch(Exception e) {
-            return error(WebErrors.InputNoDateFormat, null, s);
+            return error(FieldErrors.InputNoDateFormat, null, s);
         }
     }
 

Modified: incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/tags/ActionErrorsTag.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/tags/ActionErrorsTag.java?rev=1158228&r1=1158227&r2=1158228&view=diff
==============================================================================
--- incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/tags/ActionErrorsTag.java (original)
+++ incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/tags/ActionErrorsTag.java Tue Aug 16 12:23:53 2011
@@ -25,8 +25,8 @@ import javax.servlet.http.HttpServletReq
 import javax.servlet.http.HttpServletResponse;
 import javax.servlet.jsp.JspException;
 
-import org.apache.empire.commons.ErrorInfo;
 import org.apache.empire.struts2.action.ActionErrorProvider;
+import org.apache.empire.struts2.action.ErrorInfo;
 import org.apache.empire.struts2.html.HtmlTagDictionary;
 import org.apache.empire.struts2.html.HtmlWriter;
 import org.apache.empire.struts2.html.HtmlWriter.HtmlTag;
@@ -92,7 +92,7 @@ public class ActionErrorsTag extends Emp
         ErrorInfo lastActionError = provider.getLastActionError(true);
         Map<String, ErrorInfo> fieldErrors = provider.getItemErrors();
         
-        boolean hasActionError = (lastActionError!=null && lastActionError.hasError());
+        boolean hasActionError = (lastActionError!=null); //  && lastActionError.hasError());
         boolean hasFieldErrors = (fieldErrors!=null && fieldErrors.size()>0); 
 
         // Check whether we have an error to render

Modified: incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/tags/EmpireTagSupport.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/tags/EmpireTagSupport.java?rev=1158228&r1=1158227&r2=1158228&view=diff
==============================================================================
--- incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/tags/EmpireTagSupport.java (original)
+++ incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/tags/EmpireTagSupport.java Tue Aug 16 12:23:53 2011
@@ -215,7 +215,7 @@ public abstract class EmpireTagSupport e
         return ((value!=null) ? value : defValue);
     }
 
-    protected Object getObject(Object value, Object defValue, Class asType)
+    protected Object getObject(Object value, Object defValue, Class<?> asType)
     {
         if (value == null)
         {

Modified: incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/tags/EmpireValueTagSupport.java
URL: http://svn.apache.org/viewvc/incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/tags/EmpireValueTagSupport.java?rev=1158228&r1=1158227&r2=1158228&view=diff
==============================================================================
--- incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/tags/EmpireValueTagSupport.java (original)
+++ incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/jsp/tags/EmpireValueTagSupport.java Tue Aug 16 12:23:53 2011
@@ -127,7 +127,7 @@ public abstract class EmpireValueTagSupp
     
     protected String getTagName(String suppliedName)
     {
-        if (StringUtils.isValid(suppliedName))
+        if (StringUtils.isNotEmpty(suppliedName))
             return suppliedName;
         if (property != null)
             return getFullPropertyName(property);

Copied: incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/web/FieldErrors.java (from r1153783, incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/web/WebErrors.java)
URL: http://svn.apache.org/viewvc/incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/web/FieldErrors.java?p2=incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/web/FieldErrors.java&p1=incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/web/WebErrors.java&r1=1153783&r2=1158228&rev=1158228&view=diff
==============================================================================
--- incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/web/WebErrors.java (original)
+++ incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/web/FieldErrors.java Tue Aug 16 12:23:53 2011
@@ -20,12 +20,12 @@ package org.apache.empire.struts2.web;
 
 import org.apache.empire.commons.ErrorType;
 
-public class WebErrors
+public class FieldErrors
 {
     // general 
-    public static final ErrorType InvalidFormData = new ErrorType("error.web.recordsDontMatch", "The form submitted is invalid for the current context.");
-    public static final ErrorType ColumnNotFound  = new ErrorType("error.web.columnNotFound",   "The column {0} has not been found!");
-    public static final ErrorType FieldError      = new ErrorType("error.web.fieldError", "Field {0}: {1}");
+    // public static final ErrorType InvalidFormData = new ErrorType("error.web.recordsDontMatch", "The form submitted is invalid for the current context.");
+    // public static final ErrorType ColumnNotFound  = new ErrorType("error.web.columnNotFound",   "The column {0} has not been found!");
+    public static final ErrorType FieldError           = new ErrorType("error.web.fieldError", "Field {0}: {1}");
 
     // Parsing errors
     public static final ErrorType InputInvalidValue    = new ErrorType("error.web.input.invalidValue", "Invalid Field value");
@@ -37,5 +37,5 @@ public class WebErrors
     // Validation errors
     public static final ErrorType InputValueRequired   = new ErrorType("error.web.input.required",   "Field is required"); 
     public static final ErrorType InputValueOutOfRange = new ErrorType("error.web.input.outOfRange", "The value must be in the range of {0} and {1}.");
-    public static final ErrorType InputTextTooShort    = new ErrorType("error.web.input.textTooShort",  "The value must contain at least {0} characters."); 
+    public static final ErrorType InputTextTooShort    = new ErrorType("error.web.input.textTooShort",  "The value must contain at least {0} characters.");
 }

Propchange: incubator/empire-db/branches/EMPIREDB-99/empire-db-struts2/src/main/java/org/apache/empire/struts2/web/FieldErrors.java
------------------------------------------------------------------------------
    svn:eol-style = native



Mime
View raw message