Class KiwiEnums2


  • @Beta
    public final class KiwiEnums2
    extends Object
    Static utilities for working with Enum.

    These may eventually be moved into KiwiEnums in kiwi.

    • Method Detail

      • entries

        public static <E extends Enum<E>> List<E> entries​(Class<E> enumClass)
        Return the constants in the given enum class as a list.
        Type Parameters:
        E - the type in the enum
        Parameters:
        enumClass - the enum class
        Returns:
        an unmodifiable list containing the enum constants
        Throws:
        IllegalArgumentException - if the given class is not an enum