Class ScriptEvaluatingEvent

  • All Implemented Interfaces:
    Serializable, CancelableEvent, Event, FilterableEvent

    public class ScriptEvaluatingEvent
    extends AbstractCancelableEvent
    An event triggered just before evaluation of a script macro (Groovy, Velocity, etc.) is started. The script will not be executed if this event is canceled.

    This event is supposed to be sent with org.xwiki.rendering.transformation.MacroTransformationContext as the source and org.xwiki.rendering.macro.script.ScriptMacroParameters as data.

    $Id: 7d0c1237cbdd0acc5816aacdcf7e66293abe1615 $
    See Also:
    ScriptEvaluatedEvent, Serialized Form
    • Constructor Detail

      • ScriptEvaluatingEvent

        public ScriptEvaluatingEvent()
        Constructor initializing the event filter with an AlwaysMatchingEventFilter, meaning that this event will match any other event of the same type.
      • ScriptEvaluatingEvent

        public ScriptEvaluatingEvent​(String scriptMacroName)
        Constructor initializing the event filter with a FixedNameEventFilter, meaning that this event will match only events of the same type affecting the same passed name.
        scriptMacroName - name of the macro to match, e.g. "velocity"
      • ScriptEvaluatingEvent

        public ScriptEvaluatingEvent​(EventFilter eventFilter)
        Constructor using a custom EventFilter.
        eventFilter - the filter to use for matching events