From 211c2fda6310c87104c4b9accac75ef4eb48b7f7 Mon Sep 17 00:00:00 2001 From: Leonardo Brandenberger Date: Fri, 10 Dec 2021 10:38:53 +0100 Subject: [PATCH] Command Class(Cleanup and Javadoc) --- src/ch/zhaw/catan/Command.java | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/src/ch/zhaw/catan/Command.java b/src/ch/zhaw/catan/Command.java index 4fa2e77..8b5b103 100644 --- a/src/ch/zhaw/catan/Command.java +++ b/src/ch/zhaw/catan/Command.java @@ -1,6 +1,9 @@ package ch.zhaw.catan; -//TODO:JavaDoc + +/** + * + */ public enum Command { NEXT_PLAYER("next player"), BUILD_SETTLEMENT("build settlement"), BUILD_CITY("build city"), BUILD_ROAD("build road"), TRADE_WITH_BANK("trade with bank"), QUIT("quit"); @@ -12,6 +15,12 @@ public enum Command { this.commandWord = commandWord; } + /** + * Overrides the toString method and lets it give out the commandWord as a string when used. + * + * @return commandWord as a String + */ + @Override public String toString() { return commandWord; }