Author: xor
Date: 2008-11-08 00:12:08 +0000 (Sat, 08 Nov 2008)
New Revision: 23399
Removed:
trunk/plugins/Freetalk/FTDealer.java
trunk/plugins/Freetalk/XMLUtils.java
Modified:
trunk/plugins/Freetalk/Backup.java
trunk/plugins/Freetalk/Freetalk.java
Log:
Remove not needed code.
Modified: trunk/plugins/Freetalk/Backup.java
===================================================================
--- trunk/plugins/Freetalk/Backup.java 2008-11-07 23:29:41 UTC (rev 23398)
+++ trunk/plugins/Freetalk/Backup.java 2008-11-08 00:12:08 UTC (rev 23399)
@@ -30,7 +30,9 @@
private static SAXParser saxParser;
public final static void exportConfigDb(ObjectContainer config_db,
Writer ow) throws IOException {
-
+ /* Creating XML manually is a bad idea so lets comment this out
*/
+
+ /*
Writer w = new BufferedWriter(ow);
w.write("<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n");
@@ -77,8 +79,10 @@
w.write("\t</Identities>\n");
w.write("</fms-kidding>\n");
+
w.flush();
w.close();
+ */
}
public final static void importConfigDb(ObjectContainer config_db,
InputStream is) throws IOException, ParserConfigurationException, SAXException {
Deleted: trunk/plugins/Freetalk/FTDealer.java
===================================================================
--- trunk/plugins/Freetalk/FTDealer.java 2008-11-07 23:29:41 UTC (rev
23398)
+++ trunk/plugins/Freetalk/FTDealer.java 2008-11-08 00:12:08 UTC (rev
23399)
@@ -1,31 +0,0 @@
-/* This code is part of Freenet. It is distributed under the GNU General
- * Public License, version 2 (or at your option any later version). See
- * http://www.gnu.org/ for further details of the GPL. */
-package plugins.Freetalk;
-
-import freenet.support.Executor;
-import freenet.support.Logger;
-
-public class FTDealer {
-
- private final Executor _executor;
-
- // services
- private FTIdentityManager identManager;
-
- FTDealer(Executor executor) {
- this._executor = executor;
- _executor.execute(new Runnable() {
- public void run() {
- startDealer();
- }}, "Dealer starter");
- }
-
- private void startDealer() {
- Logger.error(this, "Starting dealer", new Error("TODO"));
- }
-
- synchronized void killMe() {
- Logger.error(this, "Killing dealer", new Error("TODO"));
- }
-}
Modified: trunk/plugins/Freetalk/Freetalk.java
===================================================================
--- trunk/plugins/Freetalk/Freetalk.java 2008-11-07 23:29:41 UTC (rev
23398)
+++ trunk/plugins/Freetalk/Freetalk.java 2008-11-08 00:12:08 UTC (rev
23399)
@@ -15,7 +15,6 @@
import plugins.Freetalk.ui.Messages;
import plugins.Freetalk.ui.Status;
import plugins.Freetalk.ui.Welcome;
-import plugins.WoT.WoT;
import com.db4o.Db4o;
import com.db4o.ObjectContainer;
@@ -49,7 +48,7 @@
import freenet.support.io.TempBucketFactory;
/**
- * @author saces
+ * @author saces, xor
*
*/
public class Freetalk implements FredPlugin, FredPluginFCP, FredPluginHTTP,
FredPluginL10n, FredPluginThemed, FredPluginThreadless, FredPluginVersioned {
@@ -116,7 +115,7 @@
tbf = pr.getNode().clientCore.tempBucketFactory;
Logger.debug(this, "Creating identity manager...");
- mIdentityManager = new FTIdentityManagerWoT(db,
pr.getNode().executor, (WoT)getWoTPlugin() );
+ mIdentityManager = new FTIdentityManagerWoT(db,
pr.getNode().executor);
Logger.debug(this, "Creating message manager...");
mMessageManager = new FTMessageManagerWoT(db,
pr.getNode().executor, mIdentityManager);
Deleted: trunk/plugins/Freetalk/XMLUtils.java
===================================================================
--- trunk/plugins/Freetalk/XMLUtils.java 2008-11-07 23:29:41 UTC (rev
23398)
+++ trunk/plugins/Freetalk/XMLUtils.java 2008-11-08 00:12:08 UTC (rev
23399)
@@ -1,44 +0,0 @@
-/* This code is part of Freenet. It is distributed under the GNU General
- * Public License, version 2 (or at your option any later version). See
- * http://www.gnu.org/ for further details of the GPL. */
-package plugins.Freetalk;
-
-import java.io.IOException;
-import java.io.Writer;
-
-/**
- * @author saces
- *
- */
-public class XMLUtils {
-
- public final static void writeEsc(Writer w, String s) throws
IOException {
- writeEsc(w, s, false);
- }
-
- private static void writeEsc(Writer w, String s, boolean isAttVal)
throws IOException {
- for (int i = 0; i < s.length(); i++) {
- switch (s.charAt(i)) {
- case '&':
- w.write("&");
- break;
- case '<':
- w.write("<");
- break;
- case '>':
- w.write(">");
- break;
- case '\"':
- if (isAttVal) {
- w.write(""");
- } else {
- w.write('\"');
- }
- break;
- default:
- w.write(s.charAt(i));
- }
- }
- }
-}
-