Class CustomEventAttribute

All Implemented Interfaces:
TagBase, EventAttribute, Serializable, Cloneable

public class CustomEventAttribute extends AbstractEventAttribute
See Also:
  • Constructor Details

    • CustomEventAttribute

      public CustomEventAttribute(String attributeName, ServerAsyncMethod serverAsyncMethod)
    • CustomEventAttribute

      public CustomEventAttribute(String attributeName, String jsPreFunctionBody, ServerAsyncMethod serverAsyncMethod, String jsFilterFunctionBody, String jsPostFunctionBody)
    • CustomEventAttribute

      public CustomEventAttribute(String attributeName, ServerAsyncMethod serverAsyncMethod, Object serverSideData)
      Parameters:
      attributeName -
      serverAsyncMethod -
      serverSideData -
      Since:
      3.0.2
    • CustomEventAttribute

      public CustomEventAttribute(String attributeName, String jsPreFunctionBody, ServerAsyncMethod serverAsyncMethod, String jsFilterFunctionBody, String jsPostFunctionBody, Object serverSideData)
      Parameters:
      attributeName -
      jsPreFunctionBody -
      serverAsyncMethod -
      jsFilterFunctionBody -
      jsPostFunctionBody -
      serverSideData -
      Since:
      3.0.2
    • CustomEventAttribute

      public CustomEventAttribute(String attributeName, boolean preventDefault, String jsPreFunctionBody, ServerAsyncMethod serverAsyncMethod, String jsFilterFunctionBody, String jsPostFunctionBody, Object serverSideData)
      Parameters:
      attributeName -
      preventDefault - true to call event.preventDefault(); on event otherwise false. In almost all cases this may not be required.
      jsPreFunctionBody -
      serverAsyncMethod -
      jsFilterFunctionBody -
      jsPostFunctionBody -
      serverSideData -
      Since:
      3.0.15
    • CustomEventAttribute

      public CustomEventAttribute(String attributeName, boolean preventDefault, String jsPreFunctionBody, ServerAsyncMethod serverAsyncMethod, String jsFilterFunctionBody, String jsPostFunctionBody)
      Parameters:
      attributeName -
      preventDefault - true to call event.preventDefault(); on event otherwise false. In almost all cases this may not be required.
      jsPreFunctionBody -
      serverAsyncMethod -
      jsFilterFunctionBody -
      jsPostFunctionBody -
      Since:
      3.0.15
  • Method Details

    • isPreventDefault

      public boolean isPreventDefault()
      Description copied from class: AbstractEventAttribute
      This is applicable for some special attributes like OnSubmit.
      Overrides:
      isPreventDefault in class AbstractEventAttribute
      Returns:
      true or false. true means to call event.preventDefault() on event otherwise false.
    • setPreventDefault

      public void setPreventDefault(boolean preventDefault)
      Description copied from class: AbstractEventAttribute
      true to call event.preventDefault(); on event. It will set only if there is ServerAsyncMethod. This is applicable for some special attributes like OnSubmit.
      Overrides:
      setPreventDefault in class AbstractEventAttribute
      Parameters:
      preventDefault - true to call event.preventDefault(); on event otherwise false.