| 程序包 | 说明 |
|---|---|
| cn.hutool.core.text.escape |
提供各种转义和反转义实现
|
| cn.hutool.core.text.replacer |
文本替换类抽象及实现
|
| 限定符和类型 | 类和说明 |
|---|---|
class |
Html4Escape
HTML4的ESCAPE
参考:Commons Lang3
|
class |
Html4Unescape
HTML4的UNESCAPE
|
class |
NumericEntityUnescaper
形如'的反转义器
|
class |
XmlEscape
XML特殊字符转义
见:https://stackoverflow.com/questions/1091945/what-characters-do-i-need-to-escape-in-xml-documents & (ampersand) 替换为 & < (less than) 替换为 < > (greater than) 替换为 > " (double quote) 替换为 " ' (single quote / apostrophe) 替换为 ' |
class |
XmlUnescape
XML的UNESCAPE
|
| 限定符和类型 | 类和说明 |
|---|---|
class |
LookupReplacer
查找替换器,通过查找指定关键字,替换对应的值
|
class |
ReplacerChain
字符串替换链,用于组合多个字符串替换逻辑
|
| 限定符和类型 | 方法和说明 |
|---|---|
Iterator<StrReplacer> |
ReplacerChain.iterator() |
Iterator<StrReplacer> |
ReplacerChain.iterator() |
| 限定符和类型 | 方法和说明 |
|---|---|
ReplacerChain |
ReplacerChain.addChain(StrReplacer element) |
ReplacerChain |
ReplacerChain.addChain(StrReplacer element) |
| 构造器和说明 |
|---|
ReplacerChain(StrReplacer... strReplacers)
构造
|
ReplacerChain(StrReplacer... strReplacers)
构造
|
Copyright © 2022. All rights reserved.