public final class Text extends java.lang.Object implements java.lang.CharSequence, java.lang.Comparable<Text>
A common text element which is used by multiple elements and namespaces in XMPP. This list of elements it is used by includes:
Collator instance of the locale (if any) and is consistent with equals.| Constructor and Description |
|---|
Text(java.lang.String text)
Constructs a default status.
|
Text(java.lang.String text,
java.util.Locale language)
Constructs a status with a language attribute.
|
| Modifier and Type | Method and Description |
|---|---|
char |
charAt(int index) |
int |
compareTo(Text o) |
boolean |
equals(java.lang.Object o) |
java.util.Locale |
getLanguage()
Gets the language.
|
java.lang.String |
getText()
Gets the text.
|
int |
hashCode() |
int |
length() |
java.lang.CharSequence |
subSequence(int start,
int end) |
java.lang.String |
toString() |
public Text(java.lang.String text)
Constructs a default status.
text - The text.public Text(java.lang.String text,
java.util.Locale language)
Constructs a status with a language attribute.
text - The textlanguage - The language.public final java.util.Locale getLanguage()
Gets the language.
public final java.lang.String getText()
Gets the text.
public final int length()
length in interface java.lang.CharSequencepublic final char charAt(int index)
charAt in interface java.lang.CharSequencepublic final java.lang.CharSequence subSequence(int start,
int end)
subSequence in interface java.lang.CharSequencepublic final int compareTo(Text o)
compareTo in interface java.lang.Comparable<Text>public final boolean equals(java.lang.Object o)
equals in class java.lang.Objectpublic final int hashCode()
hashCode in class java.lang.Objectpublic final java.lang.String toString()
toString in interface java.lang.CharSequencetoString in class java.lang.ObjectCopyright © 2014–2019 XMPP.rocks. All rights reserved.