()
| 21 | private final int id; |
| 22 | public Pizza(int id) { this.id = id; } |
| 23 | public Pizza next() { |
| 24 | step = step.forward(); |
| 25 | System.out.println("Pizza " + id + ": " + step); |
| 26 | return this; |
| 27 | } |
| 28 | public Pizza next(Step previousStep) { |
| 29 | if(!step.equals(previousStep)) |
| 30 | throw new IllegalStateException("Expected " + |