From ee56d1e57aa1359f7bc0b696d3cf8edfd500b2bc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=A3o=20Lino?= Date: Mon, 25 Jul 2022 15:39:56 +0200 Subject: [PATCH] interface definition for the library --- src/main/java/org/example/scoreboard/IMatch.java | 5 +++++ src/main/java/org/example/scoreboard/IScore.java | 5 +++++ .../java/org/example/scoreboard/IScoreboard.java | 14 ++++++++++++++ src/main/java/org/example/scoreboard/ITeam.java | 4 ++++ 4 files changed, 28 insertions(+) create mode 100644 src/main/java/org/example/scoreboard/IMatch.java create mode 100644 src/main/java/org/example/scoreboard/IScore.java create mode 100644 src/main/java/org/example/scoreboard/IScoreboard.java create mode 100644 src/main/java/org/example/scoreboard/ITeam.java diff --git a/src/main/java/org/example/scoreboard/IMatch.java b/src/main/java/org/example/scoreboard/IMatch.java new file mode 100644 index 0000000..134d5dd --- /dev/null +++ b/src/main/java/org/example/scoreboard/IMatch.java @@ -0,0 +1,5 @@ +package org.example.scoreboard; + +public interface IMatch { + +} diff --git a/src/main/java/org/example/scoreboard/IScore.java b/src/main/java/org/example/scoreboard/IScore.java new file mode 100644 index 0000000..992791a --- /dev/null +++ b/src/main/java/org/example/scoreboard/IScore.java @@ -0,0 +1,5 @@ +package org.example.scoreboard; + +public interface IScore { + +} diff --git a/src/main/java/org/example/scoreboard/IScoreboard.java b/src/main/java/org/example/scoreboard/IScoreboard.java new file mode 100644 index 0000000..6daaee6 --- /dev/null +++ b/src/main/java/org/example/scoreboard/IScoreboard.java @@ -0,0 +1,14 @@ +package org.example.scoreboard; + +import java.util.ArrayList; + +public interface IScoreboard { + + IMatch startMatch(ITeam home, ITeam away); + + void finishMatch(IMatch match); + + IMatch updateScore(IMatch match, IScore home, IScore away); + + ArrayList getGameSummary(); +} diff --git a/src/main/java/org/example/scoreboard/ITeam.java b/src/main/java/org/example/scoreboard/ITeam.java new file mode 100644 index 0000000..1980e58 --- /dev/null +++ b/src/main/java/org/example/scoreboard/ITeam.java @@ -0,0 +1,4 @@ +package org.example.scoreboard; + +public interface ITeam { +} -- 2.24.1