Added Javadocs

This commit is contained in:
Nathan Lum
2019-04-11 20:18:53 -06:00
committed by GitHub
parent 7134a6825e
commit 0221a5a2f1

View File

@@ -12,6 +12,11 @@ public class WarehouseLogic extends Player {
setPlayer(playerDummy); setPlayer(playerDummy);
} }
/**
* Method that tranfers your cargo from your ship to your warehouse.
* Has error handling to prevent incorrect inputs
*
*/
public String deposit(String str, int goodsNum) { public String deposit(String str, int goodsNum) {
try { try {
int deposit = Integer.parseInt(str); int deposit = Integer.parseInt(str);
@@ -52,6 +57,11 @@ public class WarehouseLogic extends Player {
} }
} }
/**
* Method that transfers cargo from your warehouse onto your ship.
* Has error handling to prevent incorrect inputs
*
*/
public String withdraw(String str, int goodsNum) { public String withdraw(String str, int goodsNum) {
try { try {
int withdraw = Integer.parseInt(str); int withdraw = Integer.parseInt(str);