Class GoAndClearFilter

    • Constructor Detail

      • GoAndClearFilter

        public GoAndClearFilter​(String id,
                                FilterForm<?> form)
        Constructor This constructor will use default models for the 'clear' and 'go' button labels. Uses the form's model object as an original state
        Parameters:
        id - component id
        form - filter form of the filter toolbar
      • GoAndClearFilter

        public GoAndClearFilter​(String id,
                                FilterForm<?> form,
                                IModel<String> goModel,
                                IModel<String> clearModel)
        Constructor. Uses the form's model object as an original state
        Parameters:
        id - component id
        form - filter form of the filter toolbar
        goModel - model for the label of the 'go' button
        clearModel - model for the label of the 'clear' button
      • GoAndClearFilter

        public GoAndClearFilter​(String id,
                                IModel<String> goModel,
                                IModel<String> clearModel,
                                Object originalState)
        Constructor
        Parameters:
        id - component id
        goModel - model for the label of the 'go' button
        clearModel - model for the label of the 'clear' button
        originalState - the object to use as original state
    • Method Detail

      • getClearButton

        protected Button getClearButton()
        Returns:
        button component representing the clear button
      • onClearSubmit

        protected void onClearSubmit​(Button button)
        This method should be implemented by subclasses to provide behavior for the clear button.
        Parameters:
        button - the 'clear' button