[Prime-cvs] CVS update: prime/lib

アーカイブの一覧に戻る

Hiroyuki Komatsu komat****@users*****
2004年 12月 31日 (金) 15:23:32 JST


Index: prime/lib/taiyaki.rb
diff -u prime/lib/taiyaki.rb:1.7 prime/lib/taiyaki.rb:1.8
--- prime/lib/taiyaki.rb:1.7	Thu Dec  9 21:24:16 2004
+++ prime/lib/taiyaki.rb	Fri Dec 31 15:23:32 2004
@@ -1,5 +1,5 @@
 # taiyaki.rb: Ruby Libraries by Hiroyuki Komatsu
-# $Id: taiyaki.rb,v 1.7 2004/12/09 12:24:16 komatsu Exp $
+# $Id: taiyaki.rb,v 1.8 2004/12/31 06:23:32 komatsu Exp $
 #
 # Copyright (C) 2002 Hiroyuki Komatsu <komat****@taiya*****>
 #     All rights reserved.
@@ -56,6 +56,7 @@
           'prime/prime-dict-config.rb' =>
                              'http://sourceforge.jp/projects/prime/',
           'suikyo/suikyo' => 'http://taiyaki.org/suikyo/',
+          'MeCab'         => 'http://chasen.org/~taku/software/mecab/',
   }
   begin
     Kernel::require(name)
@@ -84,7 +85,7 @@
       end
       $stderr.puts("  Sorry for your inconvenience.")
     end
-    exit()
+    raise(LoadError)
   end
 end
 
Index: prime/lib/prime.rb
diff -u prime/lib/prime.rb:1.16 prime/lib/prime.rb:1.17
--- prime/lib/prime.rb:1.16	Thu Dec 16 23:44:09 2004
+++ prime/lib/prime.rb	Fri Dec 31 15:23:32 2004
@@ -1,5 +1,5 @@
 # prime/prime.rb
-# $Id: prime.rb,v 1.16 2004/12/16 14:44:09 komatsu Exp $
+# $Id: prime.rb,v 1.17 2004/12/31 06:23:32 komatsu Exp $
 #
 # Copyright (C) 2002, 2003, 2004 Hiroyuki Komatsu <komat****@taiya*****>
 #     All rights reserved.
@@ -380,6 +380,8 @@
   end
 
   public
+  ## This returns an avairable prefix string for the literal.
+  ## ex). get_prefix("This", "is") => " "
   def Prime::get_prefix (context, literal)
     if PRIME_ENV['style_auto_space'] and context and context != "" then
       if (context[-1] > 128 and literal[0] > 128) or
@@ -451,10 +453,11 @@
       "part=#{@pos}",
       "base=#{@literal}",
       "basekey=#{@pron}",
-      ( "conjugation=#{@conjugation}"       unles****@conju*****?()    ),
-      ( "suffix=#{@rest}"                   unles****@rest*****?()           ),
-      ( "annotation=#{@data['annotation']}" if****@data*****_key?('annotation') ),
-      ( "usage=#{@data['usage']}"           if****@data*****_key?('usage')      ),
+      ( "conjugation=#{@conjugation}"  unles****@conju*****?() ),
+      ( "suffix=#{@rest}"              unles****@rest*****?()        ),
+      ( "form=#{@data['form']}"        if****@data*****_key?('form')    ),
+      ( "usage=#{@data['usage']}"      if****@data*****_key?('usage')   ),
+      ( "comment=#{@data['comment']}"  if****@data*****_key?('comment') ),
     ]
     return data_list.compact.join("\t")
   end


Prime-cvs メーリングリストの案内
アーカイブの一覧に戻る