UML for Java Programmers

Description

This two-day course is designed as a broad overview of the UML, with specific emphasis on reading the UML notation and accurately translating design into code.  This course is designed for software Implementers, not Designers and Architects.  Therefore, the course is focused on aspects of developing code in strict accordance with the design.  The majority of the course is composed of lectures and exercises in Rational Rose designed to enhance an Implementers understanding of the UML input artifacts from design to construction.

 

Participants will be exposed to all major UML design artifacts, and strategies for code development from each design construct for Java.  Participants will learn how to do code generation, reverse engineering, and roundtrip engineering in Rational Rose for Java.  RUP methods will be referenced for iterative development, stressing the importance of design and code synchronization.

 

This course is in the form of short lectures followed by Lab exercises, which will be completed by teams of 2 people working together. The class and instructor will review lab results. Instructional computers will include Rational Rose.

 

Understanding of the course material will be demonstrated by means of end-of-lesson surveys and Pre/Post Questionnaires for the course.

Overall Course Objective

Upon completion of the course, participants will be able to read and understand UML designs at a sufficient level to develop code in Java.

Course Objectives

·         Describe the UML design artifacts– what they are, when they are produced, by whom, and for what purpose.

·         Describe the purpose of use cases and how they relate to code.

·         Interpret Activity and Use Case Diagrams.

·         Translate the static elements of design into code: Class Diagrams and Specifications

·         Translate the relational elements of design into code: generalization, association, aggregation

·         Differentiate between the data model and the object model

·         Translate the dynamic elements of design into code: Sequence Diagrams, State Diagrams, Collaboration Diagrams

·         Translate the detailed elements of Class Specifications into code: methods, attributes, relationships (types, export control, stereotypes)

·         Synchronize code and design using forward, reverse, and roundtrip engineering

Scope and Intent

The purpose of this course is to interpret UML designs, not to create the designs. Emphasis will be on issues relating to code development from UML to Java.

Audience

This course is intended for Implementers only.

Lesson Course Outline

1.       Introduction to UML

·         Purpose and Background

·         4+1 model architecture review

·         Logical

·         Implementation

·         Process

·         Deployment

·         Use Case

·         RUP Artifact Set

·         RUP Design Package

·         UML References

 

2.       Use Case View: Interpreting Use Case Documents

·         Use Case diagrams

·         Use Case documents

 

3.       Use Case View: Interpreting Use Case Flows

·         Activity diagrams

·         Use Case Realizations

·         Relationships between the parts of the use case view

 

4.       Logical View: UML static models

·         What is a static model?

·         Class Specifications/Diagrams

·         Stereotypes

·         Relationships

·         Association

·         Aggregate

·         Composite

·         Generalization

·         Roles

·         Attributes

·         Operations

·         Method Specification

·         Packages

·         Dependencies

·         Control Units

 

5.       Code Generation

·         Using Rational Rose to generate Java

·         Parts of the model which generate code

·         Forward engineering practices

·         Setting model properties for code generation

·         Creating code for languages which are not object-oriented

 

6.       Reverse Engineering and Roundtrip Engineering with Rational Rose

·         Reverse engineering practices

·         Roundtrip engineering practices

 

7.       Object Models and Data Models

·         Relationship between the models

·         Generating a database schema from a data model in Rational Rose

·         Reverse engineering DDL's in Rational Rose

 

8.       Logical View: UML dynamic models

·         What is a dynamic model?

·         Object models

·         Sequence diagrams

·         Collaboration diagrams

·         State diagrams

 

9.       Implementation View:

·         Component diagrams

·         Expressing the implementation architecture in component diagrams

 

10.   Process View:

·         Component diagrams for process architecture

·         Inter-process communication on sequence diagrams

 

11.   Deployment View: 

·         Deployment diagrams

·         Expressing the physical architecture in deployment diagrams

·         How deployment diagrams influence the code

Duration

8 hours Lecture

8 hours Lab

Prerequisites

Participants must have taken the Rational Rose Fundamentals course.

Source Materials

·         "UML for Java Programmers”, Robert C. Martin, Pearson Education, ISBN 0-13-142848-9

SME / Content Providers

Alex Rush, Geri Schneider Winters

Instructors

Wendy Boggs, Dave Fortescue, Alex Rush, Lauren Thayer, Geri Schneider Winters

 


Lesson 1: Introduction to UML

 

Lesson Description:

This lesson introduces the Unified Modeling Language (UML). It includes the purpose of the UML, how it fits into RUP, and a review of RUP artifacts important to implementers: 4+1 Architecture, Artifacts used and produced by implementers, and the design package.

 

Lesson Objective (overall objective):

Understand what the Unified Modeling Language (UML) is and the relationship between RUP and UML.

 

Enabling Objectives:

·         Describe the purpose and background of UML

·         Describe the parts of the 4+1 architecture

·         List the artifacts that will be used by implementers

·         Describe a Design Package

 

Scope and Intent:

The purpose of this lesson is to give the background and context of the Unified Modeling Language.

 

Outline:

·         Introduction to UML

·         Purpose and Background

·         4+1 Model Architecture review

·         Logical

·         Implementation

·         Process

·         Deployment

·         Use Case

·         RUP Artifact Set

·         RUP Design Package

·         UML References

 

Lab Objectives

No lab for this lesson

 

Estimated Duration

30 minutes Lecture

No lab

 

 


Lesson 2: Use Case View: Interpreting Use Case Documents

 

Lesson Description:

This lesson discusses use cases and the use case view in Rational Rose. It includes descriptions of the use case diagram and use case documents.

 

Lesson Objective (overall objective):

Understand a use case by identifying and interpreting the diagrams and documents that describe a use case.

 

Enabling Objectives:

·         Identify the diagrams and documents that describe a use case

·         Interpret the use case document

·        Interpret the use case diagram

 

Scope and Intent:

The purpose of this lesson is for participants to understand the functionality of a use case by navigating to and interpreting the diagrams and documents that describe a use case. This includes the use case diagram and use case document.

 

Outline:

·         Use Case View: Interpreting Use Case Documents

·         Use Case Diagrams

·         Use Case Documents

 

Lab Objectives

-Description

Use Rational Rose and Microsoft Word to gather information about a use case by navigating to the diagrams and documents that describe the use case.

 

-Objectives

·         Review a Use Case Diagram.

·         Review the Use Case Documents associated with the use cases in the diagram.

·         Describe the functionality of the use cases to the class.

 

Estimated Duration

60 minutes Lecture

30 minutes Lab

 


Lesson 3: Use Case View: Interpreting Use Case Flows

 

Lesson Description:

This lesson continues the discussion of use cases by examining the diagrams that document the flow of a use case. This includes the activity diagram and use case realization. The lesson also discusses the relationship between the various diagrams and documents in the use case view.

 

Lesson Objective (overall objective):

Understand a use case by identifying and interpreting the diagrams and documents that describe a use case.

 

Enabling Objectives:

·         Interpret an activity diagram

·         Interpret a use case realization

·        Describe the relationships between the parts of the use case view

 

Scope and Intent:

The purpose of this lesson is for participants to understand the functionality of a use case by navigating to and interpreting the diagrams and documents that describe a use case flow. This includes the activity diagram and use case realization.

 

Outline:

·         Use Case View: Interpreting Use Case Flows

·         Activity Diagrams

·         Use Case Realizations

·         Relationships between the parts of the use case view

 

Lab Objectives

-Description

Use Rational Rose to gather information about a use case by navigating to the diagrams and documents that describe the use case.

 

-Objectives

·         Review the Activity Diagrams associated with the use cases in the use case diagram.

·         Review the Use Case Realizations associated with the use cases in the use case diagram.

·        Describe the relationships between the parts of the use case view.

 

Estimated Duration

60 minutes Lecture

30 minutes Lab


Lesson 4: Logical View: UML Static Models

 

Lesson Description:

This lesson discusses the logical view in Rational Rose, specifically the static model part of the logical view. This includes specifications for classes, attributes, operations, and relationships, the class diagram, and the package diagram. The lesson also discusses the relationship between the various diagrams in the logical view.

 

Lesson Objective (overall objective):

Understand the classes that will implement a project by identifying and interpreting the diagrams and specifications that describe these classes.

 

Enabling Objectives:

·         Identify the diagrams and documents that describe classes

·         Interpret a class diagram

·         Interpret the class specification

·         Interpret the attribute specification

·         Interpret the operation specification

·         Interpret the relationship specification

·        Interpret the package diagram describing work units

 

Scope and Intent:

The purpose of this lesson is for participants to understand the classes that will implement a project by navigating to and interpreting the diagrams and specifications that describe classes. This includes specifications for classes, attributes, operations, and relationships, the class diagram, and the package diagram.

 

Outline:

·         Logical View: UML Static Models

·         What is a static model?

·         Class Specifications/Diagrams

·         Stereotypes

·         Relationships

·         Association

·         Aggregate

·         Composite

·         Generalization

·         Roles

·         Attributes

·         Operations

·         Method Specification

·         Packages

·         Dependencies

·         Control Units

 

Lab Objectives

-Description

Use Rational Rose to gather information about the classes in a project by navigating to the diagrams and specifications that describe the classes.

 

-Objectives

·         Review a Class Diagram.

·         Browse to a class specification and review that specification.

·         Browse to the attribute specification and review that specification.

·         Browse to the operation specification and review that specification.

·         Browse to the relationship specification and review that specification.

·         Browse to the properties of a class and review those properties.

·         Review a package diagram describing work units

·         Describe the basic class structure to the other participants.

 

Estimated Duration

60 minutes Lecture

60 minutes Lab

 


Lesson 5: Code Generation

 

Lesson Description:

This lesson discusses how to produce code from UML class diagrams. It includes using Rational Rose to generate Java source code and manually creating code for languages such as COBOL and C, which are not object oriented.

 

Lesson Objective (overall objective):

Understand how to produce source code from UML class diagrams for both object-oriented languages and languages that are not object-oriented.

 

Enabling Objectives:

·         Use a UML class diagram and specifications to produce Java source code

·         Use a UML class diagram and specifications to produce COBOL or C source code

 

Scope and Intent:

The purpose of this lesson is for participants to produce code from UML class diagrams.

 

Outline:

·         Code Generation

·         Using Rational Rose to generate Java

·         Parts of the model which generate code

·         Forward engineering practices

·         Setting model properties for code generation

·         Creating code for languages which are not object-oriented

 

Lab Objectives<