Does anyone know how to get the length of a collection using the EL? I am trying to
do one of the tests below. Note that "children" is a List.
<c:if test="${component.parentDao.children.length > 1}">
<!-- stuff here -->
</c:if>
or
<c:if test="${component.parentDao.children.size > 1}">
<!-- stuff here -->
</c:if>
And get this error:
javax.servlet.jsp.JspException: An error occurred while evaluating custom action
attribute "test" with value "${component.parentDao.children.length > 1}": The "."
operator was supplied with an index value of type "java.lang.String" to be applied to
a List or array, but that value cannot be converted to an integer.
Thanks!
Matt