If I have this peace of code:
<rich:select enableManualInput="true" defaultLabel="Select time spent">
<f:selectItems value="" />
</rich:select>
and a properties file like:
key1=val1
key2=val2
key3=val3
key4=val4
The question is how to take all the values from the properties file and make a ArrayList<SelectItems> from them for example so I can use them in the drop-down list?
If you can change the layout of your properties file i would suggest storing it like
Properties Tutorial: http://download.oracle.com/javase/tutorial/essential/environment/properties.html
Api: http://download.oracle.com/javase/6/docs/api/java/util/Properties.html.
Unfortunately Properties is backed by a Hashtable<Object,Object>. But unless you mess with it, the casts should be safe.