Skip to content

Applying Composite Design Pattern #20

Description

@ManzanillaSebastian

Within the tetris package, applying the Composite pattern to this program makes the work of the Main client class easier. Previously, the client class implemented the display of the figures on the screen, and the Figure class was also responsible for implementing the movement of each of its cells. By applying Composite, the client class only calls the show() method of the Fi_g_ure class. Finally, the Figure class does not worry about implementing the display of the squares on the screen or their movement, instead, it only calls the show() and move() methods of each square respectively.

image
image
image
image
image

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions