Refactored event calling so its front loading avoiding the lookup for each event call.
This now uses an annoymous class implementing IExecutor that facilitates direct event method handler calling Changed commands from being executed exclusively by a player to by a CommandSender to facilitate external command callers such as rcon Fixed CustomEventListener Merged in additional events Added getFullName to PluginDescriptionFile which returns the combination of Name and Version There's also a few bits of reformatting as it seems someones been editing with either tabs or dos eol :( By: stevenh <steven.hartland@multiplay.co.uk>
This commit is contained in:
@@ -5,6 +5,7 @@ import java.io.File;
|
||||
import java.util.regex.Pattern;
|
||||
|
||||
import org.bukkit.event.Event;
|
||||
import org.bukkit.event.Listener;
|
||||
|
||||
/**
|
||||
* Represents a plugin loader, which handles direct access to specific types
|
||||
@@ -27,13 +28,12 @@ public interface PluginLoader {
|
||||
public Pattern[] getPluginFileFilters();
|
||||
|
||||
/**
|
||||
* Calls a player related event with the given details
|
||||
* Creates and returns an event executor
|
||||
*
|
||||
* @param registration Registered information on the plugin to call about this event
|
||||
* @param type Type of player related event to call
|
||||
* @param event Event details
|
||||
* @param type Type of the event executor to create
|
||||
* @param listener the object that will handle the eventual call back
|
||||
*/
|
||||
public void callEvent(RegisteredListener registration, Event event);
|
||||
public IExecutor createExecutor(Event.Type type, Listener listener);
|
||||
|
||||
/**
|
||||
* Enables the specified plugin
|
||||
|
||||
Reference in New Issue
Block a user