1 / 40

Chapter 8: Conceptual Model Chapter 10, 11 & 12 in Applying UML and Patterns Book.

Chapter 8: Conceptual Model Chapter 10, 11 & 12 in Applying UML and Patterns Book. UML overview, where are we now? Understands what concept model is. Concepts. Attributes. Associations. Knowing how to draw a concept model either from the problem domain or the use case. Overview.

jcarmen
Download Presentation

Chapter 8: Conceptual Model Chapter 10, 11 & 12 in Applying UML and Patterns Book.

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Chapter 8: Conceptual Model Chapter 10, 11 & 12 in Applying UML and Patterns Book.

  2. UML overview, where are we now? • Understands what concept model is. • Concepts. • Attributes. • Associations. • Knowing how to draw a concept model either from the problem domain or the use case. Overview

  3. 1) Use Cases • Define user interaction with the system. 2) Conceptual Model << we are here right now. • Underline nouns to identify concepts in the problem domain. • Use the underlined nouns from the use cases to create the concepts in the conceptual model. • Some of the nouns, if they identify simple data types, are used to create attributes of these concepts. • Create associations between the concepts. UML Process Overview

  4. 3) Sequence Diagram << we have done this it can be done before or after conceptual model or in parallel with it. • Create system sequence diagrams for each use case scenario. • Each sequence event in the diagram corresponds to a user interaction with the system specified by the expanded use case. 4) Class Diagram • Add methods and additional attributes which were discovered in the collaboration diagrams to the classes in the conceptual model. UML Process Overview

  5. 5) Code • Create classes with their names, attributes and method signatures taken from the class diagram. • For each method on a class, use the sequence diagrams to find the sequence of messages generated when the method is called and create at least one line of code for each message. UML Process Overview

  6. Is also named domain model. • Is an analysis-level activity. • A model of real-world objects and NOT an attempt to design the actual software. Conceptual (Domain) Model

  7. A domain model illustrates meaningful concepts in a problem domain. • It’s a representation of real-world things, not software components. • It’s a set of static structure diagrams; no operations are defined. • It may show: • Concepts • Attributes of concepts. • Associations between concepts. Conceptual (Domain) Model

  8. Library Book Patron Librarian Loan

  9. A domain model is a description of things in the real world. • A domain model is NOT a description of the software design. • A concept is an idea, thing, or object. Conceptual (Domain) Model

  10. Items Cashier Sale Sale line item POS customer Store

  11. A central distinction between object-oriented and structured analysis: division by concepts (objects) rather than division by functions. Conceptual Classes in the Sale Domain

  12. Use a conceptual class category list. • Make a list of candidate concepts. • Use noun phrase identification. • Identify noun (and noun phrases) in textual descriptions of the problem domain, and consider them as concepts or attributes. • Use cases are excellent description to draw for this analysis. Strategies to Identify Conceptual Classes

  13. Use a Conceptual Class Category List * See complete list in Larman 2nd edition, P.G. 134 - 135.

  14. The fully addressed use cases are an excellent description to draw for this analysis. • Some of these noun phrases are candidate concepts; some may be attributes of concepts. • A mechanical noun-to-concept mapping is not possible, as words in a natural language are (sometimes) ambiguous. Finding a Conceptual Classes with Noun Phrase Identification

  15. Narrative language is well understood by everyone on a project. • An effective communication medium for both technical and non-technical project staff. • Usually, one-to-one mapping from nouns to objects or classes or interfaces. • No learning curve. Advantages of Noun Phrase Identification

  16. The imprecision of natural language. • Different noun phrases may represent the same conceptual class or attribute, among other ambiguities. • Nouns do not always result in classes, or objects in the problem domain. • Many sentences in a functional specification may be in the wrong form for easy identification of the objects and classes. For example, ”roll back the transaction” or “the software will compute the average salary”. • In many cases, the nouns, especially subjects to sentences, refer to: • An entire assembly or a computer software configuration, • A sub assembly or a software component, • An attribute, • Service. Disadvantages of Noun Phrase Identification

  17. Noun phrase technique. • Interview the domain experts. • Conceptual Class Category List. • Consider whether: • it is any real-life entity. • it is important to the requirement discussion. • Finally, we need additional steps: • Use the use cases to generate scenarios. • Use the scenarios to find missing categories and interfaces. • Record the scenarios. Recommended Approach

  18. What is wrong with this picture? • Consider the case where all items are sold, and thus deleted from the computer memory. • How much does an item cost? The Need for Specification or Description Conceptual Classes

  19. The memory of the item’s price was attached to inventoried instances, which were deleted. • Notice also that in this model there is duplicated data (description, price, itemID). The Need for Specification or Description Conceptual Classes

  20. Add a specification or description concept when: • Deleting instances of things they describe results in a loss of information that needs to be maintained, due to the incorrect association of information with the deleted thing. • It reduces redundant or duplicated information. The Need for Specification or Description Conceptual Classes

  21. The NextGen POS (Partial) Domain Model

  22. Adding Associations

  23. Finding AssociationsCommon Associations List * See complete list in Larman 2nd edition, P.G. 156 - 157.

  24. Multiplicity defines how many instances of a type A can be associated with one instance of a type B, at a particular moment in time. • For example: a single instance of a Store can be associated with “many” (zero or more) Item instances. Multiplicity

  25. Multiplicity

  26. Name an association based on a TypeName-VerbPhrase-TypeName format. • Association names should start with a capital letter. • A verb phrase should be constructed with hyphens. • The default direction to read an association name is left to right, or top to bottom. Naming Associations

  27. It’s not uncommon to have multiple associations between two types. • In the example, not every flight is guaranteed to land at an airport. Multiple Associations Between Two Types

  28. An attribute is a logical data value of an object. • Include the following attributes: those for which the requirements suggest or imply a need to remember information. • For example, a Sales receipt normally includes a date and time. • The Sale concept would need a date and time attribute. Adding Attributes

  29. 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),... Valid Attributes Types

  30. We still need to discuss: • Class-based types. • Attribute visibility. • These issues require deeper knowledge of modelling. Hence, they will be discussed later on as the course progresses. We are not finished with the attributes yet!!

  31. Domain Model Conclusion

  32. We need to write an application supporting us in managing the information about university operation. Right now, at Stockholm University we have a substantial amount of students - 35 000 students. To manually manage all information about students is simply impossible. Hence, SU needs some automated support. In addition to this, we need handle information on courses and lecturersgiving these courses. Recently, SU has taken over the library and book shops. They want to provide better service to their students, and they want to better integrate the management of course literature with all other courses given at SU. Hence, they wish to automate the book management as well. This gives them better insight into the education on the course level, and provides a solid basis for evaluating the courses and a basis for establishing the incremental educational programme. The knowledge of which books are utilised on which course helps them identify the overlapping in the educational material. To be able to provide high quality education, SU must have highly competent lecturers. SU wishes to store information about their lecturers and their state of competence and its development. By competence, SU means professional, pedagogical and administrative competence. Underline concepts (or maybe attributes),Red means association or transaction category concept. University Case Study

  33. Student Lecturer Book shop Competence Evaluation Course Evaluation Course Book Library Course Overlapping Competence University Do we need a class called University? University Case Study Conceptual Classes

  34. How is the object described in general? • What parts of the general description are applicable to this problem domain? • What is the minimal description needed for this application? Advice When Finding attributes

  35. Student Teacher Course pnr: Integer student_name: String address: String nationality: String degree_level: String grade: Integer IQ Integer $average_age: Integer pnr: Integer teacher_name: String role: String ped_competence: String admin_competence: String prof_competence: String percentage_of_full_time: Integer salary: Integer martial_state: String research_engagement: String course_number: Integer course_name: String course_description: String no_of_students: Integer teacher_name: String equipment_type: String Book book_number: Integer ISBN_number: String title: String price: Real University Case StudyAttributes

  36. Students at SU may take many different courses. The students however, should not take more than five courses during one semester. A course may only start if there are at least 15 students registered. Otherwise, the course has to be cancelled. Teaching for less than 15 students would be too expensive. The courses are taught by lecturers. The fact that you are a lecturer does not hinder you from taking courses at university. There may be cases that a lecturer takes and teaches on one and the same course simultaneously. This is in cases when the lecturer is a PhD student. The work he has put into developing and teaching on a course will give him credit point within his PhD studies. So lecturers may take courses as well. Each university course is based on some book. One course may be based on at least one book. However, many books may be read on one and the same course. Blue means constraint, many to many will be implemented by adding a transaction class. University Case StudyAssociations

  37. University Case StudyAssociations

  38. We do not need these any more! University Case StudyAssociations

More Related