Class PluginExecutor<G extends GameObject<G,​A,​R>,​A extends MapArchObject<A>,​R extends Archetype<G,​A,​R>>

    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      @Nullable BshRunnable<G,​A,​R> doRunPlugin​(@NotNull Plugin<G,​A,​R> plugin, @NotNull bsh.ConsoleInterface console, @NotNull java.util.Map<java.lang.String,​java.lang.Object> parameters)
      Runs a plugin model.
      int executePlugin​(@NotNull java.lang.String plugin, @NotNull java.lang.Iterable<java.lang.String> parameters)
      Executes an editor plugin.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • PluginExecutor

        public PluginExecutor​(@NotNull
                              @NotNull PluginModel<G,​A,​R> pluginModel,
                              @NotNull
                              @NotNull PluginParameters pluginParameters)
        Creates a new instance.
        Parameters:
        pluginModel - the plugin model to execute
        pluginParameters - the parameters to pass to the plugin
    • Method Detail

      • executePlugin

        public int executePlugin​(@NotNull
                                 @NotNull java.lang.String plugin,
                                 @NotNull
                                 @NotNull java.lang.Iterable<java.lang.String> parameters)
        Executes an editor plugin.
        Parameters:
        plugin - the plugin name to execute
        parameters - the plugin parameters
        Returns:
        whether an error occurred
      • doRunPlugin

        @Nullable
        public @Nullable BshRunnable<G,​A,​R> doRunPlugin​(@NotNull
                                                                    @NotNull Plugin<G,​A,​R> plugin,
                                                                    @NotNull
                                                                    @NotNull bsh.ConsoleInterface console,
                                                                    @NotNull
                                                                    @NotNull java.util.Map<java.lang.String,​java.lang.Object> parameters)
        Runs a plugin model.
        Parameters:
        plugin - the plugin model
        console - the console to use
        parameters - the parameters to pass to the plugin
        Returns:
        the thread executing the script