1
0
Fork 0
mirror of https://codeberg.org/Mercury-IM/Smack synced 2025-09-10 18:59:41 +02:00

SMACK-412 Added the pingMyServer back in, cleaned up unneeded synchronization and removed minimum ping interval.

git-svn-id: http://svn.igniterealtime.org/svn/repos/smack/branches/smack_3_3_0@13588 b35dd754-fafc-0310-a699-88a17e54d16e
This commit is contained in:
rcollier 2013-03-23 11:59:08 +00:00
parent 999c86ef4c
commit a14178990b
8 changed files with 174 additions and 42 deletions

View file

@ -41,10 +41,12 @@ import java.io.PrintWriter;
* @author Matt Tucker
*/
public class XMPPException extends Exception {
private static final long serialVersionUID = 6881651633890968625L;
private StreamError streamError = null;
private XMPPError error = null;
private Throwable wrappedThrowable = null;
private SmackError smackError = null;
/**
* Creates a new XMPPException.
@ -62,6 +64,16 @@ public class XMPPException extends Exception {
super(message);
}
/**
* Creates a new XMPPException with a Smack specific error code.
*
* @param code the root cause of the exception.
*/
public XMPPException(SmackError code) {
super(code.getErrorMessage());
smackError = code;
}
/**
* Creates a new XMPPException with the Throwable that was the root cause of the
* exception.
@ -74,7 +86,7 @@ public class XMPPException extends Exception {
}
/**
* Cretaes a new XMPPException with the stream error that was the root case of the
* Creates a new XMPPException with the stream error that was the root case of the
* exception. When a stream error is received from the server then the underlying
* TCP connection will be closed by the server.
*
@ -144,6 +156,16 @@ public class XMPPException extends Exception {
return error;
}
/**
* Returns the SmackError asscociated with this exception, or <tt>null</tt> if there
* isn't one.
*
* @return the SmackError asscociated with this exception.
*/
public SmackError getSmackError() {
return smackError;
}
/**
* Returns the StreamError asscociated with this exception, or <tt>null</tt> if there
* isn't one. The underlying TCP connection is closed by the server after sending the