Open
Description
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.
Metadata
Metadata
Assignees
Labels
No labels