diff options
author | Christian Schneppe <christian@pix-art.de> | 2018-04-27 23:55:16 +0200 |
---|---|---|
committer | Christian Schneppe <christian@pix-art.de> | 2018-04-27 23:55:16 +0200 |
commit | 4edd1b09946b861779e131c4a9c1c761ea445035 (patch) | |
tree | d94534f8f49c1aa9202617ef22db2f8385bcbb4a /src/main/java/de/pixart/messenger/entities | |
parent | 5a1105d37a87eaf1c369d9f8d9b7e67d6a0e1cd4 (diff) |
include node when requesting disco features
Diffstat (limited to 'src/main/java/de/pixart/messenger/entities')
-rw-r--r-- | src/main/java/de/pixart/messenger/entities/Presence.java | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/src/main/java/de/pixart/messenger/entities/Presence.java b/src/main/java/de/pixart/messenger/entities/Presence.java index af467f1f6..e21da6b37 100644 --- a/src/main/java/de/pixart/messenger/entities/Presence.java +++ b/src/main/java/de/pixart/messenger/entities/Presence.java @@ -47,19 +47,22 @@ public class Presence implements Comparable { private ServiceDiscoveryResult disco; private final String ver; private final String hash; + private final String node; private final String message; - private Presence(Status status, String ver, String hash, String message) { + private Presence(Status status, String ver, String hash, String node, String message) { this.status = status; this.ver = ver; this.hash = hash; + this.node = node; this.message = message; } public static Presence parse(String show, Element caps, String message) { final String hash = caps == null ? null : caps.getAttribute("hash"); final String ver = caps == null ? null : caps.getAttribute("ver"); - return new Presence(Status.fromShowString(show), ver, hash, message); + final String node = caps == null ? null : caps.getAttribute("node"); + return new Presence(Status.fromShowString(show), ver, hash, node, message); } public int compareTo(Object other) { @@ -78,6 +81,10 @@ public class Presence implements Comparable { return this.ver; } + public String getNode() { + return this.node; + } + public String getHash() { return this.hash; } |