org.thymeleaf.expression
Class Objects

Object
  extended by org.thymeleaf.expression.Objects

public final class Objects
extends Object

Utility class for performing operations related to general object management.

An object of this class is usually available in variable evaluation expressions with the name #objects.

Since:
1.0
Author:
Daniel Fernández

Constructor Summary
Objects()
           
 
Method Summary
<T> T[]
arrayNullSafe(T[] target, T defaultValue)
           
<T> java.util.List<T>
listNullSafe(java.util.List<T> target, T defaultValue)
           
<T> T
nullSafe(T target, T defaultValue)
           
<T> java.util.Set<T>
setNullSafe(java.util.Set<T> target, T defaultValue)
           
 
Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Objects

public Objects()
Method Detail

nullSafe

public <T> T nullSafe(T target,
                      T defaultValue)

arrayNullSafe

public <T> T[] arrayNullSafe(T[] target,
                             T defaultValue)

listNullSafe

public <T> java.util.List<T> listNullSafe(java.util.List<T> target,
                                          T defaultValue)

setNullSafe

public <T> java.util.Set<T> setNullSafe(java.util.Set<T> target,
                                        T defaultValue)


Copyright © 2012 The THYMELEAF team. All Rights Reserved.