Object expResult = this._exp.evaluate();
if (!(expResult instanceof java.util.List))
{
logger.severe(Thread.currentThread().getName()+" "+"result of expression is not of type List");
throw new SPLException(
"result of expression is not of type List");
}
ArrayList resultArray = (ArrayList) expResult;
//System.out.println("resultArray size " + resultArray.size()+ " to string " + resultArray.toString());
// //System.out.println("resultArray is of type "+expression.getType());
if ((resultArray != null) && (!resultArray.isEmpty()))
{
Integer size = new Integer(resultArray.size());
//System.out.println("Size of collection is " + size);
logger.exiting(sourceClass,Thread.currentThread().getName()+" "+ "evaluate");
return size;
}
else
{
logger.severe(Thread.currentThread().getName()+" "+"result Array is empty");
throw new SPLException("result Array is empty");
}
}