Package Diagrams Flashcards
1
Q
Two main goals for packaging
A
- Improve reasoning about and navigation through the project
- Isolate change
2
Q
Two general approaches for packaging
A
- by layer
- by feature
3
Q
Package by layer
A
- Organize packages according
to the types of classes and the
technical responsibility they
have, e.g., UI, business logic,
data persistence, etc. - Advantage: easy to understand, easy to navigate for small projects
- Disadvantage: not good at isolating change
4
Q
Package by feature
A
- Organise packages according to their domain-related functionality
→ functional cohesion - Advantage: very good at isolating change
- Disadvantage: only easy to navigate if you know the domain well
- Strongly advised for larger
projects!