dev@javaserverfaces.java.net

RE: Seeking Review Impl portion of jsf-api 205: PropertyEditorConverter

From: Ed Burns <ed.burns_at_sun.com>
Date: Fri, 11 Aug 2006 10:45:13 -0700

>>>>> On Fri, 11 Aug 2006 13:25:10 -0400, jacob_at_hookom.net said:

JH> On ignoring registration under certain conditions, someone may
JH> expect that they can provide their own converter for lang types. If
JH> PropertyEditorManager is statically scoped, application restarts
JH> with converter registration could be difficult do correctly with the
JH> changebundle.

Well, the way the PropertyEditorManager.registerEditor() works, the last
one to call it "wins". Therefore, if you want to override the lang
types using the PropertyEditor, you'd have to do it manually.

JH> If kept, use Arrays.indexOf(...) instead of writing your own. Also,
JH> what about primitives-- class name of 'int', 'long', 'byte'.

I don't even get asked to register those because there are already
PropertyEditor classes registered for those by the core JDK.

JH> ConverterPropertyEditor should be written like the other JSF
JH> ELResolvers and fail fast if FacesContext is not available.

Ok.

JH> Overall, an interesting solution, but I would prefer a literal
JH> ELResolver solution instead of piggy backing on the oddities of the
JH> Swing/Bean API here.

Well, the EL API has already chosen to use the PropertyEditor API. Jan,
you're on the CC list for this bug, care to comment?

Ed

-- 
| ed.burns_at_sun.com  | {home: 407 869 9587, office: 408 884 9519 OR x31640}
| homepage:         | http://purl.oclc.org/NET/edburns/
| aim: edburns0sunw | iim: ed.burns_at_sun.com