Class EventBusImpl

java.lang.Object
com.xpdustry.distributor.common.event.EventBusImpl
All Implemented Interfaces:
com.xpdustry.distributor.api.event.EventBus

public final class EventBusImpl extends Object implements com.xpdustry.distributor.api.event.EventBus
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    <E> void
    post(E event)
     
    <E> void
    post(Class<? super E> clazz, E event)
     
    <E extends Enum<E>>
    com.xpdustry.distributor.api.event.EventSubscription
    subscribe(E event, com.xpdustry.distributor.api.util.Priority priority, com.xpdustry.distributor.api.plugin.MindustryPlugin plugin, Runnable listener)
     
    <E> com.xpdustry.distributor.api.event.EventSubscription
    subscribe(Class<E> event, com.xpdustry.distributor.api.util.Priority priority, com.xpdustry.distributor.api.plugin.MindustryPlugin plugin, Consumer<E> listener)
     

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface com.xpdustry.distributor.api.event.EventBus

    subscribe, subscribe
  • Constructor Details

    • EventBusImpl

      public EventBusImpl()
  • Method Details

    • subscribe

      public <E> com.xpdustry.distributor.api.event.EventSubscription subscribe(Class<E> event, com.xpdustry.distributor.api.util.Priority priority, com.xpdustry.distributor.api.plugin.MindustryPlugin plugin, Consumer<E> listener)
      Specified by:
      subscribe in interface com.xpdustry.distributor.api.event.EventBus
    • subscribe

      public <E extends Enum<E>> com.xpdustry.distributor.api.event.EventSubscription subscribe(E event, com.xpdustry.distributor.api.util.Priority priority, com.xpdustry.distributor.api.plugin.MindustryPlugin plugin, Runnable listener)
      Specified by:
      subscribe in interface com.xpdustry.distributor.api.event.EventBus
    • post

      public <E> void post(E event)
      Specified by:
      post in interface com.xpdustry.distributor.api.event.EventBus
    • post

      public <E> void post(Class<? super E> clazz, E event)
      Specified by:
      post in interface com.xpdustry.distributor.api.event.EventBus
    • post

      public <E extends Enum<E>> void post(E event)
      Specified by:
      post in interface com.xpdustry.distributor.api.event.EventBus