Skip to main content

Manfred Riem

I love working with a broad range of technologies. At work it is mostly JavaEE and JavaSE technologies, as a hobby I do some Java on devices.

 

mriem's blog

JSF Tip #18 - The JSF Converter summary

Posted by mriem on October 11, 2012 at 8:01 PM PDT

The following blog articles are part of the JSF Converter series

JSF Tip #17 - Packaging your JSF Converter

Posted by mriem on October 5, 2012 at 7:25 PM PDT

In the previous blog entry you learned how to write your own converter. Say you want to distribute this converter to others. How can you make sure the JSF runtime knows about the converter without needing to add it to the faces-config.xml of the web application.

JSF Tip #16 - Writing your own Converter

Posted by mriem on October 4, 2012 at 3:57 PM PDT

Writing you own converter is a pretty straight forward process. It really comes down to implementing the Converter API.

Say you want to write a converter that will convert colors. Lets assume we support, "Red", "Green" and "Blue".

JSF Tip #15 - The DateTimeConverter

Posted by mriem on October 3, 2012 at 1:31 PM PDT

How would you use the JSF DateTimeConverter?

If you are working with dates you probably have had a need to display them in the correct format, or even had to parse them? Well, lets start off with using dateStyle. The example below will use the "long" date style as defined by the server Locale. Valid values are "default", "short", "medium", "long", and "full".

JSF Tip #14 - The NumberConverter

Posted by mriem on October 2, 2012 at 12:54 PM PDT

How do you use the JSF NumberConverter?

If you are outputting a value, how would you show a currency code along with it?

JSF Tip #13 - The JSF Converter API

Posted by mriem on September 21, 2012 at 11:49 AM PDT

See what the JSF Validator API is about!

The definition of a Converter according to the Converter interface:

JSF Tip #12 - Introduction to JSF Converters

Posted by mriem on September 21, 2012 at 6:40 AM PDT

Introduction to JSF Converters

During the JSF lifecycle each input value needs to be converted. As such the JSF runtime allows you to write converters that will take care of that during request processing.

JSF Tip #11 - The JSF Validator summary

Posted by mriem on September 17, 2012 at 6:18 PM PDT

The following blog articles are part of the JSF Validator series

JSF Tip #10 - The FacesValidator annotation

Posted by mriem on September 17, 2012 at 5:40 PM PDT

In the previous blog entry titled "Writing your own validator" you learned how to write a validator and hook it up for validation. At that time we made it all work using the faces-config.xml file. There is however another way, which we will describe below!

JSF Tip #9 - The BeanValidator

Posted by mriem on September 17, 2012 at 4:07 PM PDT

Since JSF 2 it is also possible to use BeanValidation as specified in JSR 303. The following blog article describes how this JSR has been integrated within JSF 2.

With the following JSF managed bean.