@Deprecated public static List<Object> evaluateAsList(final Object value) { return EvaluationUtils.evaluateAsList(value); }
/** * * @param value value * @return the result * @deprecated since 2.1, you should use the * {@link org.thymeleaf.standard.expression.IStandardConversionService} implementation * corresponding to the dialect you are using or the methods in * {@link EvaluationUtils}. * Will be removed in 3.0. */ @Deprecated public static List<Object> convertToIterable(final Object value) { return EvaluationUtils.evaluateAsList(value); }
/** * * @param value value * @return the result * @deprecated since 2.1, you should use the * {@link org.thymeleaf.standard.expression.IStandardConversionService} implementation * corresponding to the dialect you are using or the methods in * {@link EvaluationUtils}. * Will be removed in 3.0. */ @Deprecated public static List<Object> convertToList(final Object value) { if (value == null) { // This mimics the old behaviour of the deprecated convertToList() method, which is not the same // as the current EvaluationUtils.convertToList() method. return Collections.singletonList(null); } return EvaluationUtils.evaluateAsList(value); }
public static List<Object> evaluateAsIterable(ITemplateContext arguments, String rawValue) throws TemplateProcessingException { notNull(arguments, "arguments must not be null"); notEmpty(rawValue, "rawValue must not be empty"); final Object evaluatedExpression = evaluateExpression(arguments, rawValue); return EvaluationUtils.evaluateAsList(evaluatedExpression); }
public static List<Object> evaluateAsIterable(ITemplateContext arguments, String rawValue) throws TemplateProcessingException { notNull(arguments, "arguments must not be null"); notEmpty(rawValue, "rawValue must not be empty"); final Object evaluatedExpression = evaluateExpression(arguments, rawValue); return EvaluationUtils.evaluateAsList(evaluatedExpression); }