CS1C – Advanced Programming in C++Saddleback College Fall 2011 – J TateyamaTopic 11 – Software Development and Object Oriented Design CS1C – Saddleback CollegeThe software life cycle –Consists of all activities that take place between the time a software program or project is conceived and its retirementDevelopment is part of the life cycle and is typically broken down into 5 phases:–Analysis–Design–Implementation–Testing–DeploymentBut a project doesn’t start with development!Software Life CycleCS1C – Saddleback CollegeProject Management Process GroupsBefore development the project must be initiated and plannedThe following are the 5 Project Management Process Groups along with some of the main knowledge areas in each–Initiating•Develop project charter and identify stakeholders–Planning•Develop plans and deliverables as needed including scope, requirements, resources, budgets, risk identification and responses–Executing•Project execution/development and quality assurance–Monitoring & Controlling•Verify and control scope, perform quality control, monitor risks–Closing•Close project and procurementsCS1C – Saddleback CollegeAnalysis PhaseDuring the analysis phase decisions are made about “what” the project is supposed to accomplishYou should not be thinking about “how” to accomplish the tasksThe main deliverable from the analysis phase is a “requirements document” or “scope document”–This document describes in detail what the project will be able to do once it is completed–It should also set performance criteria or “service level agreements”One of the hardest parts about analysis is knowing when to stop analyzing and start designingCS1C – Saddleback CollegeDesign PhaseDuring the design phase decisions are made about “how” the project should be implemented–With object oriented design you decide what classes you need and their most important member functions–The following UML diagrams may be included•Class diagrams – static diagrams that display the relationship among classes•Use cases - describe the steps that are necessary to for a successful completion of a specific interaction between “actors” and the system•Sequence diagrams – show the dynamics of a particular scenario; they describe communication relationships among objects•State diagrams – document objects that change their behavior according to their current stateCS1C – Saddleback CollegeImplementation PhaseDuring the implementation phase code is developed to implement the classes and member functions discovered during the design phaseThe deliverables of this phase are completed programs “Unit testing” should also be done during development to ensure that each individual component executes correctly–Checks a function in isolation using a “test harness” – a short program written to execute test cases–Many unit test frameworks are available to organize unit test cases for testing larger programs. A few are:•CppUnit Testing Framework•Boost.Test Framework•Google C++ Testing Framework CS1C – Saddleback CollegeTesting PhaseDuring the testing phase you run additional test to verify the programs are working correctlyThe deliverable is normally a report describing the tests that were carried out and their expected and actual resultsSeveral types of testing are usually required–Integration testing – verify interfaces are working –System testing – verify system is working as designed–Performance testing – verify system will work under production loads–User Acceptance testing – assures end users are satisfied with the system; sign-off usually requiredCS1C – Saddleback CollegeDeployment PhaseThe deployment phase includes all activities associated with installing components of a project and making them available in a production environmentAll of these phases are usually controlled by some type of formal processes–These processes identify the activities and deliverables of each phase–They provide guidelines on how to carry out each phase and when to move from one phase to the nextCS1C – Saddleback CollegeFormal Development ProcessesWaterfall–First established in the 70’s and stipulated that each phase should complete before the next phase beganIterative–Project is divided into iterations rather than finishing an entire stage before moving onto the next. At the end of each iteration you will have some kind of product which is further refined in the next iterationAnalysisDesignImplementationTestingDeploymentCS1C – Saddleback CollegeAgile–Collection of light weight software development methodologies–Value and support evolving requirements through •iterative development•direct Customer/Developer communication and collaboration•self organizing cross-functional teams•continuous improvement through frequent inspection and adaptionFormal Development ProcessesPlanBuildTestReviewPlanBuildTestReviewPlanBuildTestReviewPlanBuildTestReviewReview DeployCS1C – Saddleback CollegeFormal Development ProcessesLean Software Development–Rooted in the Lean Manufacturing techniques developed by Toyota–Another popular example of a lightweight agile approach to product development–Much like other agile methods, Lean attempts to address the shortcomings of traditional software project management methods by focusing on people and effective communication.CS1C – Saddleback CollegeClass Design using CRC CardsCRC cards are used to document Classes, their Responsibilities and describe the Collaboration between classesOn way to identify classes is to keep a list of nouns as you brainstorm – you can always cross off ones not neededAs you think about the verbs in the task you pick the class that should be responsibleFor each responsibility note which other classes are needed to fulfill it. These are the collaborators.CS1C – Saddleback CollegeClass DesignCohesion–Proper class design dictates that a class should represent a single concept–The member functions and variables that the public interfaces expose should be cohesive–They should all be closely related to the single concept of the classCS1C – Saddleback CollegeClass DesignCoupling–A class depends on another if one of its member functions uses an object of another class in some way–Note in this example Date is not dependant on Student. Date
View Full Document