[cvs]
expresso/expresso-web/WEB-INF/src/com/jcorporate/expresso/core/controller
ControllerResponse.java
JCorporate Ltd
jcorp at jcorp2.servlets.net
Fri Jul 9 00:44:40 PDT 2004
Update of /home/javacorp/.cvs/expresso/expresso/expresso-web/WEB-INF/src/com/jcorporate/expresso/core/controller
In directory jcorp2.servlets.net:/tmp/cvs-serv17861/expresso-web/WEB-INF/src/com/jcorporate/expresso/core/controller
Modified Files:
ControllerResponse.java
Log Message:
deprecate confusing method
Index: ControllerResponse.java
===================================================================
RCS file: /home/javacorp/.cvs/expresso/expresso/expresso-web/WEB-INF/src/com/jcorporate/expresso/core/controller/ControllerResponse.java,v
retrieving revision 1.45
retrieving revision 1.46
diff -C2 -d -r1.45 -r1.46
*** ControllerResponse.java 8 Jul 2004 05:52:40 -0000 1.45
--- ControllerResponse.java 9 Jul 2004 07:44:38 -0000 1.46
***************
*** 1565,1569 ****
--- 1565,1590 ----
/**
+ * add an error code, and an associated arg for translating that error code
+ *
+ * @param errorMessage key to error msg found in message bundle
+ * @param arg a replacement value to use in ${} replacement template
+ * @see com.jcorporate.expresso.core.i18n.MessageBundle#getString(java.lang.String, java.lang.Object[])
+ */
+ public void addError(String errorMessage, Object arg) throws ControllerException {
+ ErrorCollection errs = getErrors();
+
+ if (errs == null) {
+ errs = new ErrorCollection();
+ }
+
+ errs.addError(errorMessage, arg);
+ saveErrors(errs);
+ }
+
+
+ /**
* add an error code, and associated args for translating that error code
+ * @param errorMessage key to error msg found in message bundle
+ * @param args an array of replacement value to use in ${} replacement templates
* @see com.jcorporate.expresso.core.i18n.MessageBundle#getString(java.lang.String, java.lang.Object[])
*/
***************
*** 1582,1590 ****
* DOCUMENT ME!
*
! * @param label DOCUMENT ME!
* @param errorMessage DOCUMENT ME!
* @throws ControllerException DOCUMENT ME!
*/
! public void addError(String label, String errorMessage)
throws ControllerException {
ErrorCollection errs = getErrors();
--- 1603,1613 ----
* DOCUMENT ME!
*
! * @deprecated 7/04 v5.5 expresso uses only one property name, the default; use addError(String errmsg) instead
!
! * @param propName DOCUMENT ME!
* @param errorMessage DOCUMENT ME!
* @throws ControllerException DOCUMENT ME!
*/
! public void addError(String propName, String errorMessage)
throws ControllerException {
ErrorCollection errs = getErrors();
***************
*** 1594,1598 ****
}
! errs.addError(label, errorMessage);
saveErrors(errs);
}
--- 1617,1621 ----
}
! errs.addError(propName, errorMessage);
saveErrors(errs);
}
***************
*** 2242,2244 ****
--- 2265,2268 ----
return title;
}
+
}
More information about the cvs
mailing list