Course Hero Logo

Truong Giang 1651Khoa_168100_0.pdf - ASSIGNMENT 1 FRONT...

Course Hero uses AI to attempt to automatically extract content from documents to surface to you and others so you can study better, e.g., in search results, to enrich docs, and more. This preview shows page 1 - 7 out of 70 pages.

ASSIGNMENT 1 FRONT SHEETQualificationBTEC Level 5 HND Diploma in ComputingUnit number and titleUnit 20: Advanced ProgrammingSubmission dateAugust 17, 2020Date Received 1st submissionRe-submission DateDate Received 2nd submissionStudent NameNguyen Khoa Truong GiangStudent IDGCH18272ClassGCH0715Assessor nameDoan Trung TungStudent declarationI certify that the assignment submission is entirely my own work and I fully understand the consequences of plagiarism. I understand thatmaking a false declaration is a form of malpractice.Student’s signatureK.GiangGrading gridP1P2M1M2D1D2
Summative Feedback:Resubmission Feedback:Grade:Assessor Signature:Date:Lecturer Signature:2.1
Table of ContentsList of Figures.............................................................................................................................................................................................4List of Table................................................................................................................................................................................................5I.Introduction.........................................................................................................................................................................................6II.OOP (Object Oriented Program) General Concepts...........................................................................................................................61.Overview about OOP.......................................................................................................................................................................62.OOP Scenario.................................................................................................................................................................................113.Use Case Diagram..........................................................................................................................................................................124.Class Diagram and Explanation.....................................................................................................................................................145.Example of Sequence Diagram......................................................................................................................................................16III.Design Patters................................................................................................................................................................................171.What is a Design Pattern................................................................................................................................................................172.Types of Design Pattern.................................................................................................................................................................173.Uses of Design Pattern...................................................................................................................................................................181.Creational Design Pattern..............................................................................................................................................................18a.Overview....................................................................................................................................................................................18bSingleton Pattern (Viet)..............................................................................................................................................................19c.Builder Pattern (Hieu)................................................................................................................................................................232.Structural Design Pattern (Thuy)...................................................................................................................................................27a. Overview.......................................................................................................................................................................................27b. Adapter Pattern.............................................................................................................................................................................283.Behavioral Design Pattern (Giangz)..............................................................................................................................................32a.Strategy.......................................................................................................................................................................................33b.Observer......................................................................................................................................................................................33
IV.Design Patterns vs OOP.................................................................................................................................................................36a.Singleton........................................................................................................................................................................................37b.Builder............................................................................................................................................................................................38c.Observer.........................................................................................................................................................................................38d.Adapter...........................................................................................................................................................................................39V.Conclusion........................................................................................................................................................................................40VII. References.........................................................................................................................................................................................68List of FiguresFigure 1. Example of Encapsulation...........................................................................................................................................................7Figure 2: Example inheritance....................................................................................................................................................................9Figure 3: Example Polymorphism............................................................................................................................................................10Figure 4. Use Case Diagram.....................................................................................................................................................................12Figure 5. OOP Class Diagram..................................................................................................................................................................14Figure 6. Example ofSequence use in the diagram.................................................................................................................................16Figure 7. Singleton Module......................................................................................................................................................................20Figure 8. Singleton Example.....................................................................................................................................................................20Figure 9. Singleton Class Diagram based on the Scenario.......................................................................................................................22Figure 10. Builder Pattern Class Diagram based on the scenario.............................................................................................................26Figure 11. Class Adapter...........................................................................................................................................................................28Figure 12. Object Adapter.........................................................................................................................................................................29Figure 13: Lili Bank diagram class...........................................................................................................................................................31Figure 14. Observer Class Diagram..........................................................................................................................................................36Figure 15. Singleton Example...................................................................................................................................................................38Figure 16. Observer Class Diagram Example...........................................................................................................................................39
List of TableTable 1. Advantages and Disadvantages of Adapter................................................................................................................................30
I.IntroductionThe following will be my group's presentations that include explaining the features of the object-oriented programming model byapplying them. Object oriented analysis and design on a scenario (assumption) and specific examples, characteristics of object orientedprogramming. Introduce 3 types (including 3 types: Creational, structure and behavior) for the audience by giving real situations, thecorresponding patterns are UML class diagrams. Analyze the relationship between the object oriented model and design pattern.II.OOP (Object Oriented Program) General Concepts1.Overview about OOP

Upload your study docs or become a

Course Hero member to access this document

Upload your study docs or become a

Course Hero member to access this document

End of preview. Want to read all 70 pages?

Upload your study docs or become a

Course Hero member to access this document

Term
Fall
Professor
N/A
Tags
Object Oriented Programming, Singleton, Design pattern

Newly uploaded documents

Show More

Newly uploaded documents

Show More

  • Left Quote Icon

    Student Picture

  • Left Quote Icon

    Student Picture

  • Left Quote Icon

    Student Picture