mirror of
https://github.com/vanitasvitae/Smack.git
synced 2025-09-10 09:39:39 +02:00
improve Message parser robustness and I18N for Message bodies (fixes SMACK-207 and SMACK-307)
git-svn-id: http://svn.igniterealtime.org/svn/repos/smack/trunk@11824 b35dd754-fafc-0310-a699-88a17e54d16e
This commit is contained in:
parent
7e01c66374
commit
cb5310c984
4 changed files with 538 additions and 88 deletions
|
@ -416,18 +416,15 @@ public abstract class Packet {
|
|||
return this.xmlns;
|
||||
}
|
||||
|
||||
protected static String parseXMLLang(String language) {
|
||||
if (language == null || "".equals(language)) {
|
||||
language = DEFAULT_LANGUAGE;
|
||||
}
|
||||
return language;
|
||||
}
|
||||
|
||||
protected static String getDefaultLanguage() {
|
||||
/**
|
||||
* Returns the default language used for all messages containing localized content.
|
||||
*
|
||||
* @return the default language
|
||||
*/
|
||||
public static String getDefaultLanguage() {
|
||||
return DEFAULT_LANGUAGE;
|
||||
}
|
||||
|
||||
|
||||
public boolean equals(Object o) {
|
||||
if (this == o) return true;
|
||||
if (o == null || getClass() != o.getClass()) return false;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue