Class ListUtil


  • public class ListUtil
    extends java.lang.Object
    Author:
    Tony Vaagenes
    • Constructor Summary

      Constructors 
      Constructor Description
      ListUtil()  
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static <T> java.lang.Iterable<T> butFirst​(java.util.Collection<T> collection)  
      static <T> java.util.List<T> butFirst​(java.util.List<T> list)  
      static <T> T first​(java.util.Collection<T> collection)  
      static boolean firstInstanceOf​(java.util.Collection<?> collection, java.lang.Class c)  
      static <T> java.util.List<T> rest​(java.util.List<T> list)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • ListUtil

        public ListUtil()
    • Method Detail

      • rest

        public static <T> java.util.List<T> rest​(java.util.List<T> list)
      • first

        public static <T> T first​(java.util.Collection<T> collection)
      • firstInstanceOf

        public static boolean firstInstanceOf​(java.util.Collection<?> collection,
                                              java.lang.Class c)
      • butFirst

        public static <T> java.util.List<T> butFirst​(java.util.List<T> list)
      • butFirst

        public static <T> java.lang.Iterable<T> butFirst​(java.util.Collection<T> collection)