12.07.2015 Views

DEV475 Mastering Object-Oriented Analysis and Design with UML ...

DEV475 Mastering Object-Oriented Analysis and Design with UML ...

DEV475 Mastering Object-Oriented Analysis and Design with UML ...

SHOW MORE
SHOW LESS
  • No tags were found...

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Module 6 - Use-Case <strong>Analysis</strong>Example: Sequence DiagramExample: Sequence Diagram: Student: RegisterForCoursesForm : RegistrationController : CourseCatalogSystem : Schedule : Student : Course CatalogCreate a newschedule1: // create schedule( )2: // get course offerings( )3: // get course offerings(forSemester)4: // get course offerings( )A list of the availablecourse offerings for thissemester are displayed5: // display course offerings( )A blank scheduleis displayed for thestudents to selectofferings6: // display blank schedule( )7: // select 4 primary <strong>and</strong> 2 alternate offerings( )8: // create schedule <strong>with</strong> offerings( ) 9: // create <strong>with</strong> offerings( )10: // add schedule(Schedule)At this point, the Submit Schedule sub-flow is executed.Sequence Diagram: Register forCourses / Register for Courses - BasicFlow (Submit Schedule)<strong>Mastering</strong> <strong>Object</strong> <strong>Oriented</strong> <strong>Analysis</strong> <strong>and</strong> <strong>Design</strong> <strong>with</strong> <strong>UML</strong>Copyright © 2003 Rational Software, all rights reserved 31The above example shows the object interactions to support the Create a Schedulesub-flow of the Register for Courses use case. Some of the rationale for responsibilityallocation is as follows:• The RegisterForCoursesForm knows what data it needs to display <strong>and</strong> how todisplay it. It does not know where to go to get it. That is one of theRegistrationController’s responsibilities.• Only the RegisterForCoursesForm interacts <strong>with</strong> the Student actor.• The RegistrationController underst<strong>and</strong>s how Students <strong>and</strong> Schedules are related.• Only the CourseCatalogSystem class interacts <strong>with</strong> the external legacy CourseCatalog System.• Note the inclusion of the actors. This is important as the diagram explicitlymodels what elements communicate <strong>with</strong> the “outside world.”6 - 31

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!