Author: nbelaevski
Date: 2009-07-10 07:04:14 -0400 (Fri, 10 Jul 2009)
New Revision: 14875
Modified:
framework/trunk/impl/src/main/java/org/ajax4jsf/event/AjaxListenerHelper.java
framework/trunk/test-base/
Log:
AjaxListenerHelper removed ValueBinding
Modified: framework/trunk/impl/src/main/java/org/ajax4jsf/event/AjaxListenerHelper.java
===================================================================
---
framework/trunk/impl/src/main/java/org/ajax4jsf/event/AjaxListenerHelper.java 2009-07-09
18:52:52 UTC (rev 14874)
+++
framework/trunk/impl/src/main/java/org/ajax4jsf/event/AjaxListenerHelper.java 2009-07-10
11:04:14 UTC (rev 14875)
@@ -23,6 +23,7 @@
import java.io.Serializable;
+import javax.el.ValueExpression;
import javax.faces.component.StateHolder;
import javax.faces.component.UIComponentBase;
import javax.faces.context.FacesContext;
@@ -36,7 +37,7 @@
public class AjaxListenerHelper implements AjaxListener,StateHolder {
- private ValueBinding _binding;
+ private ValueExpression _expression;
private boolean _transient = false;
@@ -53,16 +54,16 @@
/**
* @param binding
*/
- public AjaxListenerHelper(ValueBinding binding) {
+ public AjaxListenerHelper(ValueExpression expression) {
super();
- if (null == binding) {
+ if (null == expression) {
throw new IllegalArgumentException("Binding expression for AjaxListener helper
must be not null");
}
- _binding = binding;
+ _expression = expression;
}
private AjaxListener getHandler(FacesContext context) {
- return (AjaxListener) _binding.getValue(context);
+ return (AjaxListener) _expression.getValue(context.getELContext());
}
/* (non-Javadoc)
@@ -70,7 +71,7 @@
*/
public void restoreState(FacesContext context, Object state) {
State helperState = (State) state;
- _binding = (ValueBinding)
UIComponentBase.restoreAttachedState(context,helperState.binding);
+ _expression = (ValueExpression)
UIComponentBase.restoreAttachedState(context,helperState.binding);
}
/* (non-Javadoc)
@@ -78,7 +79,7 @@
*/
public Object saveState(FacesContext context) {
State helperState = new State();
- helperState.binding = UIComponentBase.saveAttachedState(context,_binding);
+ helperState.binding = UIComponentBase.saveAttachedState(context,_expression);
return helperState;
}
Property changes on: framework/trunk/test-base
___________________________________________________________________
Name: svn:ignore
- .project
.checkstyle
target
.metadata
.settings
+ .project
.checkstyle
target
.metadata
.settings
.classpath
Show replies by date