Interface Stepper
- public interface Stepper
A Stepper is something that has methods for stepping
forward or backward.
-
stepBackward()
- move backward.
-
stepForward()
- move forward one (and only one) step.
stepForward
public abstract void stepForward() throws CannotStepException
- move forward one (and only one) step.
If it is not possible (e.g., the stepper is hitting a wall),
then stepForward() throws a
CannotStepException.
stepBackward
public abstract void stepBackward() throws CannotStepException
- move backward. (and only one) step.
If it is not possible (e.g., the stepper is hitting a wall),
then stepBackward() throws a
CannotStepException.