MCPcopy Index your code
hub / github.com/BruceEckel/OnJava8-Examples / runAll

Method runAll

patterns/state/StateMachineDemo.java:19–22  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

17 protected abstract boolean changeState();
18 // Template method:
19 protected final void runAll() {
20 while(changeState())
21 currentState.run();
22 }
23}
24
25// A different subclass for each state:

Callers 1

WasherMethod · 0.80

Calls 2

changeStateMethod · 0.95
runMethod · 0.65

Tested by

no test coverage detected