What is software design?
Software design is a key artefact in software development and is closely linked with system implementation.
What is the software design process?
What is a programming paradigm?
A way to classify programming languages
- Imperative: requires you to say what needs to be done, and how it is done, e.g. Java, Javascript
- Declarative: describe what needs to be done, without explicitly describing the control flow, e.g. Haskell, SQL
What are some aspects of software design?
Structure
- Runtime (runtime structure, i.e. software architecture -> can be multiple clients with one server, multiple servers, microservices, etc.)
- Development (units of code in classes, methods and packages)
- Deployment
Behaviour
- Interactions (may require separate interface design)
- Control and Data flow
What are some types of software design?
Planned
- Significant issues are thought out in advance
- Potentially inflexible and out of sync with technology and changing requirements
Evolutionary
- Design of system grows as the system is implemented
- Can become a collection of ad-hoc decisions
What are some considerations for software design?
Design for change
Make components (units) atomic so that changes can be localised and made without disrupting the whole system. Modularity, separation of concerns, loosely coupling, high cohesion
User appropriate patterns
Higher level structure, architecture design, design patterns, tried and tested solutions to solve particular problems
Communicate the design
Everyone in the development team should understand the design, and why these design choices have been made
Listen to the development team
Development team can provide insights on challenges and limitations, bidirectional process
Refactor often
Especially in evolutionary design, there is no overall plan if you are incrementally adding features. We can reduce technical debt by being agile
What is a model?
A model is an abstract view of a system. A set of complementary models can be created to show
different perspectives of a software system design
It is not a complete reflection of the real world. The more abstract the model, the easier it is to understand- but more details are left out.
What can models be used for?
What are some modelling notations for software design?
Informal diagrams
- Boxes and lines
Semi-formal diagrams
- UML, SysML
Formal specifications
- CSP, 𝜋-calculus, petri nets, Promela
What is UML?
Unified Modelling Language (UML) is a graphical language used to model various artefacts of a software system, and particularly focuses on object-oriented design.
What can UML diagrams represent?
Structure
Component, composite structure, deployment, package, class, object, profile
Behaviour
Activity, state machine, use case
Interaction
Communication, sequence, interaction overview, timing
When do we use UML diagrams in software development?
Requirements
Use case diagram
Software Architecture
Component diagram, activity diagram, deployment diagram
Software Design
Class diagram, sequence diagram, state machine diagram