List of usage examples for org.apache.commons.el Coercions coerceToInteger
public static Integer coerceToInteger(Object pValue, Logger pLogger) throws ELException
From source file:org.apache.myfaces.el.ELParserHelper.java
private static Integer coerceToIntegerWrapper(Object base, Object index) throws EvaluationException, ELException { Integer integer = Coercions.coerceToInteger(index, LOGGER); if (integer != null) { return integer; }/*from w ww. ja v a 2 s . com*/ throw new ReferenceSyntaxException( "Cannot convert index to int for base " + base.getClass().getName() + " and index " + index); }
From source file:org.seasar.teeda.core.el.impl.commons.CoercionsUtil.java
public static Integer coerceToInteger(Object index, Logger logger) { try {// w w w . j a v a2 s .co m return Coercions.coerceToInteger(index, logger); } catch (ELException e) { logger_.error(e + " occured at " + CoercionsUtil.class); return null; } }