Author: alexsmirnov
Date: 2008-03-31 17:39:40 -0400 (Mon, 31 Mar 2008)
New Revision: 7506
Modified:
trunk/ui/core/src/main/java/org/ajax4jsf/taglib/html/facelets/AjaxListenerHandler.java
Log:
allow binding without 'type' attribute
Modified:
trunk/ui/core/src/main/java/org/ajax4jsf/taglib/html/facelets/AjaxListenerHandler.java
===================================================================
---
trunk/ui/core/src/main/java/org/ajax4jsf/taglib/html/facelets/AjaxListenerHandler.java 2008-03-31
20:24:08 UTC (rev 7505)
+++
trunk/ui/core/src/main/java/org/ajax4jsf/taglib/html/facelets/AjaxListenerHandler.java 2008-03-31
21:39:40 UTC (rev 7506)
@@ -67,8 +67,11 @@
public AjaxListenerHandler(TagConfig config) {
super(config);
this.binding = this.getAttribute("binding");
- this.type = this.getRequiredAttribute("type");
- if (type != null) {
+ this.type = this.getAttribute("type");
+ if(binding == null && type == null){
+ throw new TagException(this.tag, "One of the attribute 'binding'
or type' is required");
+ }
+ if (binding == null && type != null) {
if (!type.isLiteral()) {
throw new TagAttributeException(this.tag, this.type,
Messages.getMessage(Messages.MUST_BE_LITERAL_ERROR));
}
Show replies by date