Search in sources :

Example 1 with ImplicitObjectELResolver

use of javax.servlet.jsp.el.ImplicitObjectELResolver in project tomcat by apache.

the class TestJasperELResolver method doTestConstructor.

private void doTestConstructor(int count) throws Exception {
    List<ELResolver> list = new ArrayList<>();
    for (int i = 0; i < count; i++) {
        list.add(new ImplicitObjectELResolver());
    }
    JasperELResolver resolver = new JasperELResolver(list, new StreamELResolverImpl());
    Assert.assertEquals(Integer.valueOf(count), getField("appResolversSize", resolver));
    Assert.assertEquals(9 + count, ((ELResolver[]) getField("resolvers", resolver)).length);
    Assert.assertEquals(Integer.valueOf(9 + count), getField("size", resolver));
}
Also used : ImplicitObjectELResolver(javax.servlet.jsp.el.ImplicitObjectELResolver) ELResolver(javax.el.ELResolver) ImplicitObjectELResolver(javax.servlet.jsp.el.ImplicitObjectELResolver) ArrayList(java.util.ArrayList) StreamELResolverImpl(org.apache.el.stream.StreamELResolverImpl)

Example 2 with ImplicitObjectELResolver

use of javax.servlet.jsp.el.ImplicitObjectELResolver in project sling by apache.

the class JspApplicationContextImpl method createELResolver.

private ELResolver createELResolver() {
    this.instantiated = true;
    if (this.resolver == null) {
        CompositeELResolver r = new CompositeELResolver();
        r.add(new ImplicitObjectELResolver());
        for (Iterator itr = this.resolvers.iterator(); itr.hasNext(); ) {
            r.add((ELResolver) itr.next());
        }
        r.add(new MapELResolver());
        r.add(new ResourceBundleELResolver());
        r.add(new ListELResolver());
        r.add(new ArrayELResolver());
        r.add(new BeanELResolver());
        r.add(new ScopedAttributeELResolver());
        this.resolver = r;
    }
    return this.resolver;
}
Also used : CompositeELResolver(javax.el.CompositeELResolver) ImplicitObjectELResolver(javax.servlet.jsp.el.ImplicitObjectELResolver) Iterator(java.util.Iterator) ScopedAttributeELResolver(javax.servlet.jsp.el.ScopedAttributeELResolver) ResourceBundleELResolver(javax.el.ResourceBundleELResolver) ListELResolver(javax.el.ListELResolver) MapELResolver(javax.el.MapELResolver) ArrayELResolver(javax.el.ArrayELResolver) BeanELResolver(javax.el.BeanELResolver)

Aggregations

ImplicitObjectELResolver (javax.servlet.jsp.el.ImplicitObjectELResolver)2 ArrayList (java.util.ArrayList)1 Iterator (java.util.Iterator)1 ArrayELResolver (javax.el.ArrayELResolver)1 BeanELResolver (javax.el.BeanELResolver)1 CompositeELResolver (javax.el.CompositeELResolver)1 ELResolver (javax.el.ELResolver)1 ListELResolver (javax.el.ListELResolver)1 MapELResolver (javax.el.MapELResolver)1 ResourceBundleELResolver (javax.el.ResourceBundleELResolver)1 ScopedAttributeELResolver (javax.servlet.jsp.el.ScopedAttributeELResolver)1 StreamELResolverImpl (org.apache.el.stream.StreamELResolverImpl)1