XmppUri: Add toString() method
This commit is contained in:
parent
390d61d82c
commit
43eb293c66
1 changed files with 9 additions and 0 deletions
|
@ -13,6 +13,7 @@ import de.pixart.messenger.xmpp.jid.Jid;
|
|||
|
||||
public class XmppUri {
|
||||
|
||||
protected Uri uri;
|
||||
protected String jid;
|
||||
protected String fingerprint;
|
||||
protected List<Fingerprint> fingerprints = new ArrayList<>();
|
||||
|
@ -56,6 +57,7 @@ public class XmppUri {
|
|||
}
|
||||
|
||||
protected void parse(Uri uri) {
|
||||
this.uri = uri;
|
||||
String scheme = uri.getScheme();
|
||||
String host = uri.getHost();
|
||||
List<String> segments = uri.getPathSegments();
|
||||
|
@ -112,6 +114,13 @@ public class XmppUri {
|
|||
}
|
||||
}
|
||||
|
||||
public String toString() {
|
||||
if (uri != null) {
|
||||
return uri.toString();
|
||||
}
|
||||
return "";
|
||||
}
|
||||
|
||||
protected List<Fingerprint> parseFingerprints(String query) {
|
||||
return parseFingerprints(query, ';');
|
||||
}
|
||||
|
|
Reference in a new issue