Java style accessors for AbstractFSM #22592

This commit is contained in:
Johan Andrén 2017-03-17 10:18:15 +01:00
parent 363ca39f52
commit 07e88300bc
24 changed files with 85 additions and 58 deletions

View file

@ -51,7 +51,7 @@ public class SimpleEchoHandler extends AbstractActor {
})
.match(ConnectionClosed.class, msg -> {
getContext().stop(self());
getContext().stop(getSelf());
})
.build();
}
@ -71,7 +71,7 @@ public class SimpleEchoHandler extends AbstractActor {
closing = true;
} else {
// could also be ErrorClosed, in which case we just give up
getContext().stop(self());
getContext().stop(getSelf());
}
})
.build();
@ -98,7 +98,7 @@ public class SimpleEchoHandler extends AbstractActor {
if (stored > maxStored) {
log.warning("drop connection to [{}] (buffer overrun)", remote);
getContext().stop(self());
getContext().stop(getSelf());
} else if (stored > highWatermark) {
log.debug("suspending reading");
@ -120,7 +120,7 @@ public class SimpleEchoHandler extends AbstractActor {
if (storage.isEmpty()) {
if (closing) {
getContext().stop(self());
getContext().stop(getSelf());
} else {
getContext().unbecome();
}