All Implemented Interfaces:
Serializable, Iterable<Component>, IEventSink, IEventSource, IFeedbackContributor, IConverterLocator, IGenericComponent<String,FormComponent<String>>, IMetadataContext<Serializable,Component>, IFormModelUpdateListener, IFormSubmitter, IFormSubmittingComponent, IFormVisitorParticipant, ILabelProvider<String>, IHeaderContributor, IRequestableComponent, IHierarchical<Component>, IClusterable

public class NextButton extends WizardButton
Models a next button in the wizard. When pressed, it calls IWizardStep.applyState() on the active wizard step, and then moves the wizard state to the next step of the model by calling next on the wizard's model.
Author:
Eelco Hillenius
See Also:
  • Constructor Details

  • Method Details

    • onConfigure

      protected void onConfigure()
      Description copied from class: Component
      Called on all components before any component is rendered. This method should be used to configure such things as visibility and enabled flags.

      Overrides must call super.onConfigure(), usually before any other code

      NOTE: Component hierarchy should not be modified inside this method, instead it should be done in Component.onBeforeRender()

      NOTE: Why this method is preferrable to directly overriding Component.isVisible() and Component.isEnabled()? Because those methods are called multiple times even for processing of a single request. If they contain expensive logic they can slow down the response time of the entire page. Further, overriding those methods directly on form components may lead to inconsistent or unexpected state depending on when those methods are called in the form processing workflow. It is a better practice to push changes to state rather than pull.

      NOTE: If component's visibility or another property depends on another component you may call other.configure() followed by other.isVisible() as mentioned in Component.configure() javadoc.

      NOTE: Why should Component.onBeforeRender() not be used for this? Because if a component's visibility is controlled inside Component.onBeforeRender(), once invisible the component will never become visible again.

      Overrides:
      onConfigure in class Component
    • onClick

      public void onClick()
      Description copied from class: WizardButton
      Called when this button is clicked.
      Specified by:
      onClick in class WizardButton
      See Also:
    • onBeforeRender

      protected void onBeforeRender()
      Description copied from class: Component
      Called on all visible components before any component is rendered.

      NOTE: If you override this, you *must* call super.onBeforeRender() within your implementation. Because this method is responsible for cascading Component.onBeforeRender() call to its children it is strongly recommended that super call is made at the end of the override.

      Changes to the component tree can be made only before calling super.onBeforeRender().
      Overrides:
      onBeforeRender in class FormComponent<String>
      See Also: