InvocationExecuteException ite=(InvocationExecuteException)cause;
msg=ite.getCause().getMessage();
}
else if(cause instanceof ArgPrepareExecuteException)
{
ArgPrepareExecuteException apee=(ArgPrepareExecuteException)cause;
Throwable th=apee.getCause();
if(th instanceof ParamIllegalException)
{
ParamIllegalException pie=(ParamIllegalException)th;
msg="The parameter [name: \""+pie.getParamName()+"\", value: \""+pie.getParamValue()+"\"]";
Type targetType=pie.getTargetType();
if(Integer.class.equals(targetType)
|| int.class.equals(targetType))
msg+=" is not valid integer.";
else
msg+=" is invalid";
}
else
msg+=apee.getMessage();
}
else
msg="unknown error";
return msg+" (\""+execution.getExecutable().getName()+"\")";