Package de.odysseus.el

Examples of de.odysseus.el.ObjectValueExpression


  @Override
  protected void setUp() throws Exception {
    context = new SimpleContext(new SimpleResolver());
   
    // variables var_long_1, indentifier_string
    context.setVariable("var_long_1", new ObjectValueExpression(1l, long.class));
    context.setVariable("indentifier_string", new ObjectValueExpression("foo", String.class));
    context.setVariable("var_method_1", new ObjectValueExpression(getClass().getMethod("method_1"), Method.class));

    // properties property_long_1, indentifier_string
    context.getELResolver().setValue(context, null, "property_long_1", 1l);
    context.getELResolver().setValue(context, null, "indentifier_string", "bar"); // shadowed by variable indentifier_string
    context.getELResolver().setValue(context, null, "property_method_1", getClass().getMethod("method_1"));
View Full Code Here


    // function g()
    context.setFunction("", "g", BindingsTest.class.getMethod("bar", new Class[]{int.class}));

    // variable v
    context.setVariable("v", new ObjectValueExpression(TypeConverter.DEFAULT, new Long(0), long.class));
  }
View Full Code Here

    // functions g0(), g1(int)
    context.setFunction("", "g0", TreeTest.class.getMethod("foo"));
    context.setFunction("", "g1", TreeTest.class.getMethod("bar", new Class[]{int.class}));

    // variables v0, v1
    context.setVariable("v0", new ObjectValueExpression(TypeConverter.DEFAULT, 0, long.class));
    context.setVariable("v1", new ObjectValueExpression(TypeConverter.DEFAULT, 1, long.class));
  }
View Full Code Here

    context = new SimpleContext(new SimpleResolver());
   
    TypeConverter converter = TypeConverter.DEFAULT;
   
    // variables var_long_1, indentifier_string
    context.setVariable("var_long_1", new ObjectValueExpression(converter, 1l, long.class));
    context.setVariable("indentifier_string", new ObjectValueExpression(converter, "foo", String.class));
    context.setVariable("var_method_1", new ObjectValueExpression(converter, getClass().getMethod("method_1"), Method.class));

    // properties property_long_1, indentifier_string
    context.getELResolver().setValue(context, null, "property_long_1", 1l);
    context.getELResolver().setValue(context, null, "indentifier_string", "bar"); // shadowed by variable indentifier_string
    context.getELResolver().setValue(context, null, "property_method_1", getClass().getMethod("method_1"));
View Full Code Here

    // function g()
    context.setFunction("", "g", BindingsTest.class.getMethod("bar", new Class[]{int.class}));

    // variable v
    context.setVariable("v", new ObjectValueExpression(new Long(0), long.class));
  }
View Full Code Here

    // functions g0(), g1(int)
    context.setFunction("", "g0", TreeTest.class.getMethod("foo"));
    context.setFunction("", "g1", TreeTest.class.getMethod("bar", new Class[]{int.class}));

    // variables v0, v1
    context.setVariable("v0", new ObjectValueExpression(0, long.class));
    context.setVariable("v1", new ObjectValueExpression(1, long.class));
  }
View Full Code Here

    // function g()
    context.setFunction("", "g", BindingsTest.class.getMethod("bar", new Class[]{int.class}));

    // variable v
    context.setVariable("v", new ObjectValueExpression(TypeConverter.DEFAULT, new Long(0), long.class));
  }
View Full Code Here

    // functions g0(), g1(int)
    context.setFunction("", "g0", TreeTest.class.getMethod("foo"));
    context.setFunction("", "g1", TreeTest.class.getMethod("bar", new Class[]{int.class}));

    // variables v0, v1
    context.setVariable("v0", new ObjectValueExpression(TypeConverter.DEFAULT, 0, long.class));
    context.setVariable("v1", new ObjectValueExpression(TypeConverter.DEFAULT, 1, long.class));
  }
View Full Code Here

    context = new SimpleContext(new SimpleResolver());
   
    TypeConverter converter = TypeConverter.DEFAULT;
   
    // variables var_long_1, indentifier_string
    context.setVariable("var_long_1", new ObjectValueExpression(converter, 1l, long.class));
    context.setVariable("indentifier_string", new ObjectValueExpression(converter, "foo", String.class));
    context.setVariable("var_method_1", new ObjectValueExpression(converter, getClass().getMethod("method_1"), Method.class));
    context.setVariable("var_method_1_expr", new ObjectValueExpression(converter, new TestMethodExpression(getClass().getMethod("method_1")), MethodExpression.class));

    // properties property_long_1, indentifier_string
    context.getELResolver().setValue(context, null, "property_long_1", 1l);
    context.getELResolver().setValue(context, null, "indentifier_string", "bar"); // shadowed by variable indentifier_string
    context.getELResolver().setValue(context, null, "property_method_1", getClass().getMethod("method_1"));
View Full Code Here

TOP

Related Classes of de.odysseus.el.ObjectValueExpression

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.