class DeciderBuilder extends AnyRef
Used for building a partial function for Actor.supervisorStrategy()
. * Inside an actor you can use it like this with Java 8 to define
your supervisorStrategy.
Example:
@Override private static SupervisorStrategy strategy = new OneForOneStrategy(10, Duration.ofMinutes(1), DeciderBuilder. match(ArithmeticException.class, e -> resume()). match(NullPointerException.class, e -> restart()). match(IllegalArgumentException.class, e -> stop()). matchAny(o -> escalate()).build()); @Override public SupervisorStrategy supervisorStrategy() { return strategy; }
- Source
- DeciderBuilder.java
Linear Supertypes
Type Hierarchy
Ordering
- Alphabetic
- By Inheritance
Inherited
- DeciderBuilder
- AnyRef
- Any
Implicitly
- by any2stringadd
- by StringFormat
- by Ensuring
- by ArrowAssoc
- Hide All
- Show All
Visibility
- Public
- All