A simpler solution would be to use the spring
delegating variable resolver and refer directly to the spring bean instead. Afaik there is no native way to lookup
java 5 enums in jsf 1.1 (or for that matter in jsf 1.2 either—without the
custom el resolver). From:
Baker,Jonathan [mailto:[EMAIL PROTECTED] I am trying to inject an instance of an enumeration class into
one of my ViewControllers. Spring has the capability to define a
PropertyEditor so that you can pass Strings as values to beans, and the
PropertyEditor will convert to the correct object, but I do not seee a way to
accomplish the same thing in my faces-config.xml. When I tried to define
my ViewController in my spring applicationContext.xml file jsf couldn't find
it. I did some research and it looks like if you are using jsf 1.2
you can define a el-resolver that can use a special EnumManagedBean class to
expose enumerations to your jsp, and I assume that the ELResolver would work on
the faces-config file as well, but we are using myfaces with Shale, and it only
implements the jsf 1.1 spec. Is there an equivalent to the el-resolver
tag in jsf 1.1? JB
|
Title: Injecting Java 5 Enums into a managed bean
- RE: Injecting Java 5 Enums into a managed ... Dhananjay Prasanna
- RE: Injecting Java 5 Enums into a man... Conway. Fintan \(IT Solutions\)