Author: batosai
Date: 2008-08-09 13:20:40 +0000 (Sat, 09 Aug 2008)
New Revision: 21684
Modified:
trunk/apps/WoT/src/plugins/WoT/Identity.java
Log:
Cleanup
Modified: trunk/apps/WoT/src/plugins/WoT/Identity.java
===================================================================
--- trunk/apps/WoT/src/plugins/WoT/Identity.java 2008-08-09 12:08:46 UTC
(rev 21683)
+++ trunk/apps/WoT/src/plugins/WoT/Identity.java 2008-08-09 13:20:40 UTC
(rev 21684)
@@ -5,19 +5,10 @@
*/
package plugins.WoT;
-import java.io.InputStream;
import java.util.Date;
-import javax.xml.parsers.SAXParser;
-import javax.xml.parsers.SAXParserFactory;
-
-import org.xml.sax.helpers.DefaultHandler;
-import org.xml.sax.Attributes;
-import org.xml.sax.SAXException;
-
import com.db4o.ObjectContainer;
import com.db4o.ObjectSet;
-import com.db4o.query.Query;
import freenet.keys.FreenetURI;
@@ -58,18 +49,6 @@
db.store(trust);
}
- /**
- * Parses an XML trustList file
- *
- * @param pis InputStream containing the XML trustList
- */
- public void fromXML(InputStream pis) throws Exception {
-
- SAXParserFactory factory = SAXParserFactory.newInstance();
- SAXParser saxParser = factory.newSAXParser();
- saxParser.parse(pis,new IdentityParser());
- }
-
public String toString() {
return getRequestURI().toString();
}
@@ -122,20 +101,4 @@
public void setPublishTrustList(boolean publishTrustList) {
this.publishTrustList = publishTrustList;
}
-
- public class IdentityParser extends DefaultHandler {
-
- public void startElement(String nameSpaceURI, String localName,
String rawName, Attributes attrs) throws SAXException {
- if (rawName == null) {
- rawName = localName;
- }
-
- if(rawName.equals("publishTrustList")) {
- publishTrustList =
Boolean.valueOf(attrs.getValue(0));
- }
- if(rawName.equals("trust")) {
- // TODO Now, this is the WoT's job to handle
new/updated trust relationships, let's work on it !
- }
- }
- }
}