module QT::MtUtil
Extended Modules
Defined in:
core/mt_core/mt_util.crConstant Summary
-
DIVS =
"章节幕回折"
-
HAN_VAL =
{'零' => 0, '〇' => 0, '一' => 1, '两' => 2, '二' => 2, '三' => 3, '四' => 4, '五' => 5, '六' => 6, '七' => 7, '八' => 8, '九' => 9, '十' => 10, '百' => 100, '千' => 1000, '万' => 10000, '亿' => 100000000, '兆' => 1000000000000_i64}
-
LABEL_RE_1 =
/^(\p{Ps}?第?([#{NUMS}]+|[0-9]+|\d+)([集卷季])\p{Pe}?)([\p{P}\s ]*)(.*)$/
-
LBLS =
{"季" => "Mùa", "章" => "Chương", "卷" => "Quyển", "集" => "Tập", "节" => "Tiết", "幕" => "Màn", "回" => "Hồi", "折" => "Chiết"}
-
NUMS =
"零〇一二两三四五六七八九十百千"
-
TITLE_RE_1 =
/^(第[ \s]*([#{NUMS}]+|[0-9]+|\d+)[ \s]*([章节幕回折]))([\p{P}\s ]*)(.+)/
-
TITLE_RE_2 =
/^(\p{Ps}?([#{NUMS}]+|[0-9]+|\d+)\p{Pe}?([章节幕回折]))([\p{P}\s ]*)(.*)$/
-
TITLE_RE_3 =
/^(\d+|[0-9]+)([\p{P}\s ]*)(.*)$/
-
TITLE_RE_4 =
/^(楔\s*子)(\s+| +)(.+)$/
Instance Method Summary
- #tl_title(title : String)
-
#to_integer(str : String) : Int64
convert chinese numbers to latin numbers TODO: Handle bigger numbers
- #to_integer(char : Char) : Int32 | Int64
Instance Method Detail
def to_integer(str : String) : Int64
#
convert chinese numbers to latin numbers
TODO Handle bigger numbers