Interface IProcessableElementTag
- All Superinterfaces:
IElementTag
,ITemplateEvent
- All Known Subinterfaces:
IOpenElementTag
,IStandaloneElementTag
Event interface defining a processable element tag, i.e an element tag on which processors can be applied (open, standalone).
Note that any implementations of this interface should be immutable.
- Since:
- 3.0.0
- Author:
- Daniel Fernández
-
Method Summary
Modifier and TypeMethodDescriptionReturns an array with all the attributes contained in the tag.getAttribute
(String completeName) Returns the object modelling a specific attribute in the tag (or null if it does not exist).getAttribute
(String prefix, String name) Returns the object modelling a specific attribute in the tag (or null if it does not exist).getAttribute
(AttributeName attributeName) Returns the object modelling a specific attribute in the tag (or null if it does not exist).Returns a Map containing all the attribute names+values in the tag.getAttributeValue
(String completeName) Returns the value of a specific attribute in the tag (or null if it does not exist).getAttributeValue
(String prefix, String name) Returns the value of a specific attribute in the tag (or null if it does not exist).getAttributeValue
(AttributeName attributeName) Returns the value of a specific attribute in the tag (or null if it does not exist).boolean
hasAttribute
(String completeName) Returns whether an attribute is exists at the tag or not.boolean
hasAttribute
(String prefix, String name) Returns whether an attribute is exists at the tag or not.boolean
hasAttribute
(AttributeName attributeName) Returns whether an attribute is exists at the tag or not.Methods inherited from interface org.thymeleaf.model.IElementTag
getElementCompleteName, getElementDefinition, getTemplateMode, isSynthetic
Methods inherited from interface org.thymeleaf.model.ITemplateEvent
accept, getCol, getLine, getTemplateName, hasLocation, write
-
Method Details
-
getAllAttributes
IAttribute[] getAllAttributes()Returns an array with all the attributes contained in the tag.
This array is a defensive copy of the original data kept at the tag, and might be null if there are no attributes at the tag.
- Returns:
- the array of attributes.
-
getAttributeMap
Returns a Map containing all the attribute names+values in the tag.
This array is a defensive copy of the original data kept at the tag, and might be null if there are no attributes at the tag.
- Returns:
- the map of attributes.
-
hasAttribute
Returns whether an attribute is exists at the tag or not.
- Parameters:
completeName
- the complete name of the attribute that is being queried.- Returns:
- true if the attribute exists, false if not.
-
hasAttribute
Returns whether an attribute is exists at the tag or not.
- Parameters:
prefix
- the prefix of the attribute that is being queried (might be null).name
- the name of tha attribute that is being queried.- Returns:
- true if the attribute exists, false if not.
-
hasAttribute
Returns whether an attribute is exists at the tag or not.
- Parameters:
attributeName
- the name of the attribute that is being queried.- Returns:
- true if the attribute exists, false if not.
-
getAttribute
Returns the object modelling a specific attribute in the tag (or null if it does not exist).
- Parameters:
completeName
- the complete name of the attribute that is being queried.- Returns:
- the
IAttribute
for the queried attribute, or null if it does not exist.
-
getAttribute
Returns the object modelling a specific attribute in the tag (or null if it does not exist).
- Parameters:
prefix
- the prefix of the attribute that is being queried (might be null).name
- the name of tha attribute that is being queried.- Returns:
- the
IAttribute
for the queried attribute, or null if it does not exist.
-
getAttribute
Returns the object modelling a specific attribute in the tag (or null if it does not exist).
- Parameters:
attributeName
- the name of the attribute that is being queried.- Returns:
- the
IAttribute
for the queried attribute, or null if it does not exist.
-
getAttributeValue
Returns the value of a specific attribute in the tag (or null if it does not exist).
- Parameters:
completeName
- the complete name of the attribute that is being queried.- Returns:
- the value of the queried attribute, or null if it does not exist.
-
getAttributeValue
Returns the value of a specific attribute in the tag (or null if it does not exist).
- Parameters:
prefix
- the prefix of the attribute that is being queried (might be null).name
- the name of tha attribute that is being queried.- Returns:
- the value of the queried attribute, or null if it does not exist.
-
getAttributeValue
Returns the value of a specific attribute in the tag (or null if it does not exist).
- Parameters:
attributeName
- the name of the attribute that is being queried.- Returns:
- the value of the queried attribute, or null if it does not exist.
-