Class FieldUtils

Object
org.thymeleaf.spring6.util.FieldUtils

public final class FieldUtils extends Object

Static utility class containing methods for dealing with form fields in Spring-enabled environments.

Note a class with this name existed since 1.0, but it was completely reimplemented in Thymeleaf 3.0

Since:
3.0.3
Author:
Daniel Fernández, Tobias Gafner
  • Field Details

  • Method Details

    • hasErrors

      public static boolean hasErrors(org.thymeleaf.context.IExpressionContext context, String field)
    • hasAnyErrors

      public static boolean hasAnyErrors(org.thymeleaf.context.IExpressionContext context)
    • hasGlobalErrors

      public static boolean hasGlobalErrors(org.thymeleaf.context.IExpressionContext context)
    • errors

      public static List<String> errors(org.thymeleaf.context.IExpressionContext context, String field)
    • errors

      public static List<String> errors(org.thymeleaf.context.IExpressionContext context)
    • globalErrors

      public static List<String> globalErrors(org.thymeleaf.context.IExpressionContext context)
    • detailedErrors

      public static List<DetailedError> detailedErrors(org.thymeleaf.context.IExpressionContext context)
    • detailedErrors

      public static List<DetailedError> detailedErrors(org.thymeleaf.context.IExpressionContext context, String field)
    • globalDetailedErrors

      public static List<DetailedError> globalDetailedErrors(org.thymeleaf.context.IExpressionContext context)
    • idFromName

      public static String idFromName(String fieldName)
    • getBindStatus

      public static IThymeleafBindStatus getBindStatus(org.thymeleaf.context.IExpressionContext context, String expression)
    • getBindStatus

      public static IThymeleafBindStatus getBindStatus(org.thymeleaf.context.IExpressionContext context, boolean optional, String expression)
    • getBindStatusFromParsedExpression

      public static IThymeleafBindStatus getBindStatusFromParsedExpression(org.thymeleaf.context.IExpressionContext context, boolean useSelectionAsRoot, String expression)
    • getBindStatusFromParsedExpression

      public static IThymeleafBindStatus getBindStatusFromParsedExpression(org.thymeleaf.context.IExpressionContext context, boolean optional, boolean useSelectionAsRoot, String expression)