diff options
| author | Michael Lizzio <142752852+Michael-Lizzio@users.noreply.github.com> | 2025-10-05 05:30:55 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-10-05 05:30:55 -0400 |
| commit | c5cbe4ffd56b7c96d85dc1676387993c6c15af7b (patch) | |
| tree | 2ba839f3fc8fea03612e7f7051176b8d0a059a48 /src/main/java/design/model/holeplay/HoleCompleteState.java | |
| parent | 42fcc633ddc0e328561f984a6aa0b8593765dcf2 (diff) | |
| parent | 40470b1788c28f1c95bba7339dd9819b0e9b95cc (diff) | |
| download | designproject-design-6-c5cbe4ffd56b7c96d85dc1676387993c6c15af7b.tar.gz designproject-design-6-c5cbe4ffd56b7c96d85dc1676387993c6c15af7b.tar.bz2 designproject-design-6-c5cbe4ffd56b7c96d85dc1676387993c6c15af7b.zip | |
Merge pull request #2 from RIT-SWEN-262/lizzio-holePlaySubsystem
Lizzio hole play subsystem
Diffstat (limited to 'src/main/java/design/model/holeplay/HoleCompleteState.java')
| -rw-r--r-- | src/main/java/design/model/holeplay/HoleCompleteState.java | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/src/main/java/design/model/holeplay/HoleCompleteState.java b/src/main/java/design/model/holeplay/HoleCompleteState.java new file mode 100644 index 0000000..958fe5f --- /dev/null +++ b/src/main/java/design/model/holeplay/HoleCompleteState.java @@ -0,0 +1,28 @@ +package design.model.holeplay; + +public class HoleCompleteState implements HoleState { + @Override + public void enter(HolePlayContext ctx) { + /* compute summaries if needed */ } + + @Override + public void handleStart(HolePlayContext ctx) { + // optional: treat this as “Next Hole” + ctx.setState(new SetupState()); + } + + @Override + public void handleShot(HolePlayContext ctx, design.model.Club club, Integer distanceYds) { + throw new IllegalStateException("Hole is complete; start next hole."); + } + + @Override + public void handleHoleOut(HolePlayContext ctx) { + throw new IllegalStateException("Already holed out."); + } + + @Override + public String name() { + return "HoleCompleteState"; + } +} |
