Class OnConfigReloadInvoker
java.lang.Object
tech.guilhermekaua.spigotboot.config.reload.OnConfigReloadInvoker
Invokes
@OnConfigReload callback methods reflectively, isolating any failure so it never
escapes a config reload listener.-
Constructor Summary
Constructors -
Method Summary
-
Constructor Details
-
OnConfigReloadInvoker
Creates the invoker.- Parameters:
logger- the plugin logger, not null
-
-
Method Details
-
invoke
public void invoke(@NotNull @NotNull Object bean, @NotNull @NotNull Method method, @NotNull @NotNull Object[] args) Invokes the given callback. Exceptions thrown by the callback are logged, not rethrown.- Parameters:
bean- the bean instance to invoke on, not nullmethod- the callback method, not nullargs- the arguments to pass, not null (may be empty)
-