Presentation is loading. Please wait.

Presentation is loading. Please wait.

NJIT 1 Domain Model Visualizing Concepts Chapter 9 Applying UML and Patterns Craig Larman.

Similar presentations


Presentation on theme: "NJIT 1 Domain Model Visualizing Concepts Chapter 9 Applying UML and Patterns Craig Larman."— Presentation transcript:

1 NJIT 1 Domain Model Visualizing Concepts Chapter 9 Applying UML and Patterns Craig Larman

2 2 Comments on diagrams Now that we are starting to look at diagrams, I want to emphasize that this is a class on analysis and design, not diagramming. While it may look good on your resume that you can use UML, your career depends on being able to translate ideas into good systems. That is much more difficult.

3 3 Domain Model Relationships Domain Model Use Case Model Interaction Diagrams Glossary Design Requirements Business Model Classes, attributes, associations Domain objects Elaboration on some terms

4 4 A Domain Model illustrates meaningful conceptual classes in a problem domain. is a representation of real-world concepts, not software components. is NOT a set of diagrams describing software classes, or software objects and their responsibilities.

5 5 A Domain Model is the most important OO artifact Its development entails identifying a rich set of conceptual classes, and is at the heart of object oriented analysis. It is a visual representation of the decomposition of a domain into individual conceptual classes or objects. It is a visual dictionary of noteworthy abstractions.

6 6 Domain Model UML Notation Illustrated using a set of class diagrams for which no operations are defined. It may contain: Domain Objects or Conceptual Classes Associations between conceptual classes Attributes of conceptual classes

7 7 A Domain Model is not a Software Artifact Sale Date Time SalesDatabase Sale Date Time Print() A Conceptual class: Software Artifacts: vs.

8 8 Think of Conceptual Classes in terms of: Symbols – words or images Intensions – its definition Extensions – the set of examples to which it applies Symbols and Intensions are the practical considerations when creating a domain model.

9 9 Decomposition: A central distinction between Object- oriented analysis and structured analysis is the division by objects rather than by functions during decomposition. During each iteration, only objects in current scenarios are considered for addition to the domain model.

10 10 Conceptual Class Identification: It is better to overspecify a domain with lots of fine-grained conceptual classes than it is to underspecify it. Discover classes up front rather than later. Unlike data modeling, it is valid to include concepts for which there are no attributes, or which have a purely behavioral role rather than an informational role.

11 11 Identify Conceptual Classes by Category List: Common Candidates for classes include: Tangible objects, Descriptions, Roles, Places, Transactions, Containers, Systems, Abstract nouns, Rules, Organizations, Events, Processes, Written Materials, Catalogs, Records, Financial Instruments and Services

12 12 Identify Conceptual Classes by Noun Phrase: Identify Nouns and Noun Phrases in textual descriptions of the domain. Fully dressed Use Cases are good for this type of linguistic analysis. It’s not strictly a mechanical process: Words may be ambiguous Different phrases may represent the same concepts.

13 13 Sales Domain example - ‘Purchase Items’ Use Case We find concepts such as Register, Sale, Item, Customer, Receipt etc. in this use case. Should we include Receipt in the Model? Con: As a report of a sale, it’s duplicate info. Pro: Business Rules for a Return require that the customer has a receipt. Suggestion: Include it in the iteration where the Return Use Case is covered.

14 14 Steps to create a Domain Model Identify Candidate Conceptual classes Draw them in a Domain Model Add associations necessary to record the relationships that must be retained Add attributes necessary for information to be preserved Apply existing Analysis Patterns

15 15 Apply the Mapmaker Strategy Use existing names for things, the vocabulary of the domain Exclude irrelevant features Do not add things that are not there

16 16 A Common Mistake - Classes as Attributes Rule: If we do not think of a thing as a number or text in the real world, then it is probably a conceptual class. If it takes up space, then it is likely a conceptual class. Examples: A Store is not an attribute of a Sale A Destination is not an attribute of a flight

17 17 Specification or Description Conceptual Classes A Class that records information about an item. Even if all Instances of the item are sold out, the description remains. Avoids duplication of recording the descriptive information with each instance of the item.

18 18 Description of a Service Example (Flight) Airport Name vs. Flight Date Time Number Flight Date Time FlightDesc Date Time Airport Name Flies-to Described -by Describes -flights-to

19 19 Monopoly Concepts (candidates) Monopoly GamePlayerPiece DieBoard Square

20 20 UML Notation: Multiple Perspectives UML describes raw diagram types, such as class diagrams. It does not impose a specific method or process. UP, the Unified Process, applies raw UML to defined methodology models. UML can be used for 3 different perspectives: Essential – describe the real world Specifications – software abstractions, such as components and their interfaces Implementation – specific language (Java)


Download ppt "NJIT 1 Domain Model Visualizing Concepts Chapter 9 Applying UML and Patterns Craig Larman."

Similar presentations


Ads by Google