From 471c4ab2eac23f4ca4fa806e3c06bacfd62a505a Mon Sep 17 00:00:00 2001 From: jbion Date: Wed, 28 Dec 2016 01:16:02 +0100 Subject: Remove useless parent exception --- .../sevenwonders/errors/UniqueIdAlreadyUsedException.java | 15 --------------- src/main/java/org/luxons/sevenwonders/game/Lobby.java | 3 +-- 2 files changed, 1 insertion(+), 17 deletions(-) delete mode 100644 src/main/java/org/luxons/sevenwonders/errors/UniqueIdAlreadyUsedException.java (limited to 'src/main/java') diff --git a/src/main/java/org/luxons/sevenwonders/errors/UniqueIdAlreadyUsedException.java b/src/main/java/org/luxons/sevenwonders/errors/UniqueIdAlreadyUsedException.java deleted file mode 100644 index b1b00453..00000000 --- a/src/main/java/org/luxons/sevenwonders/errors/UniqueIdAlreadyUsedException.java +++ /dev/null @@ -1,15 +0,0 @@ -package org.luxons.sevenwonders.errors; - -public class UniqueIdAlreadyUsedException extends RuntimeException { - - private String id; - - public UniqueIdAlreadyUsedException(String id) { - super("'" + id + "'"); - this.id = id; - } - - public String getUsedId() { - return id; - } -} diff --git a/src/main/java/org/luxons/sevenwonders/game/Lobby.java b/src/main/java/org/luxons/sevenwonders/game/Lobby.java index 848f3e5d..30b31d4b 100644 --- a/src/main/java/org/luxons/sevenwonders/game/Lobby.java +++ b/src/main/java/org/luxons/sevenwonders/game/Lobby.java @@ -3,7 +3,6 @@ package org.luxons.sevenwonders.game; import java.util.ArrayList; import java.util.List; -import org.luxons.sevenwonders.errors.UniqueIdAlreadyUsedException; import org.luxons.sevenwonders.game.data.GameDefinition; public class Lobby { @@ -94,7 +93,7 @@ public class Lobby { static class PlayerUnderflowException extends IllegalStateException { } - static class PlayerNameAlreadyUsedException extends UniqueIdAlreadyUsedException { + static class PlayerNameAlreadyUsedException extends RuntimeException { PlayerNameAlreadyUsedException(String name) { super(name); } -- cgit