Interface IFormLifecyclePlugin

All Superinterfaces:
IFCPlugin, INamedUiElement, INameProviding, ITransferable, Serializable
All Known Subinterfaces:
IPluginFormPrePersist, IPluginFormPreProcess, IPluginFormPreRender, IPluginFormPreRespond

public interface IFormLifecyclePlugin extends IFCPlugin
Base interface for plugins which hook into the lifecycle of the form, such as pre-render or pre-process plugins.
Since:
7.4.0
Author:
XIMA MEDIA GmbH
  • Method Details

    • shouldExecute

      boolean shouldExecute(IFormLifecycleShouldExecuteParams params)
      Optional test to decide whether a form lifecycle plugin should be executed for a particular form request. Use e.g. params.getRequestContext().getRequestType() to check the type of the request.

      Note: Lifecycle plugins may be queued for execution at points were they were not before. Implementations of this method should prefer narrow checks, e.g.

       return params.getFormRequestContext().getRequestType() == EFormRequestType.PROVIDE}
       
      instead of
       return params.getFormRequestContext().getRequestType() != EFormRequestType.PROCESS
       
      Parameters:
      params - Parameters with the current form request.
      Returns:
      true if the plugin should be executed during the lifecycle of the given form request, false otherwise.
      Throws:
      RuntimeException - This method should never throw an exception, but if it does, it is handled as if this method had returned false.