tailieunhanh - Lecture Software design and architecture – Chapter 23

Lecture 23 – Class diagram. The class diagram is a static model that shows the classes and the relationships among classes that remain constant in the system over time. The class diagram depicts classes, which include both behaviors and states, with the relationships between the classes. The following sections will first present the elements of the class diagram, followed by the way in which a class diagram is drawn. | SOFTWARE DESIGN AND ARCHITECTURE LECTURE 23 Review Class Responsibility Collaboration Cards CRC Models Creating CRC Models Outline ANALYSIS Level Class Diagram Identifying Entities Identifying Attributes Identifying Operations Identifying Relationships Class diagram Class Diagram A class diagram is an artifact that defines the classes( objects) of the system and provides means to represent their relationships. How to create a class diagram Identify entities Identify the attributes Identify and model the relationships (detailed Diagram) Identify operations Define multiplicities Identify Entities After defining the use cases, the next step is to cross the system boundary. Open the system “black box”. Think of the whole system in terms of entities, concepts or objects. Concept Category List How to represent entities? A Domain Model is used to represent entities and it illustrates meaningful concepts in a problem domain. It is a representation of real-world things, not software . | SOFTWARE DESIGN AND ARCHITECTURE LECTURE 23 Review Class Responsibility Collaboration Cards CRC Models Creating CRC Models Outline ANALYSIS Level Class Diagram Identifying Entities Identifying Attributes Identifying Operations Identifying Relationships Class diagram Class Diagram A class diagram is an artifact that defines the classes( objects) of the system and provides means to represent their relationships. How to create a class diagram Identify entities Identify the attributes Identify and model the relationships (detailed Diagram) Identify operations Define multiplicities Identify Entities After defining the use cases, the next step is to cross the system boundary. Open the system “black box”. Think of the whole system in terms of entities, concepts or objects. Concept Category List How to represent entities? A Domain Model is used to represent entities and it illustrates meaningful concepts in a problem domain. It is a representation of real-world things, not software components. It is a set of static structure diagrams; no operations are defined. It may show: concepts associations between concepts attributes of concepts Example: POS Identify Attributes An attribute is a logical data value of an object. For example, a Sales receipt normally includes a date and time. The Sale concept would need a date and time attribute. Attributes Keep attributes simple. The type of an attribute should not normally be a complex domain concept, such as Sale or Airport. Attributes in a Domain Model should preferably be Pure data values: Boolean, Date, Number, String, Simple attributes: color, phone number, zip code, universal product code (UPC), . Identify Entity Relations The relationships between the entities identified earlier are known as associations. An association is a relationship between concepts that indicates some meaningful and interesting connection. Associations can be named. Associations can be identified using common association list. Identify .

TỪ KHÓA LIÊN QUAN