Professional Documents
Culture Documents
John Jannotti
CSCI032 (cs032)
Feb 4, 2013
Software Lifecycle
Feb 4, 2013
1 / 15
Course Announcements
Autocomplete is due today. Project groups are due today. Swing (not git) lab is going on now. Next week
Requirements analysis due Thursday. git lab
Software Lifecycle
Feb 4, 2013
2 / 15
Requirements Gathering
Techniques
User studies; interviews; surveys Keep the user part of the team
First step for your term project You must understand what the user wants in order to build it!
Software Lifecycle
Feb 4, 2013
3 / 15
Specications
Programmers requirements
Detail the problem: what the program does Dene the inputs and outputs Dene interfaces to existing systems Give a precise statement of what will be done Describe how this meets requirements Develop testing and acceptance plan What, not how not time for algorithms / data structures
Techniques
Stories & scenarios Design diagrams, UML User manual
You have to know what you are going to build in order to design it!
Software Lifecycle
Feb 4, 2013
4 / 15
Software Design
What is involved
Dene system architecture Specify packages, classes and methods Develop data structures and algorithms Problem analysis Dene the solution down to a level where it can be easily implemented
Key principles
Risk Avoidance Simplicity Abstraction
A good spec should allow a good engineer to build your system. A good design should allow a mediocre engineer to build, maintain, and extend your system.
Software Lifecycle
Feb 4, 2013
5 / 15
Design Process
Top-Level Design
Components and interfaces Dene the boundaries between components
Components allocated to individuals or groups All communication is through interfaces Pretend that subsystems will be used by outsiders.
Detailed design
Class implementations Helper classes, methods, . . .
Techniques
UML; interface code; XP: design as you go (and refactor)
XP does not excuse a lack of forethought.
Software Lifecycle
Feb 4, 2013
6 / 15
Coding
AKA Programming
Should be the easiest part of the process. If not, youre probably conating it with design.
Techniques
Emphasis on programming style Emphasis on defensive programming Write tests with, or before, implementations
Software Lifecycle
Feb 4, 2013
7 / 15
Testing
Types of Testing
Module or class testing unit tests Integration testing putting classes together Systems testing the whole shebang Acceptance testing by user
A successful test case nds a problem Writing tests forces you to think about API. Think about testing before design & coding
Design: design for and with testing XP: write the test cases rst Testing should be thorough and continuous
Software Lifecycle
Feb 4, 2013
8 / 15
Maintenance
What it involves
Fixing bugs; adding features; adapting Fix a bug? Write a test.
Software Lifecycle
Feb 4, 2013
9 / 15
Software Lifecycle
Feb 4, 2013
10 / 15
Waterfall Model
1 2 3 4 5 6
Software Lifecycle
Feb 4, 2013
11 / 15
Feedback Model
1 2 3 4 5 6
Software Lifecycle
Feb 4, 2013
11 / 15
Prototyping Model
2a Prototype
2 3 4 5 6
Software Lifecycle
Feb 4, 2013
12 / 15
Agile Programming
Software Lifecycle
Feb 4, 2013
13 / 15
Agile Workow
Software Lifecycle
Feb 4, 2013
14 / 15
Agile/XP Model
Pair programming
Program in pairs, one writing, one reading We encourage you to try this on pair/group work
Shared responsibility
Everyone on the team is responsible for all the code in the project We may ask anyone in a group about any part of design.
Emphasis on simplicity
Write the simplest code possible Avoid complexity unless absolutely necessary
Encourage refactoring
The best design will evolve As you see ways to improve the design, do so incrementally
Software Lifecycle
Feb 4, 2013
15 / 15