Thymeleaf is created for the Java-based application template engine. The engine has many helper classes and utility methods for processing any kind of a variable. In this article, we will present utility methods for
Sets. The implementation of
Sets utility methods can be found in the official Thymeleaf GitHub Repository.
2. Available utility methods for
Thymeleaf comes with several utility methods for Sets.
||Converts to set|
||Check whether set is empty|
||Check if element or elements are contained in set|
In this article, we presented Thymeleaf utility methods for
Set objects. Set is a Java collection of unique elements. Thymeleaf utility methods allow you to check if
Set is empty, or contains an element or many elements or check the size of your collection.