[jboss-cvs] jboss-seam/src/main/org/jboss/seam/mock ...
Gavin King
gavin.king at jboss.com
Fri Jun 1 14:42:42 EDT 2007
User: gavin
Date: 07/06/01 14:42:42
Modified: src/main/org/jboss/seam/mock MockApplication.java
Log:
minor cleanup
Revision Changes Path
1.17 +12 -7 jboss-seam/src/main/org/jboss/seam/mock/MockApplication.java
(In the diff below, changes in quantity of whitespace are not shown.)
Index: MockApplication.java
===================================================================
RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/mock/MockApplication.java,v
retrieving revision 1.16
retrieving revision 1.17
diff -u -b -r1.16 -r1.17
--- MockApplication.java 30 May 2007 00:19:13 -0000 1.16
+++ MockApplication.java 1 Jun 2007 18:42:42 -0000 1.17
@@ -328,16 +328,18 @@
}
@Override
- public MethodBinding createMethodBinding(final String methodExpression, final Class[] args)
+ @Deprecated
+ public MethodBinding createMethodBinding(String expression, Class[] args)
throws ReferenceSyntaxException
{
- Class[] c = args;
- if (c == null)
+ if (args == null)
{
// Mismatch between JSF and Unified EL
- c = new Class[0];
+ args = new Class[0];
}
- return new UnifiedELMethodBinding(methodExpression, c);
+ FacesContext context = FacesContext.getCurrentInstance();
+ return new UnifiedELMethodBinding( context.getApplication().getExpressionFactory()
+ .createMethodExpression( context.getELContext(), expression, Object.class, args ) );
}
@Override
@@ -371,10 +373,13 @@
}
@Override
- public ValueBinding createValueBinding(final String valueExpression)
+ @Deprecated
+ public ValueBinding createValueBinding(String expression)
throws ReferenceSyntaxException
{
- return new UnifiedELValueBinding(valueExpression);
+ FacesContext context = FacesContext.getCurrentInstance();
+ return new UnifiedELValueBinding( context.getApplication().getExpressionFactory()
+ .createValueExpression( context.getELContext(), expression, Object.class ) );
}
@Override
More information about the jboss-cvs-commits
mailing list