i have a util el method that gets an object in a list with index
public static Object get(List list, Integer index) {
return list.get(index);
}
and i am calling this method in the xhtml page to get the name of first element in list as follows:
<span>#{[utils:get(myBean.myList,1)].name}</span>
but above expression gives me the following exception:
org.apache.el.parser.ParseException: Encountered " "[" "[ "" at line 1, column 3.
Was expecting one of:
<INTEGER_LITERAL> ...
<FLOATING_POINT_LITERAL> ...
<STRING_LITERAL> ...
"true" ...
"false" ...
"null" ...
"(" ...
"!" ...
"not" ...
"empty" ...
"-" ...
<IDENTIFIER> ...
any ideas why ?