Enum Form.Operation

    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
      CANCEL
      Cancels any modifications to the model and calls the cancel callback.
      CLEAR
      Clears this form by removing the model reference and by clearing all bound form fields.
      EDIT
      Takes the specified model and populates the bound form fields with the values from the model.
      REMOVE
      Removes the model and calls the remove callback.
      RESET
      Resets the model and updates the bound form field.
      SAVE
      Validates the form and its fields and upon successful validation persists the changes to the model and calls the save callback.
      VIEW
      Takes the specified model and updates the read-only state with the values from the model.
    • Enum Constant Detail

      • VIEW

        public static final Form.Operation VIEW
        Takes the specified model and updates the read-only state with the values from the model.
      • CLEAR

        public static final Form.Operation CLEAR
        Clears this form by removing the model reference and by clearing all bound form fields. Does not modify the model!
      • RESET

        public static final Form.Operation RESET
        Resets the model and updates the bound form field.
      • EDIT

        public static final Form.Operation EDIT
        Takes the specified model and populates the bound form fields with the values from the model.
      • SAVE

        public static final Form.Operation SAVE
        Validates the form and its fields and upon successful validation persists the changes to the model and calls the save callback.
      • CANCEL

        public static final Form.Operation CANCEL
        Cancels any modifications to the model and calls the cancel callback.
      • REMOVE

        public static final Form.Operation REMOVE
        Removes the model and calls the remove callback.
    • Method Detail

      • values

        public static Form.Operation[] 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 (Form.Operation c : Form.Operation.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static Form.Operation 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