From 28d059a4ab6355ab6c07c1b49cb32f016d628285 Mon Sep 17 00:00:00 2001 From: =?utf8?q?David=20=E2=80=98Bombe=E2=80=99=20Roden?= Date: Sun, 27 Oct 2019 17:35:18 +0100 Subject: [PATCH] =?utf8?q?=E2=99=BB=EF=B8=8F=20Use=20facade=20instead=20of?= =?utf8?q?=20real=20plugin=20respirator?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- .../pterodactylus/sone/freenet/plugin/PluginConnector.java | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/src/main/java/net/pterodactylus/sone/freenet/plugin/PluginConnector.java b/src/main/java/net/pterodactylus/sone/freenet/plugin/PluginConnector.java index fbaabb3..aa45dbf 100644 --- a/src/main/java/net/pterodactylus/sone/freenet/plugin/PluginConnector.java +++ b/src/main/java/net/pterodactylus/sone/freenet/plugin/PluginConnector.java @@ -25,8 +25,6 @@ import com.google.inject.Singleton; import freenet.pluginmanager.FredPluginTalker; import freenet.pluginmanager.PluginNotFoundException; -import freenet.pluginmanager.PluginRespirator; -import freenet.pluginmanager.PluginTalker; import freenet.support.SimpleFieldSet; import freenet.support.api.Bucket; @@ -41,20 +39,20 @@ public class PluginConnector implements FredPluginTalker { private final EventBus eventBus; /** The plugin respirator. */ - private final PluginRespirator pluginRespirator; + private final PluginRespiratorFacade pluginRespiratorFacade; /** * Creates a new plugin connector. * * @param eventBus * The event bus - * @param pluginRespirator + * @param pluginRespiratorFacade * The plugin respirator */ @Inject - public PluginConnector(EventBus eventBus, PluginRespirator pluginRespirator) { + public PluginConnector(EventBus eventBus, PluginRespiratorFacade pluginRespiratorFacade) { this.eventBus = eventBus; - this.pluginRespirator = pluginRespirator; + this.pluginRespiratorFacade = pluginRespiratorFacade; } // @@ -110,9 +108,9 @@ public class PluginConnector implements FredPluginTalker { * @throws PluginException * if the plugin can not be found */ - private PluginTalker getPluginTalker(String pluginName, String identifier) throws PluginException { + private PluginTalkerFacade getPluginTalker(String pluginName, String identifier) throws PluginException { try { - return pluginRespirator.getPluginTalker(this, pluginName, identifier); + return pluginRespiratorFacade.getPluginTalker(this, pluginName, identifier); } catch (PluginNotFoundException pnfe1) { throw new PluginException(pnfe1); } -- 2.7.4