The project we're working on requires us to generate a java web application from a some ancient language. The code being converted, we have transformed into java classes
the presentation is converted into JSF (facelets) pages.
By the way, long before java (.net) platform has been conceived, there were
languages and environments, worked out so good that contemporary client - server
paradigms (like JSF, ASP.NET, and so on) are just their isomorphisms.
The problem we were dealing with recently is JSF databinding for a bean properties
of types java.sql.Date, java.sql.Time, java.sql.Timestamp.
java.sql.Date, java.sql.Time, java.sql.Timestamp
At some point of design we have decided that these types are most natural
representation of data in the original language, as the program's activity is
tightly connected to the database. Later on it's became clear that JSF
databinding does not like these types at all. We were to decide either to fall
back and use java.util.Date as bean property types, or do something with
It was not clear what's the best way until we have found an elegant solution,
namely: to create ELResolver to handle bean properties of these types. The solution
works because custom el resolvers are applied before standard resolvers (except
DateELResolver is rather simple extension of the
BeanELResolver. To use it you only need to register it the faces-config.xml:
a@href@title, b, blockquote@cite, em, i, strike, strong, sub, super, u