Answered step by step
Verified Expert Solution
Question
1 Approved Answer
[ Design Pattern ] 2. (a) What are the relationships between the Facade and Abstract Factory patterns? (b) 5 10 VISITOR NODE VISITOR_1 VISITOR_2 NODE
[Design Pattern]
2. (a) What are the relationships between the Facade and Abstract Factory patterns? (b) 5 10 VISITOR NODE VISITOR_1 VISITOR_2 NODE NODE 2 Answer the following questions according to the above diagram. i) Describe the features required in each deferred class, and a typical effective class in each hierarchy, to support the pattern. ii) Suppose a class NODE_C is added as a subclass of NODE. List and describe the required changes to all of the classes affected by the addition. 111) Would you advise using the Visitor Pattern if the NODE hierarchy changed frequently? Explain your answer. iv) Describe the type of applications that are suitable for the Visitor Pattern. v) Explain the term "Double Dispatch" in visitor pattern. (c) Use the Composite pattern, to model the notion of a folder in Windows XP. Folders may be nested, and may also contain text files and binary files. Files may be opened, closed, and 5 drawn on the screen. Folders may also have items added to and removed from them. Draw the UML diagram for the described model. (d) Explain the intent and motivation of Command pattern. 5Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started