public abstract class AbstractModelVariableModifierProcessor
extends org.thymeleaf.processor.element.AbstractElementProcessor
Constructor and Description |
---|
AbstractModelVariableModifierProcessor(String elementName) |
Modifier and Type | Method and Description |
---|---|
protected <T> void |
addCollectionToExistingSet(org.thymeleaf.Arguments arguments,
String key,
Collection<T> value) |
protected <T> void |
addItemToExistingSet(org.thymeleaf.Arguments arguments,
String key,
Object value) |
protected void |
addToModel(org.thymeleaf.Arguments arguments,
String key,
Object value)
Helper method to add a value to the expression evaluation root (model) Map
|
int |
getPrecedence() |
protected abstract void |
modifyModelAttributes(org.thymeleaf.Arguments arguments,
org.thymeleaf.dom.Element element)
This method must be overriding by a processor that wishes to modify the model.
|
protected org.thymeleaf.processor.ProcessorResult |
processElement(org.thymeleaf.Arguments arguments,
org.thymeleaf.dom.Element element)
This method will handle calling the modifyModelAttributes abstract method and return
an "OK" processor result
|
doProcess, getMatcher
public AbstractModelVariableModifierProcessor(String elementName)
public int getPrecedence()
getPrecedence
in class org.thymeleaf.processor.AbstractProcessor
protected org.thymeleaf.processor.ProcessorResult processElement(org.thymeleaf.Arguments arguments, org.thymeleaf.dom.Element element)
processElement
in class org.thymeleaf.processor.element.AbstractElementProcessor
protected void addToModel(org.thymeleaf.Arguments arguments, String key, Object value)
key
- the key to add to the modelvalue
- the value represented by the keyprotected <T> void addCollectionToExistingSet(org.thymeleaf.Arguments arguments, String key, Collection<T> value)
protected <T> void addItemToExistingSet(org.thymeleaf.Arguments arguments, String key, Object value)
protected abstract void modifyModelAttributes(org.thymeleaf.Arguments arguments, org.thymeleaf.dom.Element element)
arguments
- element
- Copyright © 2017. All rights reserved.