@ThreadSafe public class DefaultPinyinTone extends AbstractPinyinTone
| 构造器和说明 |
|---|
DefaultPinyinTone() |
| 限定符和类型 | 方法和说明 |
|---|---|
protected String |
getCharTone(String segment,
IPinyinToneStyle toneStyle)
获取单个字的映射
|
protected CharToneInfo |
getCharToneInfo(String tone)
获取对应的声调信息
|
protected List<String> |
getCharTones(String chinese,
IPinyinToneStyle toneStyle)
获取单个字符的所有拼音列表
|
protected String |
getPhraseTone(String segment,
IPinyinToneStyle toneStyle,
String connector)
获取词组的映射
|
Set<String> |
phraseSet()
词组列表
作用:快速分词。
|
int |
toneNum(String defaultPinyin)
根据中文获取对应的拼音声调
1.
|
tone, toneListprotected List<String> getCharTones(String chinese, IPinyinToneStyle toneStyle)
AbstractPinyinTonegetCharTones 在类中 AbstractPinyinTonechinese - 中文字符toneStyle - 拼音格式protected String getCharTone(String segment, IPinyinToneStyle toneStyle)
AbstractPinyinTonegetCharTone 在类中 AbstractPinyinTonesegment - 单个的字toneStyle - 拼音格式protected String getPhraseTone(String segment, IPinyinToneStyle toneStyle, String connector)
AbstractPinyinTonegetPhraseTone 在类中 AbstractPinyinTonesegment - 单个的字toneStyle - 拼音格式connector - 连接符号public Set<String> phraseSet()
IPinyinTonepublic int toneNum(String defaultPinyin)
IPinyinTonedefaultPinyin - 中文拼音-默认格式protected CharToneInfo getCharToneInfo(String tone)
tone - 拼音信息Copyright © 2023. All rights reserved.