I'm trying to clean up warnings on my working pages in a simple
JSF application. In particular, my
<h:selectManyListbox ...> instances all behave perfectly, but Eclipse marks my
.jsp with a warning (hmmm... I hope this isn't an Eclipse thing and I've gone and asked the question of the wrong forum?):
Cannot coerce type java.lang.String[] to java.lang.String, java.lang.Short, java.lang.Character, java.lang.Boolean, java.lang.Double, java.lang.Byte, java.lang.Long, java.lang.Float, java.lang.Integer
The warning occurs each time on line 2 (presumably because of the
value attribute):
Now,
QueryBean.java, relevant to
languages, appears thus:
Everywhere in examples on the Internet, I see
String[] used as the type of what goes in the
value attribute. In fact, given it's potentially multiple items, it doesn't sound reasonable it could ever be any of those other, "scalar" types. Why then would the
JSP validator issue this warning? Am I missing something? Can I do nothing other than just ignore the warning?
Thanks for any and all elucidation.
Russ Bateman