Class BattleshipController

java.lang.Object
battleship.controller.BattleshipController

public class BattleshipController extends Object
  • Constructor Details

    • BattleshipController

      public BattleshipController()
  • Method Details

    • getView

      public BattleshipView getView()
    • startGame

      public void startGame()
      Start new game from user input parameters
    • startGame

      public void startGame(int[] args)
      Start new game with arguments from terminal.
      Parameters:
      args - arguments
    • requestForUserInput

      public int requestForUserInput(String helpString, int minBound, int maxBound)
      Request for user input
      Parameters:
      helpString - help string to print first
      minBound - minimum correct integer number
      maxBound - maximum correct integer number
      Returns:
      option (int)
    • executeCommands

      public void executeCommands()
      Execute all user input commands.