You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@commons.apache.org by js...@apache.org on 2002/06/25 20:00:09 UTC
cvs commit: jakarta-commons-sandbox/jelly/src/java/org/apache/commons/jelly/tags/ant DataTypeTag.java AntTagSupport.java
jstrachan 2002/06/25 11:00:09
Modified: jelly/src/java/org/apache/commons/jelly/tags/ant
DataTypeTag.java AntTagSupport.java
Log:
allowed setAttribute() to throw an exception so that DynaTag errors can popup to the TagScript for better error reporting
Revision Changes Path
1.9 +1 -1 jakarta-commons-sandbox/jelly/src/java/org/apache/commons/jelly/tags/ant/DataTypeTag.java
Index: DataTypeTag.java
===================================================================
RCS file: /home/cvs/jakarta-commons-sandbox/jelly/src/java/org/apache/commons/jelly/tags/ant/DataTypeTag.java,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -r1.8 -r1.9
--- DataTypeTag.java 18 Jun 2002 18:36:43 -0000 1.8
+++ DataTypeTag.java 25 Jun 2002 18:00:09 -0000 1.9
@@ -229,7 +229,7 @@
setDynaBean( new ConvertingWrapDynaBean(dataType) );
}
- public void setAttribute(String name, Object value) {
+ public void setAttribute(String name, Object value) throws Exception {
if ( "id".equals( name ) ) {
getAntProject().addReference( (String) value, dataType );
return;
1.3 +9 -13 jakarta-commons-sandbox/jelly/src/java/org/apache/commons/jelly/tags/ant/AntTagSupport.java
Index: AntTagSupport.java
===================================================================
RCS file: /home/cvs/jakarta-commons-sandbox/jelly/src/java/org/apache/commons/jelly/tags/ant/AntTagSupport.java,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- AntTagSupport.java 25 Jun 2002 17:13:32 -0000 1.2
+++ AntTagSupport.java 25 Jun 2002 18:00:09 -0000 1.3
@@ -136,7 +136,7 @@
return task;
}
- public void setAttribute(String name, Object value) {
+ public void setAttribute(String name, Object value) throws Exception {
Object obj = null;
@@ -146,7 +146,7 @@
e.printStackTrace();
return;
}
-
+
if ( obj == null ) {
return;
}
@@ -167,13 +167,9 @@
} catch (Exception e) {
// e.printStackTrace();
- try
- {
- super.setAttribute( name, value );
- }
- catch (Exception f) {
- // f.printStackTrace();
- }
+ // let any exceptions bubble up from here
+
+ super.setAttribute( name, value );
}
}
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>