EventLoader

Handles loading and registering Event class event handlers from registered source directories.

Constructor

new EventLoader()

Source:

Methods

.addSourceDir() → void

Registers a source directory to load Event class event handlers from. Does nothing if the directory is already registered. Events will be loaded by the Client after the continue event is emitted at runtime

Source:
Returns:
void

.hasSources() → boolean

Returns whether or not the EventLoader has any registered source directories

Source:
Returns:
boolean

.loadFromSources() → number

Loads or reloads all Events from all registered sources. Allows for hot-reloading

Source:
Returns:

The total number of loaded or reloaded events

number