statisticsMap.put("totalEntries", totalEntries);
Iterator formEntryValueVOListIterator = formEntryValueVOList.iterator();
while(formEntryValueVOListIterator.hasNext())
{
FormEntryValueVO formEntryValueVO = (FormEntryValueVO)formEntryValueVOListIterator.next();
if(type.equals("percentage") || type.equals("numeric"))
{
Integer count = (Integer)statisticsMap.get("" + formEntryValueVO.getValue());
if(count == null)
statisticsMap.put("" + formEntryValueVO.getValue(), 1);
else
statisticsMap.put("" + formEntryValueVO.getValue(), count + 1);
}
else if(type.equals("average"))
{
try
{
totalValue = totalValue + Integer.getInteger(formEntryValueVO.getValue());
}
catch (Exception e)
{
logger.warn("Not a valid number:" + e.getMessage());
}