mirror of
https://github.com/vanitasvitae/Smack.git
synced 2025-09-09 17:19:39 +02:00
Improve StringUtils.escapeForXml()
This commit is contained in:
parent
f2a748db9a
commit
e6a9027cc6
11 changed files with 169 additions and 43 deletions
|
@ -85,7 +85,7 @@ public class Macros extends IQ {
|
|||
if (getPersonalMacroGroup() != null) {
|
||||
// CHECKSTYLE:OFF
|
||||
buf.append("<personalMacro>");
|
||||
buf.append(StringUtils.escapeForXML(getPersonalMacroGroup().toXML()));
|
||||
buf.append(StringUtils.escapeForXmlText(getPersonalMacroGroup().toXML()));
|
||||
buf.append("</personalMacro>");
|
||||
// CHECKSTYLE:ON
|
||||
}
|
||||
|
|
|
@ -97,7 +97,7 @@ public class MetaDataUtils {
|
|||
for (Iterator<String> it = value.iterator(); it.hasNext();) {
|
||||
String v = it.next();
|
||||
buf.append("<value name=\"").append(key).append("\">");
|
||||
buf.append(StringUtils.escapeForXML(v));
|
||||
buf.append(StringUtils.escapeForXmlText(v));
|
||||
buf.append("</value>");
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue