Class ModuleEvent
java.lang.Object
eu.cloudnetservice.driver.event.Event
eu.cloudnetservice.driver.event.events.module.ModuleEvent
- Direct Known Subclasses:
ModulePostLoadEvent, ModulePostReloadEvent, ModulePostStartEvent, ModulePostStopEvent, ModulePostUnloadEvent, ModulePreLoadEvent, ModulePreReloadEvent, ModulePreStartEvent, ModulePreStopEvent, ModulePreUnloadEvent
The base event for all events which are related to modules. By default, all module state changes have their own
event. See the package files for a list of all modules.
Each module event contains the associated module and the provider which is associated with the module action.
- Since:
- 4.0
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionModuleEvent(@NonNull ModuleProvider moduleProvider, @NonNull ModuleWrapper module) Constructs a new module event. -
Method Summary
Modifier and TypeMethodDescriptionmodule()Get the module on which the action is currently taking place.Get the module provider from which the associated module was loaded.
-
Field Details
-
module
-
moduleProvider
-
-
Constructor Details
-
ModuleEvent
public ModuleEvent(@NonNull @NonNull ModuleProvider moduleProvider, @NonNull @NonNull ModuleWrapper module) Constructs a new module event.- Parameters:
moduleProvider- the provider in which the module is loaded.module- the module which is associated with this event.- Throws:
NullPointerException- if either the provider or wrapper is null.
-
-
Method Details
-
moduleProvider
Get the module provider from which the associated module was loaded.- Returns:
- the module provider from which the associated module was loaded.
-
module
Get the module on which the action is currently taking place.- Returns:
- the module on which the action is currently taking place.
-