Class Battleship

java.lang.Object
battleship.model.ships.Ship
battleship.model.ships.Battleship

public class Battleship extends Ship
  • Constructor Details

    • Battleship

      public Battleship()
  • Method Details

    • getLength

      public int getLength()
      Specified by:
      getLength in class Ship
      Returns:
      max length
    • restoreHealthInRecoveryMode

      public void restoreHealthInRecoveryMode()
      When the recovery mode is enabled this method restore. health of the ship to 5.
      Specified by:
      restoreHealthInRecoveryMode in class Ship
    • toString

      public String toString()
      Overrides:
      toString in class Object
      Returns:
      ship type name