[jsword-svn] r1033 - in trunk/jsword-limbo: .settings src/main/java/org/crosswire/bibledesktop/passage src/main/java/org/crosswire/bibledesktop/reference src/main/java/org/crosswire/common/io src/main/java/org/crosswire/common/net src/main/java/org/crosswire/common/swing src/main/java/org/crosswire/jsword/book/jdbc src/main/java/org/crosswire/jsword/book/raw src/main/java/org/crosswire/jsword/book/ser

dmsmith at crosswire.org dmsmith at crosswire.org
Sun Mar 5 05:27:33 MST 2006


Author: dmsmith
Date: 2006-03-05 05:26:56 -0700 (Sun, 05 Mar 2006)
New Revision: 1033

Modified:
   trunk/jsword-limbo/.settings/org.eclipse.jdt.core.prefs
   trunk/jsword-limbo/src/main/java/org/crosswire/bibledesktop/passage/PassageListCellRenderer.java
   trunk/jsword-limbo/src/main/java/org/crosswire/bibledesktop/reference/ReferenceRootTreeNode.java
   trunk/jsword-limbo/src/main/java/org/crosswire/bibledesktop/reference/ReferencedPane.java
   trunk/jsword-limbo/src/main/java/org/crosswire/common/io/StackedInputStream.java
   trunk/jsword-limbo/src/main/java/org/crosswire/common/io/StackedReader.java
   trunk/jsword-limbo/src/main/java/org/crosswire/common/io/TeeOutputStream.java
   trunk/jsword-limbo/src/main/java/org/crosswire/common/io/TeeWriter.java
   trunk/jsword-limbo/src/main/java/org/crosswire/common/net/WebBrowser.java
   trunk/jsword-limbo/src/main/java/org/crosswire/common/net/WebPage.java
   trunk/jsword-limbo/src/main/java/org/crosswire/common/swing/BeanPanel.java
   trunk/jsword-limbo/src/main/java/org/crosswire/common/swing/DebugContainerListener.java
   trunk/jsword-limbo/src/main/java/org/crosswire/common/swing/ExceptionShelf.java
   trunk/jsword-limbo/src/main/java/org/crosswire/common/swing/MenuUtil.java
   trunk/jsword-limbo/src/main/java/org/crosswire/jsword/book/jdbc/JDBCBook.java
   trunk/jsword-limbo/src/main/java/org/crosswire/jsword/book/jdbc/JDBCBookDriver.java
   trunk/jsword-limbo/src/main/java/org/crosswire/jsword/book/raw/RawBook.java
   trunk/jsword-limbo/src/main/java/org/crosswire/jsword/book/raw/RawBookDriver.java
   trunk/jsword-limbo/src/main/java/org/crosswire/jsword/book/ser/SerBook.java
   trunk/jsword-limbo/src/main/java/org/crosswire/jsword/book/ser/SerBookDriver.java
Log:
Partially updated to Java 5

Modified: trunk/jsword-limbo/.settings/org.eclipse.jdt.core.prefs
===================================================================
--- trunk/jsword-limbo/.settings/org.eclipse.jdt.core.prefs	2006-03-05 12:11:48 UTC (rev 1032)
+++ trunk/jsword-limbo/.settings/org.eclipse.jdt.core.prefs	2006-03-05 12:26:56 UTC (rev 1033)
@@ -1,4 +1,4 @@
-#Thu Mar 02 07:29:07 EST 2006
+#Sun Mar 05 07:35:42 EST 2006
 eclipse.preferences.version=1
 org.eclipse.jdt.core.builder.cleanOutputFolder=clean
 org.eclipse.jdt.core.builder.duplicateResourceTask=warning

Modified: trunk/jsword-limbo/src/main/java/org/crosswire/bibledesktop/passage/PassageListCellRenderer.java
===================================================================
--- trunk/jsword-limbo/src/main/java/org/crosswire/bibledesktop/passage/PassageListCellRenderer.java	2006-03-05 12:11:48 UTC (rev 1032)
+++ trunk/jsword-limbo/src/main/java/org/crosswire/bibledesktop/passage/PassageListCellRenderer.java	2006-03-05 12:26:56 UTC (rev 1033)
@@ -84,7 +84,7 @@
             try
             {
                 VerseRange range = (VerseRange) value;
-                String text = (String) hash.get(range);
+                String text = hash.get(range);
 
                 if (text == null)
                 {
@@ -132,7 +132,7 @@
     /**
      * A cache of Bible texts
      */
-    private Map hash = new HashMap();
+    private Map<VerseRange, String> hash = new HashMap<VerseRange, String>();
 
     /**
      * Serialization ID

Modified: trunk/jsword-limbo/src/main/java/org/crosswire/bibledesktop/reference/ReferenceRootTreeNode.java
===================================================================
--- trunk/jsword-limbo/src/main/java/org/crosswire/bibledesktop/reference/ReferenceRootTreeNode.java	2006-03-05 12:11:48 UTC (rev 1032)
+++ trunk/jsword-limbo/src/main/java/org/crosswire/bibledesktop/reference/ReferenceRootTreeNode.java	2006-03-05 12:26:56 UTC (rev 1033)
@@ -133,7 +133,7 @@
      */
     public TreeNode getChildAt(int childIndex)
     {
-        Book book = (Book) books.get(childIndex);
+        Book book = books.get(childIndex);
         return new ReferenceBookTreeNode(model, this, book);
     }
 
@@ -150,7 +150,7 @@
     /**
      * The current list of books
      */
-    protected List books = new ArrayList();
+    protected List<Book> books = new ArrayList<Book>();
 
     /**
      * the filter that we apply to books before we display them

Modified: trunk/jsword-limbo/src/main/java/org/crosswire/bibledesktop/reference/ReferencedPane.java
===================================================================
--- trunk/jsword-limbo/src/main/java/org/crosswire/bibledesktop/reference/ReferencedPane.java	2006-03-05 12:11:48 UTC (rev 1032)
+++ trunk/jsword-limbo/src/main/java/org/crosswire/bibledesktop/reference/ReferencedPane.java	2006-03-05 12:26:56 UTC (rev 1033)
@@ -217,7 +217,7 @@
             Key key = book.getKey(data);
             if (key != null)
             {
-                List lpath = new ArrayList();
+                List<Key> lpath = new ArrayList<Key>();
                 while (true)
                 {
                     lpath.add(0, key);
@@ -228,7 +228,7 @@
                         break;
                     }
                 }
-                Key[] keys = (Key[]) lpath.toArray(new Key[lpath.size()]);
+                Key[] keys = lpath.toArray(new Key[lpath.size()]);
 
                 TreePath path = new TreePath(keys);
                 treEntries.setSelectionPath(path);

Modified: trunk/jsword-limbo/src/main/java/org/crosswire/common/io/StackedInputStream.java
===================================================================
--- trunk/jsword-limbo/src/main/java/org/crosswire/common/io/StackedInputStream.java	2006-03-05 12:11:48 UTC (rev 1032)
+++ trunk/jsword-limbo/src/main/java/org/crosswire/common/io/StackedInputStream.java	2006-03-05 12:26:56 UTC (rev 1033)
@@ -52,7 +52,7 @@
         else
         {
             dead = current;
-            current = (InputStream) list.lastElement();
+            current = list.lastElement();
             list.removeElement(current);
         }
 
@@ -99,7 +99,7 @@
         {
             try
             {
-                InputStream in = (InputStream) list.elementAt(i);
+                InputStream in = list.elementAt(i);
                 in.close();
             }
             catch (Exception ex)
@@ -141,14 +141,14 @@
 
         for (int i=list.size()-1; i>=0; i--)
         {
-            InputStream in = (InputStream) list.elementAt(i);
+            InputStream in = list.elementAt(i);
             retcode += "Next: " + in.toString() + NEWLINE; //$NON-NLS-1$
         }
 
         return retcode;
     }
 
-    private Vector list = new Vector();
+    private Vector<InputStream> list = new Vector<InputStream>();
     private InputStream current;
 
     /** The log stream */

Modified: trunk/jsword-limbo/src/main/java/org/crosswire/common/io/StackedReader.java
===================================================================
--- trunk/jsword-limbo/src/main/java/org/crosswire/common/io/StackedReader.java	2006-03-05 12:11:48 UTC (rev 1032)
+++ trunk/jsword-limbo/src/main/java/org/crosswire/common/io/StackedReader.java	2006-03-05 12:26:56 UTC (rev 1033)
@@ -51,7 +51,7 @@
         else
         {
             dead = current;
-            current = (Reader) list.lastElement();
+            current = list.lastElement();
             list.removeElement(current);
         }
 
@@ -119,7 +119,7 @@
         {
             try
             {
-                Reader in = (Reader) list.elementAt(i);
+                Reader in = list.elementAt(i);
                 in.close();
             }
             catch (Exception ex)
@@ -161,14 +161,14 @@
 
         for (int i=list.size()-1; i>=0; i--)
         {
-            Reader in = (Reader) list.elementAt(i);
+            Reader in = list.elementAt(i);
             retcode += "Next: " + in.toString() + NEWLINE; //$NON-NLS-1$
         }
 
         return retcode;
     }
 
-    private Vector list = new Vector();
+    private Vector<Reader> list = new Vector<Reader>();
     private Reader current;
 
     /** The log stream */

Modified: trunk/jsword-limbo/src/main/java/org/crosswire/common/io/TeeOutputStream.java
===================================================================
--- trunk/jsword-limbo/src/main/java/org/crosswire/common/io/TeeOutputStream.java	2006-03-05 12:11:48 UTC (rev 1032)
+++ trunk/jsword-limbo/src/main/java/org/crosswire/common/io/TeeOutputStream.java	2006-03-05 12:26:56 UTC (rev 1033)
@@ -48,7 +48,7 @@
     {
         for (int i=0; i<list.size(); i++)
         {
-            OutputStream out = (OutputStream) list.elementAt(i);
+            OutputStream out = list.elementAt(i);
             out.write(b);
         }
     }
@@ -68,7 +68,7 @@
         {
             try
             {
-                OutputStream out = (OutputStream) list.elementAt(i);
+                OutputStream out = list.elementAt(i);
                 out.close();
             }
             catch (Exception ex)
@@ -105,14 +105,14 @@
 
         for (int i=list.size()-1; i>=0; i--)
         {
-            OutputStream out = (OutputStream) list.elementAt(i);
+            OutputStream out = list.elementAt(i);
             retcode += "Stream" + i + ": " + out.toString() + NEWLINE; //$NON-NLS-1$ //$NON-NLS-2$
         }
 
         return retcode;
     }
 
-    private Vector list = new Vector();
+    private Vector<OutputStream> list = new Vector<OutputStream>();
 
     /** The log stream */
     protected static Logger log = Logger.getLogger(TeeOutputStream.class);

Modified: trunk/jsword-limbo/src/main/java/org/crosswire/common/io/TeeWriter.java
===================================================================
--- trunk/jsword-limbo/src/main/java/org/crosswire/common/io/TeeWriter.java	2006-03-05 12:11:48 UTC (rev 1032)
+++ trunk/jsword-limbo/src/main/java/org/crosswire/common/io/TeeWriter.java	2006-03-05 12:26:56 UTC (rev 1033)
@@ -47,7 +47,7 @@
     {
         for (int i=0; i<list.size(); i++)
         {
-            Writer out = (Writer) list.elementAt(i);
+            Writer out = list.elementAt(i);
             out.write(cbuf, off, len);
         }
     }
@@ -61,7 +61,7 @@
     {
         for (int i=0; i<list.size(); i++)
         {
-            Writer out = (Writer) list.elementAt(i);
+            Writer out = list.elementAt(i);
             out.write(b);
         }
     }
@@ -74,7 +74,7 @@
     {
         for (int i=0; i<list.size(); i++)
         {
-            Writer out = (Writer) list.elementAt(i);
+            Writer out = list.elementAt(i);
             out.flush();
         }
     }
@@ -94,7 +94,7 @@
         {
             try
             {
-                Writer out = (Writer) list.elementAt(i);
+                Writer out = list.elementAt(i);
                 out.close();
             }
             catch (Exception ex)
@@ -131,14 +131,14 @@
 
         for (int i=list.size()-1; i>=0; i--)
         {
-            Writer out = (Writer) list.elementAt(i);
+            Writer out = list.elementAt(i);
             retcode += "Stream" + i + ": " + out.toString() + NEWLINE; //$NON-NLS-1$ //$NON-NLS-2$
         }
 
         return retcode;
     }
 
-    private Vector list = new Vector();
+    private Vector<Writer> list = new Vector<Writer>();
 
     /** The log stream */
     protected static Logger log = Logger.getLogger(TeeWriter.class);

Modified: trunk/jsword-limbo/src/main/java/org/crosswire/common/net/WebBrowser.java
===================================================================
--- trunk/jsword-limbo/src/main/java/org/crosswire/common/net/WebBrowser.java	2006-03-05 12:11:48 UTC (rev 1032)
+++ trunk/jsword-limbo/src/main/java/org/crosswire/common/net/WebBrowser.java	2006-03-05 12:26:56 UTC (rev 1033)
@@ -153,10 +153,10 @@
     }
 
     /** The set of additional headers */
-    private Vector headers = new Vector();
+    private Vector<Header> headers = new Vector<Header>();
 
     /** The set of cookies */
-    private Vector cookies = new Vector();
+    private Vector<Cookie> cookies = new Vector<Cookie>();
 
     /** The special cookie header */
     private Header cook_head = null;

Modified: trunk/jsword-limbo/src/main/java/org/crosswire/common/net/WebPage.java
===================================================================
--- trunk/jsword-limbo/src/main/java/org/crosswire/common/net/WebPage.java	2006-03-05 12:11:48 UTC (rev 1032)
+++ trunk/jsword-limbo/src/main/java/org/crosswire/common/net/WebPage.java	2006-03-05 12:26:56 UTC (rev 1033)
@@ -233,10 +233,10 @@
     public static int mode = 1;
 
     /** The page headers */
-    private Vector headers = new Vector();
+    private Vector<Header> headers = new Vector<Header>();
 
     /** The new cookies delivered with this page */
-    private Vector cookies = new Vector();
+    private Vector<Cookie> cookies = new Vector<Cookie>();
 
     /** The page source */
     private String data;

Modified: trunk/jsword-limbo/src/main/java/org/crosswire/common/swing/BeanPanel.java
===================================================================
--- trunk/jsword-limbo/src/main/java/org/crosswire/common/swing/BeanPanel.java	2006-03-05 12:11:48 UTC (rev 1032)
+++ trunk/jsword-limbo/src/main/java/org/crosswire/common/swing/BeanPanel.java	2006-03-05 12:26:56 UTC (rev 1033)
@@ -160,7 +160,7 @@
     /**
      * A list of the current editors
      */
-    private List editors = new ArrayList();
+    private List<JTextField> editors = new ArrayList<JTextField>();
 
     /**
      * The log stream

Modified: trunk/jsword-limbo/src/main/java/org/crosswire/common/swing/DebugContainerListener.java
===================================================================
--- trunk/jsword-limbo/src/main/java/org/crosswire/common/swing/DebugContainerListener.java	2006-03-05 12:11:48 UTC (rev 1032)
+++ trunk/jsword-limbo/src/main/java/org/crosswire/common/swing/DebugContainerListener.java	2006-03-05 12:26:56 UTC (rev 1033)
@@ -136,7 +136,7 @@
         map.remove(child);
     }
 
-    private Map map = new HashMap();
+    private Map<Component, Component> map = new HashMap<Component, Component>();
 
     /**
      * The log stream

Modified: trunk/jsword-limbo/src/main/java/org/crosswire/common/swing/ExceptionShelf.java
===================================================================
--- trunk/jsword-limbo/src/main/java/org/crosswire/common/swing/ExceptionShelf.java	2006-03-05 12:11:48 UTC (rev 1032)
+++ trunk/jsword-limbo/src/main/java/org/crosswire/common/swing/ExceptionShelf.java	2006-03-05 12:26:56 UTC (rev 1033)
@@ -23,6 +23,7 @@
 
 import java.awt.BorderLayout;
 import java.awt.CardLayout;
+import java.awt.Component;
 import java.awt.Font;
 import java.awt.Insets;
 import java.awt.event.ActionEvent;
@@ -202,7 +203,7 @@
         }
         else
         {
-            ExceptionPane.showExceptionDialog(this, (Throwable) exceptions.get(current));
+            ExceptionPane.showExceptionDialog(this, exceptions.get(current));
         }
     }
 
@@ -211,7 +212,7 @@
      */
     protected void remover()
     {
-        removeException((Throwable) exceptions.get(current));
+        removeException(exceptions.get(current));
     }
 
     /**
@@ -319,7 +320,7 @@
     /**
      * The set of panels reporting on the errors
      */
-    private List panels = new ArrayList();
+    private List<Component> panels = new ArrayList<Component>();
 
     /**
      * The shelf scroller
@@ -354,7 +355,7 @@
     /**
      * The set of known errors
      */
-    private List exceptions = new ArrayList();
+    private List<Throwable> exceptions = new ArrayList<Throwable>();
 
     /**
      * You must call setHelpDeskListener() in order to start displaying
@@ -392,7 +393,7 @@
     /**
      * All the ExceptionShelves that we know about
      */
-    protected static final List SHELVES = new ArrayList();
+    protected static final List<Component> SHELVES = new ArrayList<Component>();
 
     /**
      * The font for the remove button

Modified: trunk/jsword-limbo/src/main/java/org/crosswire/common/swing/MenuUtil.java
===================================================================
--- trunk/jsword-limbo/src/main/java/org/crosswire/common/swing/MenuUtil.java	2006-03-05 12:11:48 UTC (rev 1032)
+++ trunk/jsword-limbo/src/main/java/org/crosswire/common/swing/MenuUtil.java	2006-03-05 12:26:56 UTC (rev 1033)
@@ -67,7 +67,7 @@
     {
         for (int i=0; i<actions.length; i++)
         {
-            commands.put(actions[i].getValue(Action.NAME), actions[i]);
+            commands.put(actions[i].getValue(Action.NAME).toString(), actions[i]);
         }
     }
 
@@ -148,7 +148,7 @@
      */
     protected static Action getAction(String cmd)
     {
-        return (Action) commands.get(cmd);
+        return commands.get(cmd);
     }
 
     /**
@@ -160,7 +160,7 @@
      */
     protected JMenuItem getMenuItem(String cmd)
     {
-        return (JMenuItem) menuitems.get(cmd);
+        return menuitems.get(cmd);
     }
 
     /**
@@ -335,7 +335,7 @@
     /*
      * Data
      */
-    private static Hashtable menuitems = new Hashtable();
-    private static Hashtable commands = new Hashtable();
+    private static Hashtable<String, JMenuItem> menuitems = new Hashtable<String, JMenuItem>();
+    private static Hashtable<String, Action> commands = new Hashtable<String, Action>();
     private static ResourceBundle resource = null;
 }

Modified: trunk/jsword-limbo/src/main/java/org/crosswire/jsword/book/jdbc/JDBCBook.java
===================================================================
--- trunk/jsword-limbo/src/main/java/org/crosswire/jsword/book/jdbc/JDBCBook.java	2006-03-05 12:11:48 UTC (rev 1032)
+++ trunk/jsword-limbo/src/main/java/org/crosswire/jsword/book/jdbc/JDBCBook.java	2006-03-05 12:26:56 UTC (rev 1033)
@@ -32,7 +32,6 @@
 import java.util.Iterator;
 import java.util.Map;
 import java.util.NoSuchElementException;
-import java.util.Properties;
 
 import org.crosswire.common.util.Logger;
 import org.crosswire.jsword.book.BookDriver;
@@ -59,7 +58,7 @@
     /**
      * Simple ctor
      */
-    public JDBCBook(BookDriver driver, Properties prop) throws BookException
+    public JDBCBook(BookDriver driver, Map<String, String> prop) throws BookException
     {
         BookMetaData bmd = new DefaultBookMetaData(driver, this, prop);
         setBookMetaData(bmd);

Modified: trunk/jsword-limbo/src/main/java/org/crosswire/jsword/book/jdbc/JDBCBookDriver.java
===================================================================
--- trunk/jsword-limbo/src/main/java/org/crosswire/jsword/book/jdbc/JDBCBookDriver.java	2006-03-05 12:11:48 UTC (rev 1032)
+++ trunk/jsword-limbo/src/main/java/org/crosswire/jsword/book/jdbc/JDBCBookDriver.java	2006-03-05 12:26:56 UTC (rev 1033)
@@ -24,8 +24,8 @@
 import java.net.URL;
 import java.util.ArrayList;
 import java.util.List;
-import java.util.Properties;
 
+import org.crosswire.common.util.CollectionUtil;
 import org.crosswire.common.util.Logger;
 import org.crosswire.common.util.NetUtil;
 import org.crosswire.common.util.Reporter;
@@ -74,11 +74,8 @@
                 URL url = NetUtil.lengthenURL(dir, names[i]);
                 URL propUrl = NetUtil.lengthenURL(url, "bible.properties"); //$NON-NLS-1$
 
-                Properties prop = new Properties();
-                prop.load(propUrl.openStream());
+                Book book = new JDBCBook(this, CollectionUtil.properties2Map(propUrl));
 
-                Book book = new JDBCBook(this, prop);
-
                 books.add(book);
             }
 

Modified: trunk/jsword-limbo/src/main/java/org/crosswire/jsword/book/raw/RawBook.java
===================================================================
--- trunk/jsword-limbo/src/main/java/org/crosswire/jsword/book/raw/RawBook.java	2006-03-05 12:11:48 UTC (rev 1032)
+++ trunk/jsword-limbo/src/main/java/org/crosswire/jsword/book/raw/RawBook.java	2006-03-05 12:26:56 UTC (rev 1033)
@@ -25,7 +25,7 @@
 import java.net.URL;
 import java.util.Collection;
 import java.util.Iterator;
-import java.util.Properties;
+import java.util.Map;
 
 import org.crosswire.common.util.Logger;
 import org.crosswire.common.util.Reporter;
@@ -213,7 +213,7 @@
     /**
      * Simple ctor
      */
-    public RawBook(BookDriver driver, Properties prop, URL url)
+    public RawBook(BookDriver driver, Map<String, String> prop, URL url)
     {
         BookMetaData bmd = new DefaultBookMetaData(driver, this, prop);
         setBookMetaData(bmd);

Modified: trunk/jsword-limbo/src/main/java/org/crosswire/jsword/book/raw/RawBookDriver.java
===================================================================
--- trunk/jsword-limbo/src/main/java/org/crosswire/jsword/book/raw/RawBookDriver.java	2006-03-05 12:11:48 UTC (rev 1032)
+++ trunk/jsword-limbo/src/main/java/org/crosswire/jsword/book/raw/RawBookDriver.java	2006-03-05 12:26:56 UTC (rev 1033)
@@ -24,8 +24,8 @@
 import java.net.URL;
 import java.util.ArrayList;
 import java.util.List;
-import java.util.Properties;
 
+import org.crosswire.common.util.CollectionUtil;
 import org.crosswire.common.util.Logger;
 import org.crosswire.common.util.NetUtil;
 import org.crosswire.common.util.Reporter;
@@ -72,13 +72,10 @@
             for (int i=0; i<names.length; i++)
             {
                 URL url = NetUtil.lengthenURL(dir, names[i]);
-                URL prop_url = NetUtil.lengthenURL(url, RawConstants.FILE_BIBLE_PROPERTIES);
+                URL propUrl = NetUtil.lengthenURL(url, RawConstants.FILE_BIBLE_PROPERTIES);
 
-                Properties prop = new Properties();
-                prop.load(prop_url.openStream());
+                Book book = new RawBook(this, CollectionUtil.properties2Map(propUrl), url);
 
-                Book book = new RawBook(this, prop, url);
-
                 books.add(book);
             }
 

Modified: trunk/jsword-limbo/src/main/java/org/crosswire/jsword/book/ser/SerBook.java
===================================================================
--- trunk/jsword-limbo/src/main/java/org/crosswire/jsword/book/ser/SerBook.java	2006-03-05 12:11:48 UTC (rev 1032)
+++ trunk/jsword-limbo/src/main/java/org/crosswire/jsword/book/ser/SerBook.java	2006-03-05 12:26:56 UTC (rev 1033)
@@ -22,7 +22,7 @@
 package org.crosswire.jsword.book.ser;
 
 import java.net.URL;
-import java.util.Properties;
+import java.util.Map;
 
 import org.crosswire.jsword.book.BookDriver;
 import org.crosswire.jsword.book.BookException;
@@ -148,7 +148,7 @@
     /**
      * Simple ctor
      */
-    public SerBook(BookDriver driver, Properties prop, URL url) throws BookException
+    public SerBook(BookDriver driver, Map<String, String> prop, URL url) throws BookException
     {
         BookMetaData bmd = new DefaultBookMetaData(driver, this, prop);
         setBookMetaData(bmd);

Modified: trunk/jsword-limbo/src/main/java/org/crosswire/jsword/book/ser/SerBookDriver.java
===================================================================
--- trunk/jsword-limbo/src/main/java/org/crosswire/jsword/book/ser/SerBookDriver.java	2006-03-05 12:11:48 UTC (rev 1032)
+++ trunk/jsword-limbo/src/main/java/org/crosswire/jsword/book/ser/SerBookDriver.java	2006-03-05 12:26:56 UTC (rev 1033)
@@ -24,14 +24,15 @@
 import java.net.URL;
 import java.util.ArrayList;
 import java.util.List;
-import java.util.Properties;
 
+import org.crosswire.common.util.CollectionUtil;
 import org.crosswire.common.util.Logger;
 import org.crosswire.common.util.NetUtil;
 import org.crosswire.common.util.Reporter;
 import org.crosswire.jsword.book.Book;
 import org.crosswire.jsword.book.basic.AbstractBookDriver;
 import org.crosswire.jsword.book.basic.BookRoot;
+import org.crosswire.jsword.book.raw.RawBook;
 
 /**
  * This represents all of the SerBibles.
@@ -72,13 +73,10 @@
             for (int i=0; i<names.length; i++)
             {
                 URL url = NetUtil.lengthenURL(dir, names[i]);
-                URL prop_url = NetUtil.lengthenURL(url, "bible.properties"); //$NON-NLS-1$
+                URL propUrl = NetUtil.lengthenURL(url, "bible.properties"); //$NON-NLS-1$
 
-                Properties prop = new Properties();
-                prop.load(prop_url.openStream());
+                Book book = new RawBook(this, CollectionUtil.properties2Map(propUrl), url);
 
-                Book book = new SerBook(this, prop, url);
-
                 books.add(book);
             }
 



More information about the jsword-svn mailing list