Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

answer these question SECTION 2 - Creational (Factory) Patterns & Principles (10) 4. List and describe (1-2 sentences each) three of the design approaches we

answer these question image text in transcribed
SECTION 2 - Creational (Factory) Patterns & Principles (10) 4. List and describe (1-2 sentences each) three of the design approaches we discussed for constructing, or creating, Java objects. (Hint: think shirts) (6 points) a. make it yourself. ... For example, we need a pretty cool shirt to go to a party, We want the shirt to be unique and perfect fit, we can make one by ourself. b. Use of factory. We still need a pretty cool shirt to go to a party, but we have skills on making clothes, we can use of factory visit son Stores to find out a shirt that we like. are give out . you a c. Get via injection, If we don't have skills on making clothes and we money, we can ask someone to buy a shirt and 5. Draw and explain what is the Dependency Inversion Principle (DIP)? How does the use of Factory patterns support it? Be specific in your answers. (4 points) The Dependency Inversion principle, high level classes are a directly with low level classes, they are using interface as an ab The Factory patterns support the DIP because the purpose o patterns is to expose a me that for creating objects, allowing su m the actual creation process

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Students also viewed these Databases questions