Commit 559a3128 authored by Yusuke Iwaki's avatar Yusuke Iwaki

Rename of exception class Disconnectied. Add comment.

parent ef3e9da6
...@@ -191,7 +191,7 @@ import rx.subjects.PublishSubject; ...@@ -191,7 +191,7 @@ import rx.subjects.PublishSubject;
.flatMap(state -> .flatMap(state ->
state == ServerConnectivity.STATE_CONNECTED state == ServerConnectivity.STATE_CONNECTED
? Single.just(true) ? Single.just(true)
: Single.error(new ServerConnectivity.Disconnected())); : Single.error(new ServerConnectivity.DisconnectedException()));
} }
private Single<Boolean> waitForDisconnected(String hostname) { private Single<Boolean> waitForDisconnected(String hostname) {
......
...@@ -17,8 +17,11 @@ public class ServerConnectivity { ...@@ -17,8 +17,11 @@ public class ServerConnectivity {
this.state = state; this.state = state;
} }
public static class Disconnected extends Exception { /**
public Disconnected() { * This exception should be thrown when connection is lost during waiting for CONNECTED.
*/
public static class DisconnectedException extends Exception {
public DisconnectedException() {
super("Disconnected"); super("Disconnected");
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment