IMHO, AstIdentify.getValue() should take the responsibility of resolving the class name (just the class name, not the field) before passing the resolution to context resolver chain.
In AstIdentifier, I propose to change:
from
ctx.setPropertyResolved(false);
Object ret = ctx.getELResolver().getValue(ctx, null, this.image);
to
ctx.setPropertyResolved(false);
// resolve class name
if (ctx.getImportHandler() != null) {
final Class<?> c = ctx.getImportHandler().resolveClass(this.image);
if (c != null)
{ ctx.setPropertyResolved(true); return new ELClass(c); }
}
Object ret = ctx.getELResolver().getValue(ctx, null, this.image);
Sorry for the bad formatting. I couldn't figure out how to format it properly.
<h:outputText value="# {Boolean.TRUE}
" /> prints out nothing.
It's expected to print out "true"
Please refer to GLASSFISH-20778 and JAVASERVERFACES-3362
IMHO, AstIdentify.getValue() should take the responsibility of resolving the class name (just the class name, not the field) before passing the resolution to context resolver chain.
In AstIdentifier, I propose to change:
from
ctx.setPropertyResolved(false); Object ret = ctx.getELResolver().getValue(ctx, null, this.image);
to
ctx.setPropertyResolved(false); // resolve class name if (ctx.getImportHandler() != null) { final Class<?> c = ctx.getImportHandler().resolveClass(this.image); if (c != null)
{ ctx.setPropertyResolved(true); return new ELClass(c); }
} Object ret = ctx.getELResolver().getValue(ctx, null, this.image);
Sorry for the bad formatting. I couldn't figure out how to format it properly.
Environment
WildFly 8.1 Final, Mojarra 2.2.7
Affected Versions
[current]