import net.pterodactylus.sone.core.Core;
import net.pterodactylus.sone.core.FreenetInterface;
import net.pterodactylus.sone.freenet.PluginStoreConfigurationBackend;
+import net.pterodactylus.sone.freenet.fcp.FcpInterface;
import net.pterodactylus.sone.freenet.plugin.PluginConnector;
import net.pterodactylus.sone.freenet.wot.IdentityManager;
import net.pterodactylus.sone.freenet.wot.WebOfTrustConnector;
import freenet.l10n.PluginL10n;
import freenet.pluginmanager.FredPlugin;
import freenet.pluginmanager.FredPluginBaseL10n;
+import freenet.pluginmanager.FredPluginFCP;
import freenet.pluginmanager.FredPluginL10n;
import freenet.pluginmanager.FredPluginThreadless;
import freenet.pluginmanager.FredPluginVersioned;
+import freenet.pluginmanager.PluginReplySender;
import freenet.pluginmanager.PluginRespirator;
+import freenet.support.SimpleFieldSet;
+import freenet.support.api.Bucket;
/**
* This class interfaces with Freenet. It is the class that is loaded by the
*
* @author <a href="mailto:bombe@pterodactylus.net">David ‘Bombe’ Roden</a>
*/
-public class SonePlugin implements FredPlugin, FredPluginL10n, FredPluginBaseL10n, FredPluginThreadless, FredPluginVersioned {
+public class SonePlugin implements FredPlugin, FredPluginFCP, FredPluginL10n, FredPluginBaseL10n, FredPluginThreadless, FredPluginVersioned {
static {
/* initialize logging. */
/** The web interface. */
private WebInterface webInterface;
+ /** The FCP interface. */
+ private FcpInterface fcpInterface;
+
/** The l10n helper. */
private PluginL10n l10n;
webInterface = new WebInterface(this);
core.addCoreListener(webInterface);
+ /* create FCP interface. */
+ fcpInterface = new FcpInterface(core);
+
/* create the identity manager. */
identityManager.addIdentityListener(core);
}
//
+ // INTERFACE FredPluginFCP
+ //
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public void handle(PluginReplySender pluginReplySender, SimpleFieldSet parameters, Bucket data, int accessType) {
+ fcpInterface.handle(pluginReplySender, parameters, data, accessType);
+ }
+
+ //
// INTERFACE FredPluginL10n
//