In the drawer4 package we used the state pattern to change


Question: In the drawer4 package, we used the State pattern to change the behavior of the Canvas Editor based on its state instead of creating subclasses of Canvas Editor with different behaviors. We can look at the Figure hierarchy similarly. In the design of the drawer4 package, each of the subclasses of Figure are identical except for their behavior when asked to draw themselves. Use the State pattern to eliminate the need for subclasses of Figure, and instead change the behavior of each Figure based on its state. Then critique your design compared to the design of package drawer4.

Request for Solution File

Ask an Expert for Answer!!
Basic Computer Science: In the drawer4 package we used the state pattern to change
Reference No:- TGS02580327

Expected delivery within 24 Hours