Class CollectionConverter


  • @Converter(generateLoader=true)
    public final class CollectionConverter
    extends Object
    Some core java.util Collection based Type Converters
    • Method Detail

      • toArray

        @Converter
        public static Object[] toArray​(Collection<?> value)
        Converts a collection to an array
      • toList

        @Converter
        public static List<Object> toList​(Object[] array)
        Converts an array to a collection
      • toList

        @Converter
        public static <T> List<T> toList​(Collection<T> collection)
        Converts a collection to a List if it is not already
      • toSet

        @Converter
        public static <T> Set<T> toSet​(Collection<T> collection)
      • toSet

        @Converter
        public static <K,​V> Set<Map.Entry<K,​V>> toSet​(Map<K,​V> map)
      • toHashtable

        @Converter
        public static <K,​V> Hashtable<K,​V> toHashtable​(Map<? extends K,​? extends V> map)
      • toHashMap

        @Converter
        public static <K,​V> HashMap<K,​V> toHashMap​(Map<? extends K,​? extends V> map)