import org.thymeleaf.context.VariablesMap;
import org.thymeleaf.dom.Element;
import org.thymeleaf.dom.Node;
+import org.thymeleaf.exceptions.TemplateProcessingException;
import org.thymeleaf.processor.ProcessorResult;
import org.thymeleaf.processor.attr.AbstractAttrProcessor;
import org.thymeleaf.resourceresolver.IResourceResolver;
+import org.thymeleaf.standard.expression.IStandardExpression;
+import org.thymeleaf.standard.expression.IStandardExpressionParser;
+import org.thymeleaf.standard.expression.StandardExpressions;
import org.thymeleaf.templateresolver.ITemplateResolver;
import org.thymeleaf.templateresolver.TemplateResolution;
)
{
Configuration config = arguments.getConfiguration();
+
+ Configuration configuration = arguments.getConfiguration();
+
String parameter = element.getAttributeValue(name);
+ try
+ {
+ IStandardExpressionParser parser =
+ StandardExpressions.getExpressionParser(configuration);
+ IStandardExpression expression =
+ parser.parseExpression(configuration, arguments, parameter);
+ parameter = (String)expression.execute(configuration, arguments);
+ }
+ catch (TemplateProcessingException e) { }
+
+ if (parameter != null && !parameter.trim().isEmpty())
+ {
+ LOG.info("ignoring empty parameter");
+ return ProcessorResult.OK;
+ }
Iterator<Entry<String, Object>> it = null;