mirror of
https://codeberg.org/Mercury-IM/Smack
synced 2024-11-22 06:12:05 +01:00
Make SmackException abstract
This commit is contained in:
parent
7e76712c46
commit
394f3d133a
3 changed files with 8 additions and 8 deletions
|
@ -29,12 +29,12 @@ import org.jxmpp.jid.Jid;
|
||||||
*
|
*
|
||||||
* @author Florian Schmaus
|
* @author Florian Schmaus
|
||||||
*/
|
*/
|
||||||
public class SmackException extends Exception {
|
public abstract class SmackException extends Exception {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
private static final long serialVersionUID = 1844674365368214457L;
|
private static final long serialVersionUID = 1844674365368214458L;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Creates a new SmackException with the Throwable that was the root cause of the exception.
|
* Creates a new SmackException with the Throwable that was the root cause of the exception.
|
||||||
|
@ -49,7 +49,7 @@ public class SmackException extends Exception {
|
||||||
super(message);
|
super(message);
|
||||||
}
|
}
|
||||||
|
|
||||||
public SmackException(String message, Throwable wrappedThrowable) {
|
protected SmackException(String message, Throwable wrappedThrowable) {
|
||||||
super(message, wrappedThrowable);
|
super(message, wrappedThrowable);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -198,10 +198,10 @@ public class IncomingFileTransfer extends FileTransfer {
|
||||||
if (cause instanceof SmackException) {
|
if (cause instanceof SmackException) {
|
||||||
throw (SmackException) cause;
|
throw (SmackException) cause;
|
||||||
}
|
}
|
||||||
throw new SmackException("Error in execution", e);
|
throw new SmackException.SmackWrappedException("Error in execution", e);
|
||||||
}
|
}
|
||||||
catch (TimeoutException e) {
|
catch (TimeoutException e) {
|
||||||
throw new SmackException("Request timed out", e);
|
throw new SmackException.SmackWrappedException("Request timed out", e);
|
||||||
}
|
}
|
||||||
finally {
|
finally {
|
||||||
streamNegotiatorTask.cancel(true);
|
streamNegotiatorTask.cancel(true);
|
||||||
|
|
|
@ -56,10 +56,10 @@ public class Socks5TransferNegotiator extends StreamNegotiator {
|
||||||
return this.manager.establishSession(target, streamID).getOutputStream();
|
return this.manager.establishSession(target, streamID).getOutputStream();
|
||||||
}
|
}
|
||||||
catch (IOException e) {
|
catch (IOException e) {
|
||||||
throw new SmackException("error establishing SOCKS5 Bytestream", e);
|
throw new SmackException.SmackWrappedException("error establishing SOCKS5 Bytestream", e);
|
||||||
}
|
}
|
||||||
catch (InterruptedException e) {
|
catch (InterruptedException e) {
|
||||||
throw new SmackException("error establishing SOCKS5 Bytestream", e);
|
throw new SmackException.SmackWrappedException("error establishing SOCKS5 Bytestream", e);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -109,7 +109,7 @@ public class Socks5TransferNegotiator extends StreamNegotiator {
|
||||||
return stream;
|
return stream;
|
||||||
}
|
}
|
||||||
catch (IOException e) {
|
catch (IOException e) {
|
||||||
throw new SmackException("Error establishing input stream", e);
|
throw new SmackException.SmackWrappedException("Error establishing input stream", e);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue