diff options
author | pacien | 2018-02-01 12:25:04 +0100 |
---|---|---|
committer | pacien | 2018-02-01 12:25:04 +0100 |
commit | 48902d6696e40cb100c86fa83b131b4b7a016f52 (patch) | |
tree | 54294daafa9332a434fe5b50df17157ee8fc3aef /src/main/java/fr | |
parent | 5c27749c76d59e2299c67b4676426905c2a17544 (diff) | |
download | wallj-48902d6696e40cb100c86fa83b131b4b7a016f52.tar.gz |
Rename GameController and update class diagram
Signed-off-by: pacien <pacien.trangirard@pacien.net>
Diffstat (limited to 'src/main/java/fr')
-rw-r--r-- | src/main/java/fr/umlv/java/wallj/context/Game.java | 4 | ||||
-rw-r--r-- | src/main/java/fr/umlv/java/wallj/controller/GameStateController.java (renamed from src/main/java/fr/umlv/java/wallj/controller/GameController.java) | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/src/main/java/fr/umlv/java/wallj/context/Game.java b/src/main/java/fr/umlv/java/wallj/context/Game.java index d5f9873..6bc63ae 100644 --- a/src/main/java/fr/umlv/java/wallj/context/Game.java +++ b/src/main/java/fr/umlv/java/wallj/context/Game.java | |||
@@ -2,7 +2,7 @@ package fr.umlv.java.wallj.context; | |||
2 | 2 | ||
3 | import fr.umlv.java.wallj.board.Board; | 3 | import fr.umlv.java.wallj.board.Board; |
4 | import fr.umlv.java.wallj.controller.Controller; | 4 | import fr.umlv.java.wallj.controller.Controller; |
5 | import fr.umlv.java.wallj.controller.GameController; | 5 | import fr.umlv.java.wallj.controller.GameStateController; |
6 | import fr.umlv.java.wallj.event.Event; | 6 | import fr.umlv.java.wallj.event.Event; |
7 | import fr.umlv.java.wallj.block.Stage; | 7 | import fr.umlv.java.wallj.block.Stage; |
8 | 8 | ||
@@ -25,7 +25,7 @@ public final class Game { | |||
25 | */ | 25 | */ |
26 | public Game(List<Board> boards) { | 26 | public Game(List<Board> boards) { |
27 | this.controllers = new LinkedList<>(); | 27 | this.controllers = new LinkedList<>(); |
28 | this.controllers.add(new GameController()); | 28 | this.controllers.add(new GameStateController()); |
29 | Objects.requireNonNull(boards); | 29 | Objects.requireNonNull(boards); |
30 | if (boards.isEmpty()) { | 30 | if (boards.isEmpty()) { |
31 | throw new IllegalArgumentException("The list of boards is empty, not able to create a correct game from this."); | 31 | throw new IllegalArgumentException("The list of boards is empty, not able to create a correct game from this."); |
diff --git a/src/main/java/fr/umlv/java/wallj/controller/GameController.java b/src/main/java/fr/umlv/java/wallj/controller/GameStateController.java index 456793a..2c548f2 100644 --- a/src/main/java/fr/umlv/java/wallj/controller/GameController.java +++ b/src/main/java/fr/umlv/java/wallj/controller/GameStateController.java | |||
@@ -9,7 +9,7 @@ import fr.umlv.java.wallj.event.GameOverEvent; | |||
9 | import java.util.LinkedList; | 9 | import java.util.LinkedList; |
10 | import java.util.List; | 10 | import java.util.List; |
11 | 11 | ||
12 | public class GameController implements Controller { | 12 | public class GameStateController implements Controller { |
13 | 13 | ||
14 | @Override | 14 | @Override |
15 | public List<Event> update(Context context) { | 15 | public List<Event> update(Context context) { |