n.c.
[chise/ruby.git] / chise / chisedb.rb
1 # Copyright (C) 2002-2004 Kouichirou Eto, All rights reserved.
2
3 require "singleton"
4 require "chise/rbchise"
5
6 module CHISE
7   class ChiseDB
8     include Singleton
9
10     def initialize
11       @ds = DataSource.new
12     end
13
14     def location() @ds.location; end
15     def get_feature(f) @ds.get_feature(f) end
16     def get_ccs(c) @ds.get_ccs(c) end
17     def decode_char(n, cid) @ds.decode_char(n, cid) end
18     def load_feature(n, cid) @ds.load_feature(n, cid) end
19     def each_feature() @ds.each_feature {|f| yield f } end
20     def each_ccs() @ds.each_ccs {|c| yield c } end
21   end
22 end