Understanding Builder Patterns from Scratch | Low Level Design | OOPS | Design Pattern | Java
HTML-код
- Опубликовано: 8 июл 2024
- 0:00 - Problem we face without Builder Pattern
18:25 - Introduction to Builder Pattern
33:28 - Builder Pattern Code
🔴 Connect with me on Instagram - / code.blooded.voyager and ask me doubts 1:1. Would try to reply to each one of you.
🔴 Join My Telegram Channel for Placement Updates and attend my Free Live Classes on DS Algo - telegram.me/riddhi_dutta
🔴 Connect with me on LinkedIn - / riddhi-dutta
🔴Graph Placement Series From Scratch - • Graphs - The Ultimate ...
🔴 Link to my TopicWise SDE Sheets Playlist : • Trees SDE Coding Probl...
Tags
#designpatterns #builderpattern #lld #oops #java
Video acha laga to krpiya comment kare.🙂
Was it an ipad you are using?
If it was,then what is the model?
👏👏👏 What an explanation! Don't know why this video couldn't appear in my RUclips search results when I searched for a builder design pattern.
holy shit! such a great video. Keep going on with this series man. I've also watched your graph playlist, it was great.Most of the design pattern stuff over the internet never really explains the "WHY" for the pattern. But you always make sure that you focus on the "WHY" a lot and its so great. I've seen the same in graph series when you explained dial's algo before going to djikstra.Thanks for this.
Much needed, thanks for this series.✨🎊
Great Video! Problems solved and how it is solved in a simple way.
Excellent!! Understood builder design pattern clearly. 😊
I always think about learning design patterns but no one is explaining the real problem of when to use which design patterns.
Recently, I found your channel on RUclips and learning things.
Love the way you present the content and please keep adding the other design patterns & LLD things.
Please create such good content. Keep doing it !!. Thanks a lot.
Excellent! Humble request to add more videos in this series
Your explanation is simply awesome! I've been using this pattern with the @Builder annotation for quite a while, but your detailed explanation helped me truly understand its exact purpose and the need for it, what is going in the background.
Thanks for Clear explanation ❤
36 awesome minutes. Thank you very much.
Please sir don't stop this series. Let it grow more n more. Very few people create videos on design patterns.
amazing explanation riddhi da. I just started studying LLD and design patterns. feeling lucky to have started it from the right place!
Thank you so much sir for starting with this very important important topic. You really listen to the masses need!! Keep up the good work sir!!
Thank you
Thank you starting a fully unique playlist.please carry on.
Thank you. Means a lot.
Thanks riddhi
nice video Sir. helpful for dsa freshers new to system design.
Please continue the playlist in the same manner: intuition + explanation
thank you so much bhaiya!!!!
Really loved this video ❤️ and it's very informative. Waiting for next video.....
Dropping tomorrow 💯
I have never seen this much explanation . Thank you bro , want more videos
Can you please create a video What are the skills we need to develop to become good developer?
Good video. I have a doubt. If a new client comes and asks for some extra methods/attributes which are not there in our Dog class, we do not try to modify the Dog class as this is violating SOLID principle(Open closed principle to be precise).The Open-Closed Principle requires that classes should be open for extension and closed to modification. So as done in the video is modifying the already defined Dog class a good thing to do ??
very good video..cleared my concept on builder design pattern and many small things which I see in production code and wonder why done like this. Can you please share the code in description that would be really helful.
36 min dekh ke laga kon dekhe lekin kya mast video hai har ek cheez samajh aaya and now I am going to watch whole playlist
Thank you for making this video
Means a lot.
Hi Riddhi, can we declare an enum to hold gender values? If yes, how will it be advantageous?
great.. will there be full lld playlist?
The video was so worth it
I am seeing this and able to appreciate my work server code repo
Sarey design patterns cover kariyega riddhi bhai, just awesome explaination..Looking forward to learn them
Thank you ❤️
please continue this series !
I understand you are busy , but can we know when this series will continued
sir, your explanation is too good. why don't you share the code?
Very helpful 👍
Love from UEMK
❤️💯
Hi. Thanks for the great lecture.
Pls upload the code😊
badhiyan padhaya bhai tumne... more power to you..
Thank you
why are you not using intellij IDEA?
Can we expect all the design patterns in this series??
Please cover all the design pattern
Hi , I have one question.
1) What if we want to change the Dog Name again after the Dog is created?
we should expose Dog's setName method to client - ( is this correct )
anyone please clarify it.
I had a few doubts:
1. For some developers, the object of dog class contains extra attributes which are not needed by them and is set to null. Is this an acceptable practice to have such classes with extra attributes ?
2. Is this pattern anyway helpful for languages which support default keyword arguments in constructors (eg. Python) ?
3. Shouldn't a Multiple Inheritance solve the problem better, as the client should inherit only the classes which contain the method that are needed, and so new class would have only those attributes which are needed by client (nothing extra) ?
1. I think it should be fine. One use case which I can currently think of is while writing unit test cases when you want to test a particular functionality and don't want your object to be populated by data , irrelevant to the test case.
2. you can use default parameters. I think it's there in java as well using ellipsis. But still you have to enforce the client to remember the order. And it is also not backward compatible as I mentioned. To top it all off , it doesnt help in code readability when , you pass so many parameters inside the constructor.
3. Multiple inheritance is not supported in java.
Hope I was able to clarify your doubts
@@rite2riddhifor the second question:- there is a concept called named argument by which u can pass the argument in any order into a function, so basically if a constructor has a default parameter value then we can achieve all possible combinations of constructor by using name argument.
@@obsessiveDreamer right.
Nice
Thanks
Q. How this Builder pattern code implementing immutability of gender attribute ?
A. Now you can define set method inside Dog class directly for the attribute you wish to update in future. But for email attribute which we want to keep immutable don't define setEmail method inside Dog class for email attributes.
So once Builder object is constructed now its in Dog class hands to provide client with the set method for selected attribute
I hope this understanding is correct
I didnt understand one thing in builder pattern. What if we need to add another attribute to the static builder class like color of dog? Do we need to modify the static class? How will we implement it?
We need to add new attribute both to dog & builder class and create setter & getter of new attribute in builder class
@@girunalaspurthinaveli3121 Yeah but won't it violate the open closed principle
code link pls?
Waoo Riddhi Bhaiya...LLD shuru kar diya. Thanks for this. Aur bhaiya Graph ka series khatam hogya kya ya kuch aur questions agey add hongey ?
add honge . topological sort baki hai
@@rite2riddhi Ohkay bhaiya. Thanks for quick response.
Can you share the code too?
DogBuilder is a static class.
Then why are we using it as DogBuilder().setGender(“Male”).
Shouldn’t it be DogBuilder.setGender(“Male”)?
SetGender() is not static thats why😅
please complete the series
Recently I watch your video posted on
@technical sunega
At times I thaugh I was watching striver's videos xd
Sir please make more videos in LLD and HLD
From Jan
@@rite2riddhi thanks sir
Bruno might identify as a female. You never know.
Just use lombok , it will save you a ton of time , you can thanks me later.................
I know , it helps in getters and setters. But don't want to confuse people with it and keep things simple. Thanks for the suggestion though