Object Oriented Design 10

[ad_1]
Code from Video:

In this tutorial, I cover GRASP, or General Responsibility Assignment Software Patterns. GRASP defines rules you can use to decide which objects should have which responsibilities in your Object design.

Here I cover the following rules: Creator, Expert, Coupling, Controller and High Cohesion. The tutorial includes a presentation, code examples, sequence diagrams and class diagrams to make everything understandable and interesting. The code used is available in the link above


Posted

in

by

Tags:

Comments

27 responses to “Object Oriented Design 10”

  1. Haley Sparger Avatar

    These videos are great! Keep up the good work! This has helped me sooo much with systems design 🙂

  2. nafis sadik Avatar

    U r freaking awesome!
    I think it would be a lot better for us if u could introduce a way to let us directly jump to explanation of a particular topic.
    Like, I wanted to learn only about cohesion. If you had a link in the description to start the video straight from the part where you explained cohesion, it would be really helpful!

  3. Pheelbert's page Avatar

    … why didn't you make name protected, that way you wouldn't need to create a new member in Monkey2 and Lion2. This isn't the right way of doing inheritance.

  4. dogdutyascetic Avatar

    Whatever happened to dependency injection? The creator would make it pretty hard to test dependencies if you needed to pass mocks in. I always prefer dependency injection over newing up an object internally. It also makes the composite nature of the object more obvious.

  5. Faraz Mazhar Avatar

    So, the creator is also the information expert?

  6. Faraz Mazhar Avatar

    So, my 1/4th of the semester is basically 20mins of YT video.

  7. Krishna Kumar Avatar

    Excellent. Many Thanks to u.
    1. Way of explanation
    2. Choosing of right examples
    3. Timing
    All are good.

    Till now I am hearing about OOP but not able to under how it's powerful but because of your examples only I could understand how OOP powerful.

  8. Eliecer Hernández Avatar

    I have had problems with the "Creator" rules: when you must construct a class Y that depends on multiples classes Xn which has constructors with lots of variables, where even some of them are optionals. So in that case its been much more convenient to me to depend on this Xn multiples and variables constructors, than making all the possible combinations in my Y class: otherwise i would have to create as constructors as the combination of all Xn constructors (at least i would have to duplicate each constructor of Xn) also making these Y constructors more sensible to the change of any Xn constructor. What would you advice in such cases?

  9. mrjayarajj Avatar

    What do you mean by ? Avoid creating sub classes and if you do sub class interface or abstract class

    any example please

  10. mrjayarajj Avatar

    What is the different between expert and creator pattern ?

    In expert you said

    if object A is going to instantiate object B, it must have the info needed to create it.

    which means

    Object A has all the data needed to instantiate object B

    which you have said in creator pattern. both are similar, i couldn’t understand the difference.

  11. Alley00Cat Avatar

    VERY useful, well produced. I reviewed all of these for my Software Engineering exam.

  12. Het Shah Avatar

    I have a question that how GRASP patters are related to the sequence diagrams ? Thank you for such an amazing video…

  13. Justin Smith Avatar

    Love it. Subscribed.

  14. Noorshaheen Noorudheen Avatar

    Love your videos for many things
    1. Right pace : Speed is nor fast nor slow
    2. Right content and Self contained
    3. Right on target: No un wanted history or blah blah.

    A small recommendation it would good if you avoid using "new" as prefix to your variables as it can lead to confusion.

    Thanks Much,
    Noor

  15. asafel Avatar

    love your vids!

  16. infamousentnyc Avatar

    So it seems like programming is 75% planning 25% programming would that be correct?

  17. Frud Avatar

    This is great. Thank you so much! 

  18. Felixo Avatar

    Thankful student! 🙂

  19. Julius Luo Avatar

    Thank you. Help me a lot in understanding… Keep up the good work

  20. Derek Banas Avatar

    It is an insane amount of information crammed into 1 20 minute video. Watching it is pretty much reading 100+ pages in 20 minutes. Stick with it and you'll get it 🙂

  21. aysikl Avatar

    even if majority, plz ignore the ppl saying 'dont copy paste' – to me it helps spot that it's basically the same stuff just minor differences – OR that it actually is the same stuff and that time can be saved in cases like .. whenever u c&p ..
    btw this is a really mean tutorial .. start is anyway.. those charts .. ugh.. but, cool pro like stuff… hi5 … well hi5 tomorrow when I have strength to move again… so tired… 🙂

  22. Derek Banas Avatar

    Cohesion & Coupling is used as a measure of how much different classes depend upon each other. Can one class be changed without breaking the other. You want to always write code that is flexible and doesn't break when you make changes. OOP modules systems based on treating everything as an real world object with attributes and capabilities. FOD bases everything around just functions. OOD is covered in depth in this tutorial and in my UML and refactoring tutorials

  23. Jatin Bhardwaj Avatar

    hey derek thnks you for this tutorial but i have certains doubts in these topcs plss rply ASAP
    Explain the term

    1.Cohesion & Coupling,
    2. Classification of Cohesiveness & Coupling,
    3. Layered arrangement of modules,
    4. Function Oriented Design,
    5. Object Oriented Design
    thnks your 1nce again

  24. Derek Banas Avatar

    Association : class contains a reference to another class "has a"
    Composition : class is a container for other classes "part of" The contained normally can't exist unless the container does

  25. jimish shah Avatar

    Pleae can you give example for Association and Composition as you gave about Dependence, may be in code sense.

Leave a Reply

Your email address will not be published. Required fields are marked *