Class LetterTileGroup

java.lang.Object
com.example.project.controllers.gameScreens.LetterTileGroup

public class LetterTileGroup extends Object
tile group that observes an observable list and updates the ui Tile Controller's nodes into their EmptyTileController nodes.
  • Constructor Details

    • LetterTileGroup

      public LetterTileGroup(int numberOfEmptyTileSlots, javafx.scene.layout.Pane container, javafx.beans.property.ReadOnlyListProperty<LetterTile> observedList, Consumer<LetterTileController> onClickHandler, List<Runnable> afterSyncActions)
      Constructor
      Parameters:
      numberOfEmptyTileSlots - number of max tiles in group (empty slots)
      container - container to place all in.
      observedList - the observed list.
      onClickHandler - On tile click action.
      afterSyncActions - additional synchronisation actions that need to happen when this observed list changes.
    • LetterTileGroup

      public LetterTileGroup(int numberOfEmptyTileSlots, javafx.scene.layout.Pane container, javafx.beans.property.ReadOnlyListProperty<LetterTile> observedList, Consumer<LetterTileController> onClickHandler)
      Constructor
      Parameters:
      numberOfEmptyTileSlots - number of max tiles in group (empty slots)
      container - container to place all in.
      observedList - the observed list.
      onClickHandler - On tile click action.
  • Method Details

    • getControllers

      public List<LetterTileController> getControllers()
      Gets the groups tile controllers.
      Returns:
      the letter tile groups controllers