[sword-svn] r70 - in trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS: . Parse Translate

mgruner at crosswire.org mgruner at crosswire.org
Sun Jul 9 04:23:51 MST 2006


Author: mgruner
Date: 2006-07-09 04:23:32 -0700 (Sun, 09 Jul 2006)
New Revision: 70

Removed:
   trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Parse/Tokenizer.java
Modified:
   trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Parse/Books.java
   trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Parse/Chapters.java
   trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Parse/Markers.java
   trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Parse/Parser.java
   trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Parse/Verses.java
   trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Parse/Words.java
   trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Translate/BookName.java
   trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Translate/MC.java
   trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Translate/MCO.java
   trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Translate/Note.java
   trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Translate/Translate.java
   trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Translate/UnicodeChar.java
   trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Translate/WKQ.java
   trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/WLC2OSIS.java
Log:
more work

Modified: trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Parse/Books.java
===================================================================
--- trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Parse/Books.java	2006-07-07 20:27:39 UTC (rev 69)
+++ trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Parse/Books.java	2006-07-09 11:23:32 UTC (rev 70)
@@ -44,11 +44,11 @@
     P.VerseNumber = 0 ;
     P.WordNumber = 0 ;
 //     A.wlc.openTag("tanach", 0) ;
-    A.wlc.openTag("div type=\"book\" osisID=\"" + BookObject.abbrev + "\"", 1) ;
+    A.writer.openTag("div type=\"book\" osisID=\"" + BookObject.abbrev + "\"", 1) ;
 
-/*    A.wlc.writeAttributedString("title", 2, "type=\"section\" subType=\"x-Section\" subtype=\"x-preverse\"",
+/*    A.writer.writeAttributedString("title", 2, "type=\"section\" subType=\"x-Section\" subtype=\"x-preverse\"",
       BookObject.hebrewname);
-    A.wlc.writeAttributedString("title", 2, "type=\"main\" ",    	BookObject.hebrewname);*/
+    A.writer.writeAttributedString("title", 2, "type=\"main\" ",    	BookObject.hebrewname);*/
       
     
     }
@@ -62,7 +62,7 @@
         P.BookChapterCount = P.ChapterNumber ;
         P.TanachChapterCount = P.TanachChapterCount + P.ChapterNumber ;
         
-        A.wlc.closeTag("div", 1) ;
+        A.writer.closeTag("div", 1) ;
         System.out.println( BookObject.name + " has been written." ) ;
         }
     }

Modified: trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Parse/Chapters.java
===================================================================
--- trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Parse/Chapters.java	2006-07-07 20:27:39 UTC (rev 69)
+++ trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Parse/Chapters.java	2006-07-09 11:23:32 UTC (rev 70)
@@ -26,7 +26,7 @@
     P.VerseNumber = 0 ;
     P.WordNumber = 0 ;
     String num = new Integer(P.ChapterNumber).toString();
-    A.wlc.openTag("chapter osisID=\"" + P.BookAbbrev + "." + num + "\"", 2) ;
+    A.writer.openTag("chapter osisID=\"" + P.BookAbbrev + "." + num + "\"", 2) ;
     }
 //------------------------------------------------------------------------------
 
@@ -38,7 +38,7 @@
         P.BookVerseCount = P.BookVerseCount + P.VerseNumber ;
         P.TanachVerseCount = P.TanachVerseCount + P.VerseNumber ;
     
-    	A.wlc.closeTag("chapter", 2) ;
+    	A.writer.closeTag("chapter", 2) ;
 	
         }
     }

Modified: trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Parse/Markers.java
===================================================================
--- trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Parse/Markers.java	2006-07-07 20:27:39 UTC (rev 69)
+++ trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Parse/Markers.java	2006-07-09 11:23:32 UTC (rev 70)
@@ -3,7 +3,6 @@
 import WLC2OSIS.* ;
 import WLC2OSIS.Translate.H ;
 
-import java.io.* ;
 //==============================================================================
 /**
  *  <b>Processes markers.</b> 
@@ -30,7 +29,7 @@
 public void samek(){ //parasah setumah, closed paragraph == small space in line
     testMaqafWord() ;
 //     A.wlc.writeMarker("samekh", 4) ;
-    A.wlc.appendText("   " + H.samekh + "   ") ;
+    A.writer.appendText("   " + H.samekh + "   ") ;
     P.MarkerWritten = true ;
     }
 //------------------------------------------------------------------------------
@@ -38,8 +37,8 @@
 // Pe
 public void pe(){ // parasah petuhah, open paragraph == new line
     testMaqafWord() ;
-//     A.wlc.writeMarker("pe", 4) ;
-    A.wlc.appendText(" " + H.pe + " " + "<p/>") ;
+//     A.writer.writeMarker("pe", 4) ;
+    A.writer.appendText(" " + H.pe + " " + "<p/>") ;
     P.MarkerWritten = true ;
     }
 //------------------------------------------------------------------------------

Modified: trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Parse/Parser.java
===================================================================
--- trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Parse/Parser.java	2006-07-07 20:27:39 UTC (rev 69)
+++ trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Parse/Parser.java	2006-07-09 11:23:32 UTC (rev 70)
@@ -3,7 +3,6 @@
 import java.io.*;
 import WLC2OSIS.* ;
 import WLC2OSIS.Translate.* ;
-import WLC2OSIS.Utilities.* ;
 //==============================================================================
 /**
  *  <b>Parser dispatches tokens to  Books, Chapters, Markers, Tanach,
@@ -59,7 +58,7 @@
 BufferedReader file;
 
 //-----------------------------------------------------------------------------
-public Parser(WLC2OSIS A) {
+public Parser(WLC2OSIS A, boolean wlc_only) {
     this.A = A ;
 
     T = new Translate(A, this) ;
@@ -82,7 +81,6 @@
 
 public void parse(){
     String s ;
-    boolean PreviousEOL = true ;
     System.out.println("\n") ;
     
    	try{
@@ -92,7 +90,7 @@
 		System.out.println("File not found: " + e) ;
     }
 
-    java.util.regex.Pattern pattern = java.util.regex.Pattern.compile("(\\w\\w)(\\d+):(\\d+),(\\d+)\\.(\\d+)\\S*\\s(\\S+)\\s(\\S+)(?:@|%)(\\S+)");
+    java.util.regex.Pattern pattern = java.util.regex.Pattern.compile("(\\w\\w)(\\d+):(\\d+),(\\d+)\\.(\\d+)(\\]\\S)?\\s(\\S+)\\s(\\S+)(?:@|%)(\\S+)");
      
     while ( true ){
     	s="";
@@ -103,28 +101,38 @@
 			System.out.println("Read error: " + e) ;
 			break;
         }
+        if ( s == null ){
+        	try{
+	        	file.close();
+	        }
+	        catch (IOException e) {
+				System.out.println("Error closing file: " + e) ;
+	        }
+        	break;
+        }
     
         if ( s.startsWith(">") ){ //ignore this line
         	continue;
         }
-        
+
 		java.util.regex.Matcher m = pattern.matcher( s );
 		if (!m.matches()){
-			System.out.println("No match!");
+			System.out.println("No match found: " +s);
 			System.exit(1);
 		}
 		
 // Parse the identifier
-            String BookCode = m.group(1);
-            int Chapter = Integer.parseInt( m.group(2) );
-            int Verse   = Integer.parseInt( m.group(3) );
-            int wordNumber	= Integer.parseInt( m.group(4) );
-            int subWordNumber = Integer.parseInt( m.group(5) );
-            String expression = m.group(6);
-            String lemma	= m.group(7);
-            String grammar  = m.group(8);
+		String BookCode = m.group(1);
+		int Chapter = Integer.parseInt( m.group(2) );
+		int Verse   = Integer.parseInt( m.group(3) );
+		int wordNumber	= Integer.parseInt( m.group(4) );
+		int subWordNumber = Integer.parseInt( m.group(5) );
+		String note = m.group(6);
+		String expression = m.group(7);
+		String lemma	= m.group(8);
+		String grammar  = m.group(9);
             
-        System.out.println(BookCode + " " + Chapter + " " + Verse + " " + wordNumber + " " + subWordNumber + " " +expression+" "+lemma+" "+grammar);
+      //  System.out.println(BookCode + " " + Chapter + " " + Verse + " " + wordNumber + " " + subWordNumber + " " +expression+" "+lemma+" "+grammar+ " Note: "+note);
 /*
 // Change in Book, start a book.
             if(BookCode.compareTo(LastBookCode) != 0){
@@ -199,14 +207,5 @@
    }
 //----------------------------------------------------------------------------
 
-// Prints a verse identification.
 
-/*public void printPosition(){
-    System.out.print(" at " + Book + " " + A.F.i(ChapterNumber,3) + ":" 
-        + A.F.i(VerseNumber,2) 
-            + "." + A.F.i(WordNumber,2) + "\n") ;
-    }*/
-//------------------------------------------------------------------------------
 }
-//==============================================================================
-//==============================================================================

Deleted: trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Parse/Tokenizer.java
===================================================================
--- trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Parse/Tokenizer.java	2006-07-07 20:27:39 UTC (rev 69)
+++ trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Parse/Tokenizer.java	2006-07-09 11:23:32 UTC (rev 70)
@@ -1,92 +0,0 @@
-package WLC2OSIS.Parse ;
-
-import WLC2OSIS.* ;
-
-import java.io.* ;
-import javax.swing.* ;
-import java.awt.* ;
-//==============================================================================
-/**
- *  <b>Tokenizer based on standard Java tokenizer, special to WLC.</b>
- *
- *  Special to WLC.
- */
-//==============================================================================
-public class Tokenizer{
-
-public final String EOF = "***EOF***" ;
-public final String EOL = "***EOL***" ;
-WLC2OSIS A ;
-//CharArrayReader car ;
-StreamTokenizer st ;
-
-//-----------------------------------------------------------------------------
-
-public Tokenizer(WLC2OSIS A ) {
-    this.A = A ;
-
-// Set up the tokenizer
-
-//    car = new CharArrayReader(A.InputChars) ;    
-    try{
-    	st = new StreamTokenizer( new FileInputStream( A.InputFilename ) ) ;
-    }
-    catch (IOException e) {
-    	System.exit(0);
-    }
-    st.resetSyntax() ;
-    st.wordChars(33, 126 ) ; // All printables are word characters
-    st.ordinaryChar(63) ; // ? is a special symbol, the EOL marker.
-    st.eolIsSignificant(true) ;
-    }    
-//------------------------------------------------------------------------------
-
-// Gets the next token as a String.
-
-// EOF is indicated by a return of EOF.
-// EOL is indicated by a return of EOL.
-
-public String nextToken(){
-        int TokenType = 0 ;
-        boolean Found = false ;     // Found a word token or EOF ;
-        String Value = "" ; // The returned String.
-        do{
-            try{
-                TokenType = st.nextToken() ;
-                }
-            catch (IOException e) {
-                System.out.println("Tokenizer: IOException in tokenization: " + e) ;
-                }
-
-            if (TokenType==StreamTokenizer.TT_WORD){
-                Value = st.sval ;
-                Found = true ;
-                }
-            else if(TokenType==StreamTokenizer.TT_EOF){
-                Value = EOF ;
-                Found = true ;
-                }
-            else if(TokenType==StreamTokenizer.TT_EOL){
-                Value = EOL ;
-                Found = true ;
-                }
-            if (TokenType==63){ // EOL marker
-                Value = "?" ;
-                Found = true ;
-                }
-
-            }while(!Found) ;
-        
-        return Value ;
-        }
-//------------------------------------------------------------------------------
-
-// Does a pushBack on the StreamTokenizer, st.
-
-public void pushBack(){
-        st.pushBack() ;
-        }
-//-----------------------------------------------------------------------------
-}
-//==============================================================================
-//==============================================================================

Modified: trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Parse/Verses.java
===================================================================
--- trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Parse/Verses.java	2006-07-07 20:27:39 UTC (rev 69)
+++ trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Parse/Verses.java	2006-07-09 11:23:32 UTC (rev 70)
@@ -26,7 +26,7 @@
     
     String chapternum = new Integer(P.ChapterNumber).toString();
     String versenum =   new Integer(P.VerseNumber).toString();
-    A.wlc.openTag("verse osisID=\""+P.BookAbbrev+"."+chapternum+"."+versenum+"\"", 3) ;
+    A.writer.openTag("verse osisID=\""+P.BookAbbrev+"."+chapternum+"."+versenum+"\"", 3) ;
     }
 //------------------------------------------------------------------------------
 
@@ -34,7 +34,7 @@
 
 public void end(){
     if( P.VerseNumber != 0){
-    	A.wlc.closeTag("verse", 3) ;
+    	A.writer.closeTag("verse", 3) ;
         }
     }
 //----------------------------------------------------------------------------

Modified: trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Parse/Words.java
===================================================================
--- trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Parse/Words.java	2006-07-07 20:27:39 UTC (rev 69)
+++ trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Parse/Words.java	2006-07-09 11:23:32 UTC (rev 70)
@@ -2,7 +2,6 @@
 
 import WLC2OSIS.* ;
 import WLC2OSIS.Translate.H ;
-import WLC2OSIS.Utilities.* ;
 //==============================================================================
 /**
  *  <b>Processes words, sending them to the Translate class
@@ -99,13 +98,13 @@
        }
        
     if (Type.charAt(0) == 'w') {
-        A.wlc.appendText(A.MorphologicalSegmentStart + Out + A.MorphologicalSegmentEnd + " ") ;
+        A.writer.appendText(A.MorphologicalSegmentStart + Out + A.MorphologicalSegmentEnd + " ") ;
     }
     else if (Type.charAt(0) == 'k') {
-        A.wlc.appendText("[" + A.MorphologicalSegmentStart + Out + A.MorphologicalSegmentEnd + " " + H.kaf + "] ") ;
+        A.writer.appendText("[" + A.MorphologicalSegmentStart + Out + A.MorphologicalSegmentEnd + " " + H.kaf + "] ") ;
     }
     else if (Type.charAt(0) == 'q') {
-        A.wlc.appendText("("+A.MorphologicalSegmentStart + Out + A.MorphologicalSegmentEnd + " " + H.qof+ ") ") ;
+        A.writer.appendText("("+A.MorphologicalSegmentStart + Out + A.MorphologicalSegmentEnd + " " + H.qof+ ") ") ;
     }
     else {
         System.out.println("Warning: unknown word type!");

Modified: trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Translate/BookName.java
===================================================================
--- trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Translate/BookName.java	2006-07-07 20:27:39 UTC (rev 69)
+++ trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Translate/BookName.java	2006-07-09 11:23:32 UTC (rev 70)
@@ -1,9 +1,5 @@
 package WLC2OSIS.Translate ;
 
-import WLC2OSIS.* ;
-import WLC2OSIS.Translate.* ;
-
-import java.io.*;
 //==============================================================================
 /**
  *  <b>Object containing alternative book names, abbreviations, 

Modified: trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Translate/MC.java
===================================================================
--- trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Translate/MC.java	2006-07-07 20:27:39 UTC (rev 69)
+++ trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Translate/MC.java	2006-07-09 11:23:32 UTC (rev 70)
@@ -1,8 +1,5 @@
 package WLC2OSIS.Translate ;
 
-import WLC2OSIS.Utilities.* ;
-
-import java.io.*;
 //==============================================================================
 /**
  *  <b>MC ASCII decoding constants</b>.<p/>

Modified: trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Translate/MCO.java
===================================================================
--- trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Translate/MCO.java	2006-07-07 20:27:39 UTC (rev 69)
+++ trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Translate/MCO.java	2006-07-09 11:23:32 UTC (rev 70)
@@ -63,7 +63,6 @@
     this.Value = Value ;
     this.FinalValue = FinalValue ;
     this.Group = Group ;
-    this.Object = Object ;
     }
 //-----------------------------------------------------------------------------
 /**

Modified: trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Translate/Note.java
===================================================================
--- trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Translate/Note.java	2006-07-07 20:27:39 UTC (rev 69)
+++ trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Translate/Note.java	2006-07-09 11:23:32 UTC (rev 70)
@@ -1,7 +1,5 @@
 package WLC2OSIS.Translate ;
 
-import WLC2OSIS.Utilities.* ;
-
 import java.util.Hashtable ;
 
 //==============================================================================

Modified: trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Translate/Translate.java
===================================================================
--- trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Translate/Translate.java	2006-07-07 20:27:39 UTC (rev 69)
+++ trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Translate/Translate.java	2006-07-09 11:23:32 UTC (rev 70)
@@ -3,9 +3,7 @@
 import WLC2OSIS.* ;
 import WLC2OSIS.Parse.* ;
 import WLC2OSIS.Translate.Note ;
-import WLC2OSIS.Utilities.* ;
 
-import java.io.* ;
 import java.util.Vector ;
 //==============================================================================
 /**

Modified: trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Translate/UnicodeChar.java
===================================================================
--- trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Translate/UnicodeChar.java	2006-07-07 20:27:39 UTC (rev 69)
+++ trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Translate/UnicodeChar.java	2006-07-09 11:23:32 UTC (rev 70)
@@ -1,6 +1,5 @@
 package WLC2OSIS.Translate ;
 
-import WLC2OSIS.* ;
 import WLC2OSIS.Utilities.* ;
 //==============================================================================
 /**

Modified: trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Translate/WKQ.java
===================================================================
--- trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Translate/WKQ.java	2006-07-07 20:27:39 UTC (rev 69)
+++ trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/Translate/WKQ.java	2006-07-09 11:23:32 UTC (rev 70)
@@ -1,8 +1,6 @@
 package WLC2OSIS.Translate;
 
-import WLC2OSIS.* ;
 import WLC2OSIS.Parse.* ;
-import WLC2OSIS.Utilities.* ;
 //==============================================================================
 /**
  *  <b>Processes usual and Ketib/Qere words.</b><p>

Modified: trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/WLC2OSIS.java
===================================================================
--- trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/WLC2OSIS.java	2006-07-07 20:27:39 UTC (rev 69)
+++ trunk/modules/hebrew-wlc/WLC2OSIS/WLC2OSIS/WLC2OSIS.java	2006-07-09 11:23:32 UTC (rev 70)
@@ -1,11 +1,7 @@
 package WLC2OSIS ;
 
 import WLC2OSIS.Parse.* ;
-import WLC2OSIS.Translate.* ;
 import WLC2OSIS.Utilities.XMLWriter ;
-
-import java.io.*;
-import java.util.*;
 //=================================================================================================
 /**
 *
@@ -67,8 +63,7 @@
 //-----------------------------------------------------------------------------
 
 public Parser p ;
-public XMLWriter wlc;
-public XMLWriter morph;
+public XMLWriter writer;
 
 public WLC2OSIS( String file, String directory ){
     
@@ -81,32 +76,30 @@
         
 // Read, parse, and write the book files.
 
-    wlc = new XMLWriter(OutputDirectory, "wlc_osis") ;
-    morph = new XMLWriter(OutputDirectory, "morph_osis") ;
+    writer = new XMLWriter(OutputDirectory, "wlc_morph") ;
 
-
-    wlc.openTag("osisText osisIDWork=\"WLC\" osisRefWork=\"bible\" xml:lang=\"he\"", 0) ;
-    wlc.openTag("header", 0) ;
+    writer.openTag("osisText osisIDWork=\"writer\" osisRefWork=\"bible\" xml:lang=\"he\"", 0) ;
+    writer.openTag("header", 0) ;
     
-    wlc.openTag("work osisWork=\"WLC\"", 1) ;
+    writer.openTag("work osisWork=\"writer\"", 1) ;
     
-    wlc.writeString("title", 2, "Westminster Leningrad Codex");
-    wlc.writeAttributedString("contributor", 2, "role=\"encoder\"", "Martin Gruner");
-    wlc.writeAttributedString("type", 2, "type=\"OSIS\"", "Bible");
-    wlc.writeAttributedString("identifier", 2, "type=\"OSIS\"", "Bible.he.WLC.2004");
-    wlc.writeAttributedString("rights", 2, "type=\"x-copyright\"", 
-      "The WLC is maintained by the Westminster Hebrew Institute, Philadelphia, PA (http://whi.wts.edu/WHI)");
-    wlc.writeString("scope", 2, "Hebrew Bible, Old Testament");
-    wlc.writeString("refSystem", 2, "MT");
+    writer.writeString("title", 2, "Westminster Leningrad Codex");
+    writer.writeAttributedString("contributor", 2, "role=\"encoder\"", "Martin Gruner");
+    writer.writeAttributedString("type", 2, "type=\"OSIS\"", "Bible");
+    writer.writeAttributedString("identifier", 2, "type=\"OSIS\"", "Bible.he.writer.2004");
+    writer.writeAttributedString("rights", 2, "type=\"x-copyright\"", 
+      "The writer is maintained by the Westminster Hebrew Institute, Philadelphia, PA (http://whi.wts.edu/WHI)");
+    writer.writeString("scope", 2, "Hebrew Bible, Old Testament");
+    writer.writeString("refSystem", 2, "MT");
        
-    wlc.closeTag("work", 1);
-    wlc.closeTag("header", 0);
+    writer.closeTag("work", 1);
+    writer.closeTag("header", 0);
 
-    p = new Parser(this) ;
+    p = new Parser(this, false) ;
     p.parse() ;    
 
-    wlc.closeTag("osisText", 0);
-	wlc.close();
+    writer.closeTag("osisText", 0);
+	writer.close();
 
     done() ;
     } 
@@ -116,7 +109,7 @@
   *    Universal exit.
   */
 public void done(){
-    System.out.println("\nWLC2OSIS: Normal end.") ;
+    System.out.println("\nwriter2OSIS: Normal end.") ;
     System.exit(0) ;
     }
 }



More information about the sword-cvs mailing list