I'm stuck with a problem of displaying an ArrayList
that carries 2750 rows. The struts code to display row is :
<c:forEach items="${customerlist}" var="beneficiaryListval"varStatus="ForIndex" >
<tr id="<c:out value="${beneficiaryListval.customerId}" />">
<td><c:out value="${beneficiaryListval.fullName}" /></td>
<td><c:out value="${beneficiaryListval.mobileNo}" /></td>
<td><c:out value="${beneficiaryListval.passportNo}" /></td>
<td><c:out value="${beneficiaryListval.beneficiaryCount}" /></td>
</tr>
<%rowID++;%>
</c:forEach>
The action method for this is :
public ActionForward load(ActionMapping actionMapping,ActionForm actionForm,HttpServletRequest httpServletRequest,
HttpServletResponse httpServletResponse) {
try {
mtmrsLogger.entering("BeneficiaryAction", "load");
BeneficiaryForm beneficiaryForm = (BeneficiaryForm) actionForm;
ArrayList customerlist = customerManager.getCustomerForBeneficiaryWithCount();
httpServletRequest.setAttribute("customerlist", customerlist);
beneficiaryForm.setPageStatus("CustomerGrid");
return actionMapping.findForward(Constants.getInstance().SUCCESS);
}
Now i need to either break the ArrayList customerlist
and send to the JSP in chunks of fifty and display OR display them in the JSP so that it is not very slow while rendering.