summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGurmeen Bindra <gurmeen.bindra@isode.com>2012-03-29 14:34:35 (GMT)
committerKevin Smith <git@kismith.co.uk>2012-03-29 15:04:06 (GMT)
commitc194f7d215935cded5b2eab4daeed725a5a4069c (patch)
tree18f68f2247e4a7dd0f3fcb403dfcb2c6f9b3ff02 /src/com/isode/stroke/elements/ErrorPayload.java
parentcb4600a1612a5dd8342656241e11ec45542cd1e0 (diff)
downloadstroke-c194f7d215935cded5b2eab4daeed725a5a4069c.zip
stroke-c194f7d215935cded5b2eab4daeed725a5a4069c.tar.bz2
Port Error Parser to stroke
After this change, the error payload object should be populated in case of error. The condtion, type and text field will be from the payload rather than Undefined, Cancel and empty. Test-information: tested by executing adhoc-commands on an XMPP clinet in a way to result in an error. I do see the error text and condition set as per the XMPP streams. Reviewer: Kevin Smith <kevin.smith@isode.com>
Diffstat (limited to 'src/com/isode/stroke/elements/ErrorPayload.java')
-rw-r--r--src/com/isode/stroke/elements/ErrorPayload.java11
1 files changed, 10 insertions, 1 deletions
diff --git a/src/com/isode/stroke/elements/ErrorPayload.java b/src/com/isode/stroke/elements/ErrorPayload.java
index b0ffd58..42e9c61 100644
--- a/src/com/isode/stroke/elements/ErrorPayload.java
+++ b/src/com/isode/stroke/elements/ErrorPayload.java
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2010, Isode Limited, London, England.
+ * Copyright (c) 2010-2012, Isode Limited, London, England.
* All rights reserved.
*/
/*
@@ -16,6 +16,7 @@ public class ErrorPayload extends Payload {
private Condition condition_;
private Type type_;
private String text_;
+ private Payload payload_;
public enum Type { Cancel, Continue, Modify, Auth, Wait };
@@ -85,4 +86,12 @@ public class ErrorPayload extends Payload {
public String getText() {
return text_;
}
+
+ public void setPayload(Payload payload) {
+ this.payload_ = payload;
+ }
+
+ public Payload getPayload() {
+ return payload_;
+ }
}