X-Git-Url: https://git.pterodactylus.net/?a=blobdiff_plain;f=src%2Fmain%2Fjava%2Fnet%2Fpterodactylus%2Fsone%2Fmain%2FSonePlugin.java;h=42e2fe1dfc08f44a9060b0e3d023ccf44b7496fd;hb=927de326e0af0f11a27b3444f4e25b0796c877db;hp=573ed73bd54cdaeca52c4e247a001db9fedd64f4;hpb=5a9e7b3b9e2ffa21edb6b8d223d9f4d514f05f28;p=Sone.git diff --git a/src/main/java/net/pterodactylus/sone/main/SonePlugin.java b/src/main/java/net/pterodactylus/sone/main/SonePlugin.java index 573ed73..42e2fe1 100644 --- a/src/main/java/net/pterodactylus/sone/main/SonePlugin.java +++ b/src/main/java/net/pterodactylus/sone/main/SonePlugin.java @@ -1,5 +1,5 @@ /* - * Sone - SonePlugin.java - Copyright © 2010 David Roden + * Sone - SonePlugin.java - Copyright © 2010–2012 David Roden * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -24,6 +24,9 @@ import java.util.logging.Logger; import net.pterodactylus.sone.core.Core; import net.pterodactylus.sone.core.FreenetInterface; +import net.pterodactylus.sone.core.WebOfTrustUpdater; +import net.pterodactylus.sone.database.Database; +import net.pterodactylus.sone.database.memory.MemoryDatabase; import net.pterodactylus.sone.fcp.FcpInterface; import net.pterodactylus.sone.freenet.PluginStoreConfigurationBackend; import net.pterodactylus.sone.freenet.plugin.PluginConnector; @@ -83,7 +86,7 @@ public class SonePlugin implements FredPlugin, FredPluginFCP, FredPluginL10n, Fr } /** The version. */ - public static final Version VERSION = new Version(0, 8, 1); + public static final Version VERSION = new Version(0, 8, 2); /** The logger. */ private static final Logger logger = Logging.getLogger(SonePlugin.class); @@ -188,8 +191,15 @@ public class SonePlugin implements FredPlugin, FredPluginFCP, FredPluginL10n, Fr identityManager = new IdentityManager(webOfTrustConnector); identityManager.setContext("Sone"); + /* create Sone database. */ + Database soneDatabase = new MemoryDatabase(); + + /* create trust updater. */ + WebOfTrustUpdater trustUpdater = new WebOfTrustUpdater(webOfTrustConnector); + trustUpdater.init(); + /* create core. */ - core = new Core(oldConfiguration, freenetInterface, identityManager); + core = new Core(oldConfiguration, soneDatabase, freenetInterface, identityManager, trustUpdater); /* create the web interface. */ webInterface = new WebInterface(this);