Annotation Type EventHandler


  • @Target(METHOD)
    @Retention(RUNTIME)
    public @interface EventHandler
    Represent an event listener method. It means this method mush own one argument whose class is an implemented Event.
    • Optional Element Summary

      Optional Elements 
      Modifier and Type Optional Element Description
      boolean notCallIfCancelled
      Set whether this method should be called when the event is cancelled
      boolean notCallIfPrevented
      Set whether this method should be called when the event is prevented
      EventPriority priority
      Set the priority of this event listener method
    • Element Detail

      • priority

        EventPriority priority
        Set the priority of this event listener method
        Returns:
        the priority of this event listener method
        Default:
        top.focess.qq.api.event.EventPriority.NORMAL
      • notCallIfCancelled

        boolean notCallIfCancelled
        Set whether this method should be called when the event is cancelled
        Returns:
        true if this method should be called when the event is cancelled, false otherwise
        Default:
        false
      • notCallIfPrevented

        boolean notCallIfPrevented
        Set whether this method should be called when the event is prevented
        Returns:
        true if this method should be called when the event is prevented, false otherwise
        Default:
        false