Class TrackDrawer

java.lang.Object
it.polimi.ingsw.view.cli.drawer.TrackDrawer
All Implemented Interfaces:
Buildable, Fillable

public class TrackDrawer
extends java.lang.Object
implements Fillable, Buildable
Class that builds and fills the Cli representation of the Track
  • Constructor Summary

    Constructors
    Constructor Description
    TrackDrawer()  
  • Method Summary

    Modifier and Type Method Description
    java.lang.String[][] build()
    Build a Cli representation of the Object in which is implemented
    void fill​(java.lang.String[][] fillMe, SimpleGameState gameState)
    Fill the Cli representation of the Object passed as parameter with its current state Used to fill Objects related to the game
    void fill​(java.lang.String[][] fillMe, SimplePlayerState playerState)
    Fill the Cli representation of the Object passed as parameter with its current state Used to fill Objects related to the player board

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • TrackDrawer

      public TrackDrawer()
  • Method Details

    • build

      public java.lang.String[][] build()
      Description copied from interface: Buildable
      Build a Cli representation of the Object in which is implemented
      Specified by:
      build in interface Buildable
      Returns:
      the representation in matrix of String format
    • fill

      public void fill​(java.lang.String[][] fillMe, SimplePlayerState playerState)
      Description copied from interface: Fillable
      Fill the Cli representation of the Object passed as parameter with its current state Used to fill Objects related to the player board
      Specified by:
      fill in interface Fillable
      Parameters:
      fillMe - , the representation of the Object who needs to be filled
      playerState - , state of the player
    • fill

      public void fill​(java.lang.String[][] fillMe, SimpleGameState gameState)
      Description copied from interface: Fillable
      Fill the Cli representation of the Object passed as parameter with its current state Used to fill Objects related to the game
      Specified by:
      fill in interface Fillable
      Parameters:
      fillMe - , the representation of the Object who needs to be filled
      gameState - , state of the game