Enum Stability

    • Enum Constant Detail

      • DEFAULT

        public static final Stability DEFAULT
      • COMMUNITY

        public static final Stability COMMUNITY
      • PREVIEW

        public static final Stability PREVIEW
      • EXPERIMENTAL

        public static final Stability EXPERIMENTAL
    • Method Detail

      • values

        public static Stability[] values()
        Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
        for (Stability c : Stability.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static Stability valueOf​(String name)
        Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
        Parameters:
        name - the name of the enum constant to be returned.
        Returns:
        the enum constant with the specified name
        Throws:
        IllegalArgumentException - if this enum type has no constant with the specified name
        NullPointerException - if the argument is null
      • enables

        public boolean enables​(Stability stability)
        Indicates whether this stability enables the specified stability level.
        Parameters:
        stability - a stability level
        Returns:
        true, if this stability level enables the specified stability level, false otherwise.
      • map

        public static <F> Map<Stability,​F> map​(Function<Stability,​F> features)
        Returns a complete map of a feature per stability level.
        Type Parameters:
        F - the feature type
        Parameters:
        features - a function returning the feature of a given stability level
        Returns:
        a full mapping of feature per stability level