zhongwen_tools 0.15.2 → 0.16.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -105,6 +105,38 @@ module ZhongwenTools
105
105
  ZhongwenTools::Romanization::MPS2::to_mps2(self, from)
106
106
  end
107
107
 
108
+ def py?
109
+ ZhongwenTools::Romanization::Pinyin.py?(self)
110
+ end
111
+
112
+ def pyn?
113
+ ZhongwenTools::Romanization::Pinyin.pyn?(self)
114
+ end
115
+
116
+ def bpmf?
117
+ ZhongwenTools::Romanization::ZhuyinFuhao.bpmf?(self)
118
+ end
119
+
120
+ def wg?
121
+ ZhongwenTools::Romanization::WadeGiles.wg?(self)
122
+ end
123
+
124
+ def yale?
125
+ ZhongwenTools::Romanization::Yale.yale?(self)
126
+ end
127
+
128
+ def typy?
129
+ ZhongwenTools::Romanization::TongyongPinyin.typy?(self)
130
+ end
131
+
132
+ def mps2?
133
+ ZhongwenTools::Romanization::MPS2.mps2?(self)
134
+ end
135
+
136
+ def romanization?
137
+ ZhongwenTools::Romanization.romanization?(self)
138
+ end
139
+
108
140
  def zhs?
109
141
  ZhongwenTools::Script.zhs?(self)
110
142
  end
@@ -1,3 +1,3 @@
1
1
  module ZhongwenTools
2
- VERSION = '0.15.2'
2
+ VERSION = '0.16.0'
3
3
  end
@@ -62,6 +62,14 @@ class TestStringExtention < Minitest::Test
62
62
  end
63
63
  end
64
64
 
65
+ assert @rom[:pyn].pyn?
66
+ assert @rom[:py].py?
67
+ assert @rom[:bpmf].bpmf?
68
+ assert @rom[:yale].yale?
69
+ assert @rom[:typy].typy?
70
+ assert @rom[:wg].wg?
71
+ assert @rom[:mps2].mps2?
72
+ assert_equal @rom[:pyn].romanization?, :pyn
65
73
 
66
74
  # script.rb
67
75
  load 'zhongwen_tools/script.rb'# unless ZhongwenTools.const_defined?(:Script)
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: zhongwen_tools
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.15.2
4
+ version: 0.16.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Steven Daniels
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-08-25 00:00:00.000000000 Z
11
+ date: 2014-09-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rake