- Define what a design pattern is and why patterns matter
- Explain the Factory pattern and implement it in Java
- Explain the Strategy pattern and implement it in Java
- Relate Factory pattern to Spring’s
BeanFactoryandApplicationContext - Relate Strategy pattern to Spring’s DI and polymorphism
- Choose the right pattern for a given design problem
flowchart LR
A[ctx.getBean] --> B[ApplicationContext / BeanFactory]
B --> C{Configuration}
C --> D[EmailNotification bean]
C --> E[SMSNotification bean]