mirror of
https://github.com/BentoBoxWorld/BentoBox.git
synced 2024-09-07 12:58:02 +02:00
Added ability to explicitly define asynchronous PremadeEvent (#763)
* Add ability to define asynchronous event * minor formatting * Removed another line jump
This commit is contained in:
parent
3c1f033819
commit
d1e9188959
@ -8,6 +8,24 @@ import org.bukkit.event.HandlerList;
|
||||
*/
|
||||
public abstract class PremadeEvent extends Event {
|
||||
|
||||
/**
|
||||
* The default constructor is defined for cleaner code.
|
||||
* This constructor assumes the PremadeEvent is synchronous.
|
||||
*/
|
||||
public PremadeEvent() {
|
||||
this(false);
|
||||
}
|
||||
|
||||
/**
|
||||
* This constructor is used to explicitly declare an PremadeEvent as synchronous or asynchronous.
|
||||
* @param async - true indicates the event will fire asynchronously, false
|
||||
* by default from default constructor
|
||||
* @since 1.5.2
|
||||
*/
|
||||
public PremadeEvent(boolean async) {
|
||||
super(async);
|
||||
}
|
||||
|
||||
private static final HandlerList handlers = new HandlerList();
|
||||
|
||||
@Override
|
||||
|
Loading…
Reference in New Issue
Block a user