System Design Full Course Build Tinder | Dating Site | System Design
Build Tinder | Dating Site | System Design Transcript and Lesson Notes
حن جی تو کرس start welcome back core to our Landesregierung series OR today's lecture is going to catch up或 because i am the hizo the right so jump fatapathy Chang Bean or个 integrate Ond یہ leche hai sensor kan erste pero tot lo 1000 scripture 0 немного apo a neBut you need to take
Quick Summary
حن جی تو کرس start welcome back core to our Landesregierung series OR today's lecture is going to catch up或 because i am the hizo the right so jump fatapathy Chang Bean or个 integrate Ond یہ leche hai sensor kan erste pero tot lo 1000 scripture 0 немного apo a neBut you need to take
Key Takeaways
- Review the core idea: حن جی تو کرس start welcome back core to our Landesregierung series OR today's lecture is going to catch up或 because i am the hizo the right so jump fatapathy Chang Bean
- Understand how System Design fits into Build Tinder | Dating Site | System Design.
- Understand how Low Level Design fits into Build Tinder | Dating Site | System Design.
- Understand how High level Design fits into Build Tinder | Dating Site | System Design.
- Understand how System Design for Beginner fits into Build Tinder | Dating Site | System Design.
Key Concepts
Full Transcript
حن جی تو کرس start welcome back core to our Landesregierung series OR today's lecture is going to catch up或 because i am the hizo the right so jump fatapathy Chang Bean or个 integrate Ond یہ leche hai sensor kan erste pero tot lo 1000 scripture 0 немного apo a neBut you need to take care of your requirements. But don't worry, there are many requirements. So there are small requirements for you. This LLD is very simple as well.
Yes, there are many objects that we will make. But the interaction between them will be simple. So let's take a look at the requirements. Now, what is basic requirements of some dating applications?
User can swipe left or right to a profile. If you go into some dating application, then you can swipe left or left to any profile. Apart from that, you can set your profiles. Like your name, bio, interest, hobbies.
You can add and remove them. User can set his or her own preferences. What can we keep in preferences? We can keep a user in the gender.
We can store all the differences in the hobbies. After that, once there is a match, they can chat in a chat room. So we will integrate the chat room feature. If there is a match, a user and a user.
Then they can chat in chat room. Apart from that, the user can see all the profile near the location. So if you are standing at a location, then let's say 5 km in the distance, you can see all the profiles. So there is an application in which you can select within a few kilometers of your location.
There are all the users who can see you. And there is also one thing. Nearby can be based on different strategy. Now, what is the nearby strategy?
You can see that the distance formula is calculated by the distance formula. We can integrate it tomorrow. We will not make it now because we have only one thing. The person said that he should be scalable.
We can integrate it tomorrow. So you can be in the nearby formula. You can find some validations. Some users are blocked.
We will open it. We will integrate new features. We will see how to make it. We should also send notifications.
Users should be notified whenever there is a match and receive a new message. If someone gets a new message or a new message, then they should also have a notification. And our last requirement is user matching should be based on several factors. So if you are doing a match in two users, both of them are swiping the right side.
So they should also have a matching score. Because they get so many requirements and they get so much interest. On the other hand, they will determine the score. So the more good score and the more the mapping will be, the more the mapping will be.
So you can match the interest. You can match the location. We can integrate it. We can also make it scalable.
So all these features are going to integrate in our application. We have not written a non-functional requirement. You know that it is always the same. You have to keep your system scalable.
Use design principles. Use a loosely coupled one. So once we do it, we will see a happy flow. And then we will make the objects and then we will understand the entire architecture.
So let's start with our happy flow. What will happen in the happy flow? We have one user. It will come on our application.
It will have the same profile. There will be a profile of the person who will have the profile picture, the bio, the right. What else can happen on the profile? Let's write the interest.
It has the interest in its gender. It has the same location. It is not interested. It has to see other users.
There will be many images of different users. The ones who can swipe left, can swipe right. So one will have the flow. And these two will have the flow.
And once if a user gets a match, from the mappings course, then they will enable a chat room. And they can talk to you in the user. The notification will also be used. So we will have to integrate the notification.
And this is our knowledge. Chat room. The basic one is a happy flow. There is no happy flow in it.
We have to integrate the application of a user. We can show the profile of the user. This user can show multiple user. If you swipe left, you can swipe right.
Once the swipe is matched, you can chat in chat room. And the notification user can chat. So this is our small happy flow. Now we will integrate it.
When we start an LLD interview, we will start the question. So remember we have discussed this. We can solve it in two ways. Here we use our concy, bottom up approach.
And here we use our top down approach. Now, as far as we have solved the question, we have solved the bottom up approach. If you know, in this particular question, we will use the top down approach. Now you ask why.
How do we know that we should have top down in this question? Look, this is not a right and wrong answer. Now you can go to bottom up with this question. But the top down approach, I said top down approach, if you want a review, first we create big objects.
And then create small objects inside them. So what is the big object related to it? The one with which you have a hair relationship. Then we draw it.
Now the question is, why we are going to the top down approach? In this question, we have to create small objects. So if you go to the requirements, then we have to create small objects. Preferences, user profile, user object, right, matchmaking algorithms, many small objects, messages, chat rooms, so many small objects.
So if we create different objects in a different way, then we might be confused about how to integrate them. So we will do a big object first. And we will see the object in which we need to create small objects. And then we will create small objects.
So this is the practice. You know that if you want to create small objects, then you can think that using a top down approach, I will create a big object. And then we will create small objects inside them. And on the other hand, we thought that we will create small objects and then we will integrate them and create a big object.
Right? Again, depends on how you want to go with this flow. It is not like you will use a top down approach. You can go with the bottom up.
But I think that in the top down, you will not understand the topic. In this particular question. But in the top up, the bottom up approach is always out. So with this, now we will jump into our UML diagram.
So we have created many small objects here. And if we go back to our requirements again and again, then we know that we need to integrate these requirements. First of all, the interesting requirements we have created and we have already studied them. So we will integrate them.
Which is, user should get notified when there is a match or receive a new message. So what does it mean? We have to make a notification server and you will get the notification to make a constant design pattern. Observer pattern.
So let's start with an observer pattern and send a notification system. Then we will create other objects. Okay? Let's start with the first one.
Now let's do one thing. You will get the observable design pattern. You will get it from the bottom up. You have an observable.
Right? We have some functions. Add, remove, and notify. Right?
If we create an eye observable, we make an eye observable. We make an eye observable. We make an eye observable. We make an eye observable.
We make an eye observable. We jump from the bottom up. We make an eye observable. Let's say, notification observable.
Notification service. You understand that this is an eye observable. Why is it called service? It is the work of the user.
Send the notification. Observer will get a bit wrong here. Okay? So we have to name this name.
Notification service. This is an eye observable. Basically, you move from the bottom to the top to bottom so you can shout out to Google 써 doll to. Google 써 doll to us.
While doing this, we will start些 checks. Let's begin. We will open a bubblebox with an eye guessing machine. We will use the word its name to make an eye observable.
It is given between便便便便便便便便便便便便 attackers. This is a symptomatic milestone to youngsters. This is trying to fix the visible honoring facilities that I could use. نوبرز ٹھیک چیز ہو گئی اب ہم نے کہتا اسم ارپس کون کنسی میثر کرنے والے سپ سے پہلے تو اوبس لیکھ مدھڈ ہوگا ایڈ یعڈ یعب کو پتایئے ایک اوبسرور لیتا ہوگا ٹھیک ہے اور ایک اوزر کی ایڈ لیتا ہوگا ایڈ اوبس کو اس میک میں دال لیتا ہوگا اب دیکھو اگر ہم چاہتے تو ہم اس پورے کے پورے ایک کلم کیا کرتے اپنے نوطفیقیشن اوبسرورز بنالیتا ہے اس کا نام ہم نام رکتے ہیں نوطفیقیشن اوبسرور ٹھیک ہے تو اوب نوطفیقیشن اوبسرور کیو کی ایک اوبسرور ہے اس کے پاس ایک میثر ہوگا you know that update تیگ کرتا ہوگا لیتا ہوگا لیتا ہوں ایک میثج لیتا ہوگا ٹھیک چیز اس کو یہاں پیم اسے اوپسٹیکلیر کرنے اس کی میک سب کلاز بناغا کیو کی اوبسرورز کوئی طرح کی بھی ہو سکتے آج صرف ایک اوبسرور ہے کلکوں میں سے لوگ بھی کر راپا ہے تو لوگر بھی ایک اوبسروروں نا چی رائٹ کلکو اگر ہم ایک ایک ایمیثج کو لیت سے ایک ایوینٹ کے طروب بھیجنے تو ہم ایوینٹ بھی ایک اوبسروروں نا چی ہے وگرہ بگرہ ابھی ہم ایسٹرگ میثج میں نے کیو لیئے دیکھو ہوتا کیا ہوگا جب بھی اس کا نوطفائی میثج یا نوطفائی all-method call ہو تو ہوتا ہوگا یہ اپڑید میثج call کرتا ہوگا کسی بھی observer کا اور اس کو ایک message provide کرتا ہوگا اس کے ایسٹر میں تو جسی update کو message ملتا ہوگا وہ اس message کو print کرتے تو ہوتا ہے یوزر کو دے دے دے دے دے دے دے دے دے دے دے دے دے دے دے دے دے دے دے دے دے دے دے دے دے دے دے دے دے دے سمپل اب میں کیا کرتا ہوں اس کا ایک sorry اس کا ایک concrete-type بنالیتا ہوگا جس کا نام ہوگا let's say user notification observer ٹھیک ہے اپڑا نام ہوگا but ٹھیک ہے میں نے یہ بھی بنالی ہے اس کے پاس بھی obviously same update methoda جہے گا اور وہ کیا کرے گا اس message کو لے گا اور اسے print کرتا ہوگا یہ دیگا یہ ہے اور یہ اپڑا نام و سنگ اب نام اب نام اب اب اب اب اب اب اب اب اب اب اب اب اب اب اب اب اب تو یہاں جایاں گا, ترائیڈ یہاں تم نے سب کچھ پڑھا لے پڑھایا ہے اب فتح فٹیک کام کرتے ہیں اب اپنی main جو کلاس ہیں وہ user class ہے ہم اس کو بنالے تھے لیکن یہاں تم top down approach کر رہے تو سب سے بڑی جو کلاس ہے user class ہم اس کی درف چلتے ہیں اور اس کو بنانا شروع کرتے ہیں اور دیکھتے ہمیں اس میں کیاکہ چیزوں کی ضرط پڑھی رہی گئے تو یہ بہت بڑی کلاس بننے والی again کیاکھ مینت لاتے تو اس کو میں بڑا سپیسلے لے تھاں چاہلوں اب دیکھتے ہیں کہ یہ کئی کیاکہ چیزے ہوتی ہوگی اور ہمیں کیاکہ چیزے چیزے چیزے چیزے ہوں گی سب سے پہلے اگر ہمیں نوٹیفکیشن بھیج نہیں ہے تو یہ اپنی نوٹیفکیشن کا پورا کا بورا سرویس تو بنا لیا پر اس کو user کے پاس انٹیگریٹ کرنا ہوگا یعنی کی user should has a notification observer کون سا نوٹیفکیشن observer ہوگا user کے پاس آپ کو پتای یہ user notification observer ہے نا تو سب سے پہلے اس کے ایک réfرنس پاس کر دے دے ہیں Let's say notification observer and no OK اچھا اس کے لابا میوسر کے اندر کیاکہ چیزے دیکھتا ہے ہم نے ایک notification observer اس کو دے دیا ہم نے اس کو ایک user ID دے دی چلو ایک بر اپنے اس پے واپس چلتے ہیں OK اپنی دیکھتے ہیں اور دیکھتے ہیں کہ user کے پاس user can set his or her own preferences user can set up his or her own profile تو اس کے پاس اپنے کھتے ہیں ایک profile ہوتی ہوگی آپ نے preference ہوتی ہوگی تو ہم ان کے objects بنالیتے ہیں OK تو میں نے کیاکہ user کے پاس کیا ہوتا ہوگا سب سے پہلے user کا user profile ہوتی ہوگی OK Let's say a symbol to be profile اور اسی طرح سے user to be a user preferences ہوتی ہوگی OK اسے a symbol to be preference تو میں یہ سب بنالیتے ہیں تو کیوں کی top down approach تو ہم نے پہلے دیکھلیر کر دیکھتے کیوں کیاکہ کیاکہ فیرم ان کو بنالی ہے تو سب سے پہلے ہم کیا بنالی Let's say user profile ہم یہاں بنالیتے ہیں user profile OK اب user profile میں کیاکہ چیکھتے ہیں بیسک بیسک چیکھتے ہیں OK بلکل موڑکل اس کی طرف اب user profile میں اس کا ناما جاتا ہوگا تو اس کا name رکھلے تھے ہیں اس کی let's say user's age جاتا ہوتی ہوگی اس کی age رکھلے تھے OK user's let's say gender را جاتا ہوگا اب gender بھی ہمیں اپجیک لیرے Gender یا پیک asa ena m object لیسکتے ہیں تو ہم اس کو بھی ہمیں کرییٹ کر سکتے ہیں so gender our e-na m جائے گا جس میں 2 value ہو سکتے ہیں Let's say male or female OK ہم نے اس کو open رکھا ہے کہ کلگوں میں اگر other's یا اور بھی کچھ دلنا چاہیں تو دل سکتے ہیں تو یہاں پیم کہتے ہیں user profile hasa gender OK user کے پاس name age gender user کے پاس ہو سکتے ہیں اپنے interest OK کچھ interest کی وہ کیا اسے پسندہ کرنا hobbies کیا ہے اس کی so list of interest رکھلے تھے ہیں اور interest کو بھی let's say ہمیں object بنالے تھے ہیں interest again top down approach ہے اگر انترسٹھا ہم نے اس کو declear کر دیا فیر اس interest object کو ہمیں بنالے تھے let's say here we make interest اب interest object ہے اس کے پاس کیا ہوتا ہوں گa let's say interest میں اس interest کا naaahm hootahoga let's say name اور let's say اس کی category ہوتے ہوگa ki وہ کس category میں ہاتا ہے right тکے تو name اور category again, ایک ہیزر Relation Shipage پس کے ساتھ بھی ہو گیا ki user hasa gender user profile hasa gender and user profile hasa interest تو یہ یہ ہاتاں آپ کو sama جا گیا ہوگa тکے ہم نے کیا کیا بنالیا اس کا name age gender اور اس کے interest بھی رکھلے OK اور اس کے لاباں اس کے لابا ہم user میں رکھسکتے ہیں اس کی بائوں کو right تو let's say string بائوں تو user نے اپنے بارے میں ہوں کوشکہ ہوں گa right تو اس کے لابا user کے پاس vector of let's say string اس کی photos ay let's say pictures آپ اپنی جو بھی آپ کی data application اس میں آپ اپنی bultible pictures upload کرتے ہوگa ہے تو اس میں vector of string string میں store کیوں گa right تو اس کی بائوں بھی لے لی pictures بھی لے لیا اس کے لابا ہوں اور کچھ رہ گیا ہے حا سب سے ضروری ہمارے پاس user کے ایک location بھی ہوں بھی ہوں اور let's say location بھی ایک object ہے اللہ کیا اب اس کو ابن اب اس کو object ٹیٹھ کیا اگر اب اس کو object ٹیٹھ نہیں کرتے تو میں اگر لگا لگا لگا ٹیٹھ لگا لگا لگا ٹیٹھ سے ایک بیچھٹھ لگوکیشن اور کچھ نہیں بچھتا اب ہم only a method لیٹھ سے display جو user کی پوری کی پری پروفائل کو display کرواتے گا تو یہ ہو گیا ہمارے پاس user کی پری پری پروفائل ہم نے کیا بنا لے گے کو کچھ رہے بھی بنا لے ہم یہاں بھی تو ہم نے کہتا user کیا بنا لیا location کیا اب location اب اس کو اب اس کو لیٹھ تیڈ لٹ ایک ہوتا ہو گا دبل لٹ سے longitude long اور دیکھو ایک مدھرام رکسکتے لٹ سے distance in kilometer ٹیٹھ یہ کرے گا یہ لٹ سے ایک اور location کا object ل ٹیٹھ یعنی کی اس کے پاس خود گے کررافرنس ہوتا ہو گا ٹیٹھ تو یہ location کا object ل ٹ اور نکالتا ہو گا کہ اس location کا my particular location سے کیا دستنسے یعنی کی جو اس کے پاس اپنا latitude اور یہ جو ایک location پاس کی ہے اس کا distance اِن دور میں distance کیتنا ہے تو یہ اس سے کیا دا ہو گا کہ نکال پہنگے کی ایک user کے ایران لیک سے 5km کے دائرے میں اور کون کون سے user profiles جیس ہم show up کرسکتے ہیں تو اگئی یہ بھی درگتے ہیں user profile has location ابھی کی ابھی ہماری ہر گی ہے تو user کے پاس profile کے پاس انٹرسٹ ہے جندر ہے اور اس کے پاس انٹرسٹ ہے یہ جو my user اس کے پاس has a relationship آجہ گا بھی user profile ابھی کون سے has a ہو گا ابھی ہماری ہماری ایک ایک ایک ایک ایک ایک ایک ایک ایک ایک ایک ایک ایک ایک ایک ایک ایک ایک ایک ایک ایک и ایک ایک ایک ایک ایک ایک تو دیکھتے پریفرنس میں کیا گیا ہوسکتے ہیں تو ہم کیا رکسکتے ہیں لیٹھ سے ہم رکسکتے ہیں ایک رکسکتے ہیں میلمم تبل نہیں سواری انڈیچر میں لیٹھ سے ہم رکسکتے ہیں میلمم اج کی اسے جو دوسرے دوسرے ایوضر چیچہ وہ لڑگی ہوئے لڑکا ہو اپنے لوقتشن میں اس کی میلمم اج کیا ہونے چیچے ہوئے اسی طرح سے ہم ایک میکسیمم اج کو سٹھپ کر سکتے ہیں میکسیمم دستنس کیوں سے کتنی دور تک کی پروفائلس کو دیکھنا ہے تو اپنے لیٹھ سے ہم اج ہو گئی میکسیمم دستنس ہو گئے ہے نا اس کے لابا لٹسے اس کے پاس ایک لست جو سکتے ہیں وقتر آف ترنگ اور یہ ہماری ہو سکتے ہیں انٹرست کی لائٹ اسے جو پروفائلس میں انٹرست ہے اون کا انٹرست کی اس کی σٹیزوں میں ہونہ چیچے لائٹسے ایک بندا ہے کیوں کو جٹرگ نہیں ہو گئی یہ ہم رکسکتے ہیں آپ اس کو جینڈر جینڈر کو اپجیک پاس کر سکتے ہیں تو یہ بتاگئا کیوں کو جینڈرز میں انٹرستے ہے یعنی کی اس کے پاس ایوں کو جینڈر کا ایک ریφرنس ہو گئے وہاں اور مجھے لگتا ہے یہ ایک نا کافئے اس کے لابا لٹسے اس میں بس کچھ بچے ہوا گیٹرسن سیٹرس رکسکتے ہیں جیینڈر سے لگنا ہوں میں ہوا بھی تو یہ user کی preference ۔ ہم نے کیا رکھا user کی preference ۔ ہم نے minimum age, maximum age ki ۔ اس کو جو profiles میں interest ۔ ان کی minimum maximum age ۔ کیا ہونی چیئے, ان کا maximum distance ۔ کیا ہونچھے یہ, ان کا interest ۔ اور ان کا, اس کا وہ کو ان کوز a gender ۔ میں interest ۔ اور واقعی تو getters and shatters ۔ اب اس کو بھی ہم draw ۔ کر لے تھے, user also has a user profile ۔ chickam ۔ اب again یہ والا بھی جو has a relationship ۔ یہ بھی آپ کے سب سے strong ۔ کو position ۔ ہونچھے نہیں ہونچھے۔ کیا پرفرنسیز بھی, ایک لے تو, ایک لیے نہیں ہونچھے نہیں ہونچھے۔ یہ بھی ایک strong ۔ کو position ۔ تو user کے پاس آپ کیا کیا آگیا, اس کے پاس خودکہ اوپسر بے بل آگیا, اس کی user ID ۔ اس کی profile ۔ اور اس کی preference ۔ اب ہم نے our design ۔ وہ کوئی اس طرح کا دیکھ رہے.
اب ہم دیکھتے ہیں, ہم user میں اور کیا کیا چیزوں کو introduce ۔ تو ایک برپ نے دیکوارمنٹس پے باپس چلتے ہیں, ہماری رکوارمنٹس کیس آپ سے, ہم نے اس ویلہ پاٹ کو تھیل کر لیا, کی user get notified when ۔ باپس پوریتر سے انڈل گیا, برہنے گنوٹفیگیشن سرویس تو بنا لی, کی نوٹفیگیشن جائے گی کیا سے, کیا سے, اس کے لابا ہم نے اس کی profile ۔ اس کی preference ۔ تو اپنی setup profile ۔ اب ہم نے preference ۔ کو setup ۔ اور یہ بھی ہم نے کر لیا تھا. اب ہم نے ایک لیے نہیں ہونچھے۔ اب ہم کرتے ہیں, کی user جو ہے, left-right کو swipe بھی کرتے ہیں, کسی پی profile کو left-right swipe کرتے ہیں, تو اس سے لیٹر چیزے لکھ دیا, تو اس سے لیٹر ہم چیزے لکھ دیا, اپنی user باہلے ۔ class میں, تو user کے پاس کیا ہوتا ہوتا ہوں گا, لیکن حیشٹری مانٹین رکھتا ہوں گا, user کی اس سے کنکل لوگوں کو left-swip کیا, کنکل لوگوں کو right-swip کیا ہے, تو وہ history مگہاں میں انٹین کرتے ہیں, ہم ایک map بنا سکتے ہیں, لیکن of string, swip history, جہاں پی جو swip history ہے, وہ خود ایک اینہ مزکتے ہیں, اور اس کو ہم لیکن نام دیتے ہیں, صرف history. اب یہ string, swip history ہے, string میں آپ کو بتایا ہم دالتے ہیں, user کی ID, کی کن سے user کو, اس نے کن سے swip کیا ہے, left-swip کیا ہے, یا right-swip کیا ہے, تو کیوں کی swip history کے بارے میں نے بات کی, تو ہم اس کو بھی draw کر لے, لیکن سے ہم اس کو بناتے ہیں, یہاں swip history, یہ اگر ہمارا ایک ہو جائے گا اینہم, swip history نہیں, چاہلو swip history ہی نام رکھلے ہیں, یہاں our ینہم ہو جائے گا, اس کو ہم رکھلے ہیں, left-comer-right, دو ہی درکھ swip ہو سکتے ہیں, تو ہم نے اس کو left-swip رکھلے گا, اینہم, اگر این میں کو swip history پورانام دا دا چھانی لگر, اس کو ہم simple swip رکھتے ہیں, رائے تو پورے کے پوروگیت کو کہتے ہیں, تو ہم اس کا نام رکھتے ہیں, swip, تو اس کے پاس جو object ہے, وہ swip history کا نہیں ہے, اس کے پاس string comma swip object ہے, جس کا نام ہم نے رکھا ہے, history, cool, تو یہ بھی ایک ریلیشنشپ ہم draw کر لے, تو it has a swip history, تو ابھی تک ہمارے یہ سبو object's create تو ابھی تک ہمارے یہ سبو object's create ہے, اب ہم نے کہ ہمارے پاس swip ہے, تو swip history بھی آگی, اور اس کے لہا ہمارے پاس ایک method ہونا چاہی اس swip, ایک method ہونا چاہی اس swip, جو کیا لگا, جو ایک user کی ID لگا, کی کون سے user کو اس نے swip کیا اور کون سے swip کیا, یعنی کی swip coik object لے لگا, اور یہاں پاس کو define کر دے گا, تو اس کو ہم کیا کر سکتے ہیں, اس کو ہم سیدہ history میں safe بھی کر سکتے ہیں, اور یہاں پہ ہم اس کو چک بھی کر دیکھیں, کہ user نے left swip کیا ہے, or right swip کیا ہے, تو یہاں سے user swiping وقت کو بھی handle کر لے گا, so اس کے لہا ہون کون سے method ہم رکسکتے ہیں, اپنی user profile میں, تو یہاں بہت بیسک Methods جو ہمارے لٹ سے Boolean Methods ہوتے ہیں, Let's say is interested in, تو ہم یہاں پہلٹ سے کوئی user ID پاس کر دیں گے اور ہم چیک کر لے کہ وہ اس میں interested in, کیا سے چیک کر سکتے ہیں, ہم اس کی history bagel object sorry history bagel map میں, چیک کر سکتے ہیں, کہ یہ particular user ID میں user interested ہے یا نہیں ہے, جیسے کیا ہمارے میں, کر کر سکتے ہیں, ہم رکسکتے ہیں, has liked, تو یہاں پہ کی user ID کہ user ID نے اس کو like ہے یا نہیں ہے, as i has disliked, یہ سپاہاں نے Methods کام ہم سکتے ہیں, ہم یہاں پہ بھی user ID سے دیں گے, کہ user ID نے disliked ہے یا نہیں کیا ہے, has interacted with user ID اس نے اس کے ساتھ interact کیا نہیں کیا ہے, تو آپ understood, اور یہ سپاہاں نے کام ہم آتاکتے ہیں, just check کرنے کے لئے, کہ ایک user کا دوسری user کے ساتھ کیا ریلے کیا ہم اس کو like کرتے ہیں, کیا ہم اس کو disliked کیا ہم کیا ہم اس نے کر بھی اس کے ساتھ بات چیت کیا ہے, تو ہم اس کے لئے Boolean Variables رکھلے ہیں, جو کی ہم easyly, اس کے history سے نکال کر کے Answer تھی سکتے ہیں, تو ابھی میں یہ UML میں اس کو نہیں رکھ رہا, ہم اس کو code میں دیکھلیں گے, Right, تو ابھی تک ہمارہ یہ پوری کی بودی ہیرار کی بنکے سامنے آئی ہے, تو اب دیکھ سکتے ہو, ہم نے پوری کی بودی Notification vr. Part بنیا, ہم نے کی user بنیا, ہم نے اس کے interest, gender user preference user profile location اور اس کے swipe کا én ام بنا لیا, Right, چاہلو, اب ہم ایک بر دوارہ سپنے رکوارمٹs دیکھتے ہیں, اور دیکھتے ہمارہ کیا کیا ہا پاٹ ہو گیا اور کیا ہم اسے گے, تو ہم نے کیا کیا کرتے گیا, ہم نے کہا ہم نے user can left-right swipe کرتے ام نے profile پے وہ اس کے بعدم نے اس کا feature بنائلیا, hezor or on profile کو set کرتے ہو, وہ بھی بنا لیا, preference کو set کرتے ہو بھی بنا لیا, اب ہم کو بنا سکتے ہم کی وہ match کیسے کرے گا اور چیٹروں میں باچچیت کیسے کرے گا, match ہونے کے بعد بیسگلی چیٹروں میں باچچیت کیسے کرے گا, اس کم زر آباد میں مناتے ہیں, ابھی اور جو user related وہ دیکھتے ہیں, user can see all the profiles near their location, near by can be based on different strategy, تو ہمیں کیا کرنا ہے, کی بیسکلی user جب ہمیں profile open کریں, وہ ساری profile دیکھیں جو بھی اس کے locations کیاس پاس ہے, let's say, ہم نے رکھا ہے 5 km کا radius, جتنی بھی profile 5 km کا radius کیاس پاس ہے, اس کو وہ سا profile دیکھیں, تو اس کے لہم کیا کرتے ہیں, کہ ہم نے ہم نے ہمارے پاس location کو objecto ہم نے location نہ رکھا ہے, ہمیں کام کرتے ہیں, ہم مناتے ہیں, location service کو, تو یہاں بناتے ہیں, اس کو, اس کا نام ہے, location service, اب location service, کیا کریں گی, again location service, کا کام ہوگا, یہی یہاں méthod call کرنا, کی وہ, کیا کریں گی, ایک user, کے آس پاس کی profile کو نکھال کے لیکنے, تو ہم پہلے ایک چیز کر لیتے ہیں, کہ location service, hais location, obviously one to many locations, تو اب ہم دیکھنس کے بہت métھر کونسا ہو سکتے ہیں, تو دیکھیں location service, کے پاس جو métھر ہو سکتا ہے, sorry, find, nearby users, okay, تو یہاں کریں گا, کسی بھی ایک particular user ID кلا, near by users کو لے کر کیا ہے گا, تو وہ کیا کر لے گا, let's say, وہ لے گا, ایک location, alloc, okay, وہ لے گا, ایک maximum distance, okay, اور وہ list of all user, تو یہاں vector of, کہہلے تھی, all users, وہ یہاں تھی ہے, تو جتنے بھی بارے اپلکیشن میں users, وہ سب location service کے پاس اس کے پاس ایکسیسیبل ہے, right, تو وہ دیکھتا ہوگا, کہ ایک particular diary میں let's say, 5 km کے diary میں کتنے users exist کرتے ہیں, اور 5 km کے دارا کس سے اس location سے, okay, simple, یہ ہم نے, کہ ہم near by stores, Supreme and Military Manager میں بھی نکال رہے, تو کچھ سیسیسی ملٹر اگی функشنالیٹھے میں یہاں پہ کر رہے, کہ ہم کیا کر رہے, user's نکال کے لئے کیا رہے, based on the location جو ہم نے پاس کی ہے, پیرامیٹر میں, ایک میکسیمام distance, کی کتر ہیں distance تک ہمیں user چیئے, اور سارے لستف user's, تو کیوں کی یہاں پہ سارے لستف user's کی بات کی گئی ہے, تو یہاں پہ ایک حیثہ ریلیشنشے پیے والے بھی ہو جائے گا, ہے نا, کیوں کی location service کے پاس user's access ہماری حیرار کی کچھ اس طرح کی دیکھنے لگی, тکے, اب ایک کام کرتے ہم نے کہتا, یہ جو ہمارے ریکوارمٹس میں mention تھا, کی یہ جو user ہے, can see the profile of nearby location, and nearby can be based on different strategy, ہے نا, تو اس کی strategy, اس کی بھی بنانی پڑے ہمیں کو, تو یہاں پہ نا, یہاں پہنے لگی, تو ہم کیا کر سکتے ہیں, لیکسے ہم یہاں پہ ایک نیر بیش stratagy, نام کا ایک stratagy design pattern introduce کر لے, اس کا نام رکتے ہم strat, and let's say, یہاں پہنے بھی stratagy, نیر بیش stratagy, ٹکے, اس کے پاس ایکی method ہوں گا, یہی والا اچکنا ہوں گا, fine near by user, find let's say near by user, یہ بھی وہ same چیزے لیتا ہوں گا, location لیتا ہوں گا, amaximum distance, لیتا ہوں گا, and what is it, list of users, لیتا ہوں گا, اور یہاں پہنے سے declare, اور ہمارے پاس اولا گا لگترکی stratagy ہوں گی, اس میں, ایک تو ہوں گا ہوں گا, ہمارے بیشک, let's say near by, یہ سب سے basic, کیا ہوں گا, یہ نام کا نام کا نام کا نام کا نام کا نام کا نام کا نام کا نام کا نام کا نام کا نام کا اور ہم دیکھتے ہوں گا ہم نے کون ghanci چیزوں کو کر لیا ہے?
تو دیکھو, ہم نے left-right-side carry-lia تھا profile preference بھی کر لیا تھا, یہ چیٹھوں والا بھی رہگیا ہے тھی کہ اب ske lae bha ہم نے یہ بھی کر لیا ki ہم profiles کو set-carsight کر سکتے اور near-by-locations کو دیکھ سکتے ہے, ہمارے پاس near-by strategyÊ ہے, روکیشن stratagy چیز بگرا ہے ہمارے پاس, اس کے ل Bha Habe ہم نے کہاں نے پڑھڑھے گیا تو ایک تو رہ گیا کیاں میں کپنا مچ ایک چیٹروں والا پاٹ بنائیں اور ایک ہمیں منا نہے ہیں مچین گلگوریدمس تو یوزر مچینگ شوڑھی بھی بیزڈان سیVERل فیکٹرس اور سکٹرس لیکھ انٹرسٹ مچ لوکیشن مچ ایسکٹرہ تو پہلے ہم اس پے کام کرتے ہیں و لازت میں کام کریں گے پھر چیٹروں پے چکے تو اس کا مطلب یہ ہا کہ نہ ہمارے پس الگ الگ طرا کے مچینگ پھر لڑ سے ایک ٹریزی بنائیں اس میں لڑ سے ہوگا فائن مچ اور لڑ سے وہ دو ایوزر ایڈی لتا ہوگا ایوزر بن ایوزر دو اور ان کے بیچھ بیک مچنگ کلتے ہوگا اور ہمارے پس کنگریٹ مچینگ ٹریزی سو سکتی ہوگی جسے کہ آپ کو پتایا ہے ہم کرسکتے ہیں انٹرسٹ کے بیسیس پے مچ کرسکتے ہیں ہم لوکیشن کے بیسیس پے مچ کرسکتے ہیں ہم اور بھی گئی طریقوں کے بیسیس میں مچ کرسکتے ہیں لڑ سے ٹریزی اور یہ سب آپ کو پتایا ہے فائن مچ کو override کرتے ہوگی اپنی اپنی طرح تو یہ بھی کرتا ہوگا اب ایک تو ہمارے پس ہوگیا یہ والا طریق ہے جو اماثتا کرتے ہوئے آئی دے ٹریزی پر جنرلی یہ جو پر جنرلی یہ جو دیٹنگ اپلکیشنز ہوتی ہیں اس میں آپ ایک پرٹیگلر شرٹیجی کے بیسید میں مجھنے کرتے لیکن اجکل کیا ہوتا؟ اب ایک کمپلکیڈیٹس کورس نکالتے ہوگی مطلب جیسے آپ نے کیا کیا کی پہلے سپ سے پہلے مجھ کیا لوکیشن کے بیسیس پہ اگر ان کی لوکیشن میں ریہ ویلین گڑ فیرم سیکنت تنپے جائیں گے اور لڑ سے مجھ کریں گے ان کے انترسکتے ہیں اور اس کا ایک سکور آئے گا اب ابویسلی سکور اور ویری کرسکتے 100% 0% کیا پہلے کوئیسک انترس نہیں ملا اور ہوسکتا پہلے سارے انترس مل جائیں تو اس کے گرین جوگی تو لڑ سپوز امیک بیچ کی رینج مالے تھی 30% کی ہے نا اس کے بعد لڑ سے مجھ کریں گے کسی اور چیس پہلے لڑ سے پریفرنسس پیکی دونوں کے پریفرنسس کیا کیا ہے رہید اور ان تینوں کا جو فیرنالسکور آئے گا ہا مُس کو پر یہ امپلمنٹ کرنے کے لنا ہم سمپل شریتجی ایس نہیں کر سکتے ہمیں ایس کرنا پڑے گا اپنا سی اور چینوں کا ریسپونسیبلی تیزائیم پیٹن تو مجھے کریں گے ہم اگی اپنے ایک ماشتا کلس بنائیں گے پیسکلک بیس کلس بنائیں گے مجھر اور ہم الگلک سپ کلسز بی بنائیں گے same طریقے سے لڑ سے لکیشن مجھ انترسٹ اسم ام چاہلیلگلس میں رفرنسٹور کر رہے ہیں اور وہ بھی ہم ایک ہارڈ رفرنس دیں گے ہارڈ رفرنس پتل اس کو ہم اس کے ساتھ ٹائٹلی قبل کر دیں گے ہم اس کو یہ نہیں رکھیں گے دائنامکلی کلکو یہ اس کے ساتھ بھی میں چا سکتے کیوں کی کی لست میں جائے گا کی پہلے پر افرنسیز میںچھونگے پھر Sorry پہلے رہت سے لکیشن میںچھونگی چلو چلو ہم کیا کرتے ہیں ہم بنا لیتے ہم مچھر اللگواریتم ہمیں لکھا مچر چلو چلو ہم نے کیا دیسوز کیا تھا کیا اس کے پاس ایک ہمتھڈ ہوگا لیٹسے کلکو لیٹسے سکور یہ دو یوز رائیدی لتاوگا لیٹسے یوزر ہم ایسے یوزر ٹو لیٹسے یوزر ایڈی دیں اور ان کے پیچھمیک سکور نکالتا ہوگا دوول میں рیٹنگر توجا سکور کی ویلیو کو تم نے کیا کہتا ہمیں لکھا ہمیں ایک ہم لیٹسے لکیشن مچر ٹو چلکے ایک ہم لیٹسے ہمیں رہ بیسک دیتیلس بیسک دیتیلس مچر اور ہمیں اب数 کچھraction sentido 자 چام There mountain heatedی má m And & tan Can M D m D m D m و انا ستٹویک کر گے ایس کیا اور امرہ ماجینگل گوریتم ریڈی ہو گیا اب انٹرسٹینگ بات یہ ہے پتے کیا کہ ضروری نہیں ہے آپ ہر بار لکیشن مجھر دو ہو سکتے آپ لکیشن مجھر سے نہیں آپ انٹرسٹ مجھر سے شروع کرنا چاہتے ہو کہ انٹرسٹ کہے گا پہلے بیسیگڑیڈیس کو بیسیگڑیڈیس ہمس کوڑنے گا وہ انٹرسٹ کو دیکھا انٹرسٹ کنٹ کو ریٹن کر دے گا تو بیسیگڑی میں گا کر رہاں اس کیا اندراتا ہے بیسیگڑیٹیل سمجھر تو یا تو میں لکیشن دنگا فیلوکیشن بیسیگڑیڈیس کو بولے گا تو انٹرسٹ کو بولے گا انٹرسٹ بیسیگڑیڈیس کو بولے گا یا فیمسیدہ ہی صرف انٹرسٹ دیں گا اور انٹرسٹٹ بیسیگڑیڈیس کو بولے گا بیسیگ انٹرسٹ کو بولے گا اب یہاں پہ دیکھنے ایک ہونہ آپ کوئی ایس کھڑیٹر بیٹر میں پہنے گا کر رہاں پہنے دیکھنیٹر نہیں ہے کیوں کہ اس کا انٹینٹ بہت اگئے ہم اس کو دینامی قليی اب دیٹنگا رہے اور نہ ہی ہمیں گا پہنے گا ایو ایو ایو ایم لکھڑا دیکھا یا پہنے جو انٹینٹ ہے وہ سی او اروالا انٹینٹ ہے چین اف رسپونسیبیلیٹی والا تو اب جو میں نے کہا ہوں اس کو انٹی گریٹ کرتے ہیں کہ میں نے کہاہ یہ جو لکیشن مجھر بیسیگ ریٹیل مجھر اور انٹرس مجھر ہے ہم ضروری نہیں ہے لکیشن سےی ایسٹارٹ کریں ہم انٹرس سےیسٹارٹ کر سکتے ہیں ہم یہ تو سیمپل بیسیگ ریٹیل سےیسٹارٹ کر سکتے ہیں تو ان کو بنانے گیلی ہم گیلیٹیں ایک فیکٹری گریٹ کر لے اور دیپینڈیں گا بہنے اینام وہ یا تو لکیشن مجھر کا اوپجیک دے گا بیسیگ ریٹیلس کا یا انٹرس مجھر کا تو فٹافتیک فیکٹری بھی بنالے تھیں تو ہم گیلیٹیں یا ہم اپنی ایک مجھر فیکٹری بنالے تھیں لیکسے مجھر فیکٹری ٹھیکن اس کے پاس لیکسے ایکی میتھر ہو گا اس مجھر کم کیا نام رکھتے ہیں CREATE MATCHR تو لیکسے ایک مجھر ٹائپ لے گا لیکسے ٹیوائے اور اس کے بیسے سپیک مجھر ایٹن گٹھے گا یعنی کی ہے زا مجھر اب مجھر ٹائپ کیا ہوگا اگین یہ ایک ہم اینام رکھتے ہیں مجھر ٹائپ اب آپ تو اسمجھ گئے ہوگا ہم اینام کا بناتے ہیں اس کی ضرورت کہا پڑھتی ہے تو ہم ٹینت رکھ اینام رکھتے ہیں ایک تو ہم رکھتے ہیں لوکیشن یہ ایٹن گٹھے گا لوکیشن مجھر کا اوپجیکٹ ایک ہم رکھتے ہیں و یہ ایٹن گٹھے گا ہمارے انٹرس مجھر کا اوپجیکٹ تو مجھر ٹائپ اور مجھر ٹائپ ایسٹائپ مجھر ٹائپ مجھر ٹائپ جو ایٹھ کر دے گا اب یہ ہمارے پورا کا پورا ارکی ٹیکٹر ہم ہم دیکھے تو کچھ اس طرحہ گا آپ کو دیکھ رہا گا اب دیکھتے ہیں ہمارے کون کوئے فیچھر اینٹگرٹ ہوگیا اور کون زر ہے گیا تو دیکھا ہم نے میرکو لکتے اولمو سارے فیچھر انٹگرٹ کر لیا ایک سب دیس فیچھر کی وزر زر زر مجھ دیکھا ان چیٹھی نا چیٹروم تو مراسف چیٹروم بنانا رہے گیا تو فتح فتح ام چیٹروم اور مجھسجز کو بنانا لے اور دیکھتے ہیں کہ وہ ہمارے پورے کے پورے سیسٹم کے ساتھ کیسے آپ پس میں انٹگرٹ ہوتے ہیں تکے تو ابھی تو مراسسٹم ایتا دیکھرے ایک ہیزر لیشنشے پر ہے گیا ہم نے کہتا کلکلٹ سکور کے پاس یوزر بن یوزر ٹکر افرن سے یعنی کی کلکلٹ سکور نامک میتھڈ کے پاس یعنی کی میچر کے پاس ہمارے میچر کے پاس ایک ہیزر لیشنشے پھونہ چیئے وید یوزر آلسو اگی ان دیگرام بہت کندہ بنٹر پر اگی ان اس کا امکلین دیگرام تو بعدم دیکھی لیں گے تو ایک یہ بھی ہونہ چیئے اگی اب ہمارے چیٹروم بنانگے گیا تھا تو یہاں بنالے تھا چیٹروم کو جو ہمار پاس جگا ہے بلے ٹکے تو چیٹروم اب ایک چیٹروم کیا ہوتا ہے چیٹروم میں دو ایوزر اپس میں آکے چیٹ کر سکتے تو سب سے پہلے ہم کیا کرلیں گے اس کی ایک ایڈی لکلیں گے چیٹروم ایڈی اسی ہم سٹور کرلیں گے اب چیٹروم میں دو ایوزر اپس میں بات کر سکتے اب چاہیں تو ہم ان کو ایوزر بن ایوزر 2 کر کر کر کر کر کر کر کر پر لیٹ سے کل کو ہم اسے اور ایک سٹین کر بھی کی ملٹیبل ایوزر ساپس میں گروپ میں بات کریں رہید تو اس کے لہم یہ بھی کے لئے vector of let's say string رکھلیں گے let's say user IDs یا پر افرڑ ایوزر ID's جو بھی بیسکلی اپاٹیسیپنٹ سکلیں گے تو ہم اس کا نام PartyCipants user PartyCipants ID's PID's جو بھی اس گروپ کے PartyCipants ان کی ID's تو ایک تو ہم یہ اشتور کر کر لے تیک ہے اس کے لہا ہماری پاس کے اوزرکتے vector of message ہو سکتے message خودے کلاسے تیک ہے ہم دیکھلیں اس کا نام رکھلیں تیک ہے message یہ جس یہ جو بہت زرے message دائیں گے یا نا بہت اس میں мلٹیبل user سو سکتے ان کے پرفة ID's رکھلیں اس Chad Room کی ہم نے کی ID ڑکلی ۔ اس کے لابا لیٹسپیک میںθہ ہو سکتے ہیں Show All Message or Show Complete Chat کچھ بھی اسے رکھا ہم کوئی Method ڑکسکتے ہیں جو کیا کرے گا آپ کو پتایا ہے اس پورے کے بھورے Message ڑکھا EXTEND کر کرکھے رکھے گا اس کے لابا آپ کو پتایا ہے ہم اس میں CRUD operation ڑے سکتے ہیں جسے کہ Let's say Add Message تم کوئی Message لیلیں گے اور اس List MAD کر دیں گے اس کے لابا آپ کو پتایا ہے ہم ریموów Message & Delete Message عبشان دے سکتے ہیں وگرہ وگرہ اب آپ نے چیٹروم بنالیا تو ہم ایک Message بھی بنالیتے ہیں کی ایک Message Object میں کی آو تو ہوگا تو Message میں Message میں بہتے سمپل ٹین چید رکھتے ہیں Let's say I'm a Let's say I'm a Let's say Sender ID کس نے Message بھیجا اس کا رکھلے تھی ہے Content کیا ہے String Content اور Let's say I'm a Let's say Time کیس Time وہ Message بھیجا گیا اب ہم اپنے پتا ہی ہے کی چیٹروم has one too many messages تو یہ Relationship ہو گیا اور ہم ارى چیٹروم بھی بنگے ریڈی ہو گیا کیا ہے اب ہم ارى پورا کا پورا آر کی ٹیکٹر اگر ام اس کو اچھے سے زومین کر دے زومہ اٹھ کر دے کوئی اس طرح کر دے گے کیا ہے اس کے اندرہم نے سارے کے سارے وہ Feature Centigrade already done لیکن جس کے بارے میں میں بات کی تھی اب اگر این ہم ارى ایک ایک ایک سارے کے یہ جو ہمیں شاہم ایک اریکسٹریٹر کلاظ بنادتی ہیں کیا ہے جس کا نام ہو سکتا ہے ہماری Dateing App اب اس کو اپ کچھ点 اس کے סپیسک نام بھی رکسکتے ہو آپ اس کے نام ٹین در رکسکتے ہو بمبار رکسکتے ہو عینج رکسکتے ہو یا اب جو بھی نام چاہیں وہ رکسکتے ہو کیا ہے میں نے اس کا ایک جنڈریک نام رکھلیا Dating App اور اگین کیو کیا ہماری اریکسٹریٹر کلاظ ہے اور یہ بہت ساری اپریشنز کرتا ہوگا یہی سے بیسکل ہم کیا کرتے ہوگے Swipe کو اپریشن کرتے ہوگے تو ماریپ پسی آپ ایک métھڑوں کا Swipe یہ ایوزر ID لیتا ہوگا Swipe Type لیتا ہوگا Right اور Swipe Caction Perform کرتا ہوگا اسمیں ہمارے وہ ساری métھڑs ہوگے جو بیسکلی ہم جاتے اس پورے سبسسٹرم سے انتریک کرنے کے لیہمے چیے تو ابھی کے لہم یہ آپ ایک جنٹرک métھڑsift Swipe رکھلے بعد میں كود میں دیکھیں گے کہ ہمیں کان کون سے Method کی ضرورت ہے تو یہ ہے پورا کبھر آریکٹیکٹر UML Diagram فٹافٹیک برس کا کلین Diagram دیکھلے تو دیکھو یہ ہے پورا کبھر آریکٹیکٹر اب میں نے اس کو ایک دنم کلین لی بنایا اےHope آپ کو یہ بیٹر لگا ہواگہ دیکھنے میں تو اگی نیحاپے ساری ایوزر چیزے جو بایئے کہ ہمارے یہ پورا کبھر آنیدیشن سرویس ہوا گیا لکٹنٹی نوٹفکشن بھیجنے کے لئے چکے ہمارے پسی یوزر کلاس ہو گئی جس کے بہت ساری چیزیں اس کے پاسے کو عبزرور ہے اس کے پاسے پر افرنس کے لیشٹ ہے اس کے پاس یوزر کی προفعل ہے ٹھیک ہے لکیشن ہے اور یوزر προفعل کے پاس کیا ہے یوزر προتکہ پاس جنڈر ہے وگرہ وگرہ اب لکیشن ہمارہ جڑا ہا ہے لکیشن سربس سے ہمارے پس آلگلک لکیشن стریٹیجی ہو گئی ایک بیسی کم نے برانلی بیسی کلوکیشن стریٹیجی اور اوڑیم اس میں کئی طرح کی стریٹیجیز کو انٹی گریٹ کرسکتے ہیں پھر یہ رہا ہمارہ میچر الکوریتم یہاں سے یہاں تک تو ہمارے پس آلگلک لکیشن الکوریتم سے ہمارے پسے ایک انٹرسٹ بیسی کمیچر بیسی کمیچر الکیشن میچر یہ تین ہو گئے ہم نے کمیچر فیکٹری بنالی اور اپنا مہچر ٹائیت بنالیہ اور یہاں ہمارہ چیٹروں اور مہسجیز آگے تو یہ پورا کا پورا آرکی ٹیکٹر ہم نے بنائیں ایھوپ آپ کو یہ سمجھ آیا ہوگا اور یہ اپلکیشن جتے ہیں اتنی ایزی لی آپ کو سمجھ بی آیا گئے اور اس کو بنانے میں مزائے گئے اب فتح فٹ سے اس پورے کا دیگرام کا کوڑ دیکھتے ہیں اور سے کنکلوڑ کرتے ہیں تو یہ ہے یہ ہے اس کا پورا کا پورا کوڑ یہاں تک اگی ان میں اس پورے کے بھر کوڑ کو اپنی ایکی فائل میں لکھا کیوں کہ بہت بچوں کو دکھا دکھا دکھا دکھا دکھا ایلگرام کا فائلس میں گوڑ کرنے میں آپ چاہو تو جب آپ اس کوڑ کوڑ کوڑ رید کرو گوڑ کرو تو آپ اس کو ایلگرام موڈلر موڈلائیس کرسکتے ہیں انفیکٹ موڈلر کوڑ ہمیںشہ بیٹر ہوتا ہے وہ ایک پڑاکشن ٹائی پیپریکیشن جب آپ ایک پروجیک بھی بناؤ گے تو آپ سے ایک پیٹ کیا ہے آپ کا کوڑ موڈلر رونا چیے تو پریکٹس کے لیجا آپ اس میں کوئی فیچٹس انگریٹ کرو گے تو بناؤ سکتے ہو آپ ایک بیگر کوڑ گوڑ کر لے دیکھا بہت سمپل کوڑ ہے سب سے پہلے ہم اپنے اپنے اپنے اپنے اپسار دیکھا دیکھا دیکھا دیکھا اپسار دیکھا دیکھا دیکھا جس کے پاس 메سجیک پیرامیٹر ہے اور یہ مہنے ورچل پر رکھا ہے اگئے میں آپ لوگ کو سجس کروں گا آپ پوراکہ پر آجو ایوامل دائگرام ہے وہ گٹھا پسے لیلیجی اس کریشوٹ لیجا اس کوپنے ساتھ رکھوں جب میں ایک کوڑ گوڑ کر رہا ساکھ آپ کو چیزے بیٹر سمجھے کیا کیا کیا کیا کیا کیا کیا کیا کیا کیا کیا کیا کیا کیا کیا کیا ابہ میں اپنے کنكریٹ opt-ZRWD جس کا نام ابہم اپنے opt-ZR WABAL بودnah opt-ZRWD ابہم اپنے opt-ZRWD opt-ZRWD opt-ZRWD opt-ZRWD opt-ZRWD opt-ZRWD opt-ZRWD opt-ZRWD opt-ZRWD opt-ZRWD opt-ZRWD opt-ZRWD opt-ZRWD ہم وہی جو بیسک میتھڈ ہوتے, add remove or notify vala, تو یہاں پس کل جگا ہم دیگا ہم دیگاں ریجسٹر Observer وہیک user ID لیتے ہیں اور ایک Observer لیتے ہیں اس کو اس Mac میں add کر لیتے ہیں same remove Observer, وہ بس ایک user ID لیتے ہیں اور اس Maps سے remove کر دے تھی ایسے ہم ارے پس دو notify کے میتھڈے ایک تھا notify user ایک تھا notify all notify user کیا گرے گا ایک پیٹیکلر user ID کو ایک message کو notify keregah ایک ایک message کو notify keregah اور اس کو update method call اور notify all تو simple وہ ایک message اور اس list جتنے بی Observer وہسب کو update method call دے گا تو یہاں پیئے ہو گیا اب اپنی basic model دیکھتے کن کون سے ہے سب سے پہلے ہم نے gender اپنے اینم بنالیا یہاں پہنے male female non binary اذر یہ سب بگر رکھا ہے اور اس کو بعد میں بھی extended کر سکھے دیکھا اب امرہ لیتے ہیں اب امرہ لیتے ہیں کلاس لوگشر میں نے کہا تھا دو چیز ہوگی لیتیٹوڑ and longitude لگلک یہاں نے اس کا constrictor بگر بنا لیئے الگلک اور یہاں کے getters and setters ہو گیاں اب دیکھا انٹرستیگلی میں نے ایک کیا کیا ایک جو امرہ دستنس in kilometers وہ کے getter وہ کے getter ایک اور location لیتا تھا اور اس location کا اس لیتیٹوی longitude جو یہاں پہ بھی ہم نے پاس کیوں گے اسے ان کے بیچ میں distance نگالتا Kilometer ve یا آپ کو پتے کبتے اکتا جب آپ user کی glass بنا لکتے کہ یا آپ ہم اس کو بھی اب جیکنہ سکتا میں اس کو بھی اب جیکنہ سکتا اسی لیے اس کوشتن میں نہ ہم نے bottom 에 فیپروج کی جگا top down approach کو پرفر کیا اب آپ کو سامجایاں کیو top down لیا ہم نے اگر ہم bottom up بناتے نہ تو ہم کبھی ہم کبھی ہتنے سا رہے اب نا پاتے اور ہمارے interest کی strings تکہ یہ بھی نے preferences میں رکھا تھا یہ ہمارا constructor ہوں گیا اور یہ ہمارے کوئی geter setters ہوں گے by add remove set set add remove بگر بگر بگر بگر بگر basic geter settersیں سب اب ہم دیکھلے تیپنی message class ہمارے بس کچھنی accent ایڈ ڈ ڈ ڈ ڈ ڈ ڈ ڈ ڈ ڈ ڈ ڈ ڈ ڈ ڈ ڈ ڈ ڈ ڈ ڈ ڈ ڈ ڈ ڈ ڈ ڈ ڈ ڈ ڈ ڈ ڈ ڈ ڈ ڈ ڈ ڈ ڈ ڈ ڈ ڈ ڈ ڈ ڈ ڈ ڈ ڈ ڈ ڈ ڈ ہم نے یہاں پہ بھی کیاں یہی کام ہم نے اپنی Muziek Player Application میں بھی دیکھا تھا تو یہ بہت انٹرسٹینگزری کا ہوتا ہے ایک اپسر بھی بلディタイن بیٹھنگوں امپلیمین کرنے کا اس کے لابا ہم نے ہم نے آپے ایوزار کا دیسترکٹر منا دیا جو بھی ہماری چیزے تیجیس کے ساتھ یہ ٹائٹلی قبل تھا بسیگلی جو اس کے ساتھ یہ композиشنڈیشنشپ میں تھا جسے پروفائل پریفرینز ہمارہ پورا کا پورا سروبس سے اپنے آپ کو ریموف کرنا اور נوردفیکشنü آبسرنا اون سب کوئی دسترائی کر دے گا جب جب ایوز دسترائی ہوگا، ایسلی ہم نے اس کے ذہا جو ریلیشنی منا دیا وہ ڈیشنڈیشنی منا دیا تھا ان سب کا پروفائل پریفرینز اپسرور دیا تو باکی جو اس میں بیسک منا تھنگہ ایٹی گیٹ پروفائل بیسک گیٹرسائٹر سے فیل ہم نے اپنے اسپھنیشپ سوائب دیکھو کیا کرتا ہے ایک user ID لیتا اور اس کا ایکشن لیتا ہے اور اس کو سوائب ہیسٹری کے مابدہ میں دال دیتا ہے ہے نا سمپل ابھیاں پیارے کچھ بیسک بھولیر میں تڈس ہے کی حیز لائگڈ حیز دسلائگڈ اور دیکھوڑے وہ user ID exist بھی کرتی ہے اگر اگزیس کرتی ہے تو اس کا سوائب ایکشن دیکھوڑے اگر سوائب ایکشن رائد ہے تو ٹروریٹنگہ روگے دلریفٹ ہے تو فلسیٹنگہ روگے اور اگر وہ existence نہیں کرتی تو بھی فلسیٹنگہ روگے ہے نا تو اسی طرف نے حیز جسلگ بنالوگے اور اسی طرح سے آپ حیز انتریکٹڑ بھی دیکھوڑے اگر طرف فیانا لی اگر user کے بعد بھی Çeہیے کیا ہے؟ وہ فائی نیر بہی ہیزر کو بیسکلی کیس انٹیگریٹ کرتے تھا تھا اگر ان لوگیشن میکسیوں انٹیسٹنز all-User بہت ایزی دری کہتے ہیں جو ہم نے انوینٹری والے میں بھی دیکھا تھا وہ اس all-User کی لست میں گوٹھرو کرے گا اگر اس کے سا دستنسین کلومیٹر کل کر دے گا اگر اس کا جو کہ ہم نے کنسا فوملا ہے یہ والا فوملا ہے ہاروین سائیں فوملا جیسی اس نے اس کو ایز کیا ہمنا رہا ہم نے چک کر دستنسے کہ وہ میکسیموں دستنسے چھوٹا ہے اگر ہے اگر ہے تو نیر بہی ایزر مجھے پوچھ بک کر دیا اگر وہ دستنس بڑا ہوتا تو مجھے پوچھ بک نہیں کرتے اور یہ لستریٹن میں یہ لستریٹنس کو نہیں دلتے فائی لی ہم نے اس لستریٹن کر با دیا تو یہ گئے ایزی دی گی اب ہمنا ری جو لکیشن سربیس جو تھی گلاز اس سے ہم نے اس دی گیشن آبجیک لییا ہم یہ بہت ایزر ایڈی لیسکتے ہیں ایزر بہت رہا ہے کہ ہم اس کی ایزر کی ریٹیلس ٹیکہ نہیں ہے اور یہاں پہ دو بلیا ہے یہاں کی ایک سکور کو ریٹن کر با دیں گے اب ہم نے کہاں دیگیتا ہم ٹینز رہا ہے اس کی بیسک مجھر ایک بنایں گے انٹرسٹ بیس مجھر اور ایک بنایں گے لوکیشن بیس مجھر اور تینوں کو آپس میں جو دیں گے ایزیگ سیو رہا ہے چینوں فرسپونسیبل تو سب سے بل دیں گے کلکلٹ میتسکور مم نے کیا کیا ہم نے user one اور user two لیا چکاں فردگ ہم نے اس کی بیسکسکورن کیسے گری ہم نے چکیا کیا user one like user two gender ہے کیسے ہم user one کے preferences کو لے کر کے اس کے preferences میں ہمارے پاستہ اس انٹرسٹڈین جینڈر والا میتھڈ اور اس میں چک کر لیا کی کیا user two get profile get gender اس کی اندر ہے تو اسے میں کیا مل جائگا کی کیا user one user two کے gender کو بسند کرتے ہیں تیم اسی زرام نکال سکتے ہیں کیا user two user one کے gender m'interested تو یہ دونوں بولین ہم نکال سکتے ہیں اگر دونوں true true ہے اگر دونوں ایمان لو اجمع سے ایک بھی fall تم score کو two 0.0 to return کر دیں گے کیا تو basic چیزانا اگر ایک user two user کی gender m'interested نہیں ہیں تو اس آگے کا score نکالے گی ضرطی نہیں ہم یہاں آپے 0 score return کرتے ہیں تیگے اب again آپ بولسکتے بھی ہے یہ بھی تو آپ کا principle of least knowledge کو بریک کر رہے بالکل کر رہے تیگے پر آپ کیا کر سکتے ہیں آپ چاہو تو user ke under he is interested in gender اگر میتھڈ رکسکتے ہیں تاکھیں ہم صرف delegate کرنے کا کام کریں پر ابھی میں اسکسٹر ہے ایمان اسکسٹر ہے کیا بہت سارے میتھڈ سو جاتے ہیں اگر دی ہے یہ آپ کو پتلاکی کیا return کر رہے 0 point 0 اب ہم چک کریں گے اگر یہاں پہ return نہیں ہوا یعنے کی دونوں ایک دوسری جنٹر میں interested ہے تو اگر اگر اگر پر فرنس چک کریں گے کیا user one کو user two ki age پسند ہے اگر اگر اگر اگر اگر اگر پر فرنس میں آتی ہے same age check کریں گے user two کو user one ki age پسند ہے کیا سچک کریں گے again under o ke preferences میں جا کر کے is age in range کر دیں گے وہ کیا کریں گے وہ اس Indoro ke age لیتا ہوگا اور چک کر لے گا کہ وہ range میں ہے کیا سچک کر دیں گے وہتی زی ہے اس کو پتہ اس کی range کیا اس کو پتہ user کیا ہے اور نروں کو مپ کر لے گا اگر آپ دیکھنا بھی چاہو اس انجین نچک کر لے گا minimum age اور maximum age کے اندر انجین age simple تو یہ سارے basic basic method جو آپ easy لی دیکھ سکتے ہیں تو یہاں اب ہم نے age is match کر لی ہے اب اگر دیکھ age match نہیں ہوتی ہم دوارہ 0.0 return ڈکڑھنگ کر دیں گے یہ بہت basic details اگر یہی match نہیں ہوری تو آگے کا score calculate کرنے گے اگر آپ نی basic details وہ 0 match یعنگیں گے basic score is score is 0 اب اس کے لہاں دستنس پرفرینس match کر سکتے ہیں ہم ایک distance نکال لیں گے یہ دیکھیں گے user 1 like user 2 like user 2 distance same user 2 like user 1 distance کھیں گے بھی 0.0 return نہیں ہوتا تو سارے criteria match ھنے گے بعد لیکن سے ہم 50% match ھنگے چلتے ہیں کیا بھی 0.5 ہم نے return ھنگ کر با دیا کیا 0.5q S i ہم نے ایک arbitrary value رکھی ہم اس کو 0.6, 0.25 کچھ بھی رکھتے ہیں میں نے کہا کہ یہ his scores match ھنگ کر رہے ہیں تو بھی 50% match ھنگ کر رہے ہیں تو ہم لوگ اس کے لہاں فیر ہم نے ایک νیا بنہا تھا interest based match ھنگے دیکھ اس کو بھی نکس انٹگریٹ کیا یہ بھی 2 user لتا user one user 2 سب سے پہلے کیا کرتا دیکھیں ہوں ایک basic match ھنگ کا object بنا تھا ہے اور base score nighaalda kese basic match ھنگ کا calculate match score call کر کے یعنے کی interest based nigh اس کا object call کیا تو اس نے basic match ھنگ algorithm ھنگا کر کے x score nighaalda let's say nighaalda 0.5 دیکھیں تو ہمیں base score رہے 0.5 اس کے over and above یہ اپنا score nighaalda تو دیکھیں چکھ کر لے تھا اگر base score 0 ھنگ کا base score رہے نون کے بیچ تو یہ بھی 0.0 یہ بھی 0.0 return ھنگ کا no need to continue basic criteria don't match تو یہ من کے چل رہے اگر ان کے فس میں gender match نہیں ہو رہے interest match and yet تو ہم seeda بھلیں گے interest but nighaalda و آگے مدے گے and his interest match کرنے کی کوشش کریں کیا his interest کو plas plas کرتے نگے simple تو ہم شئر interest کو بڑھا دہے اب دیکھو ہم نے finally ہم نے his bonus score دہے نگے گوشش کی based on their share interest تو ہم میں zaadha nabar share interest hams ko zaadha nabar score dhenge again dhikwaap mange چاہلو یہ سب جوم کر رہے یہ سب ہائی بہتہ دیکھا لے یہ بیزنس لوجک پیڈی پینگر دھا ہے let's آپ کو interview اور نے بھولا اور ہے وہ زاادہ انٹرسٹے ہے آپ کے élگواریدمس کو دیکھنے میں obviously وہ آپ کا structure تو دیکھیں گے آپ کو یہ بھی دیکھیں آپ نے کانگوار سے design patterns کو integrate کیا پر میں آپ کو بتا ہے تھا یہ آج کل بہتے ہیں یہ بہتے ہیں یہ بہتے ہیں کیا یہ بہتے ہیں کیا آپ یہ interview کے سامنے اسے آپ اسے آپ اسے آپ کو interview اور انگواریدم اسے آپ کو بہتے ہیں آپ کو بہتے ہیں آپ کو کو کو کو کو کو کو کو کو کو کو کو کو کو کو کو 0.21, آپ کا 0.2 ۔ Which is the maximum school. And as soon as the distance is as big as the distance, your score will be less. Simple, then you have removed the proximate score. So maximum score can be 2.2.
So we have again written, what is the base score plus proximate score. These three methods, these three classes, one is our basic match, one is interest-based match, and one is location-based match. We match these three and use them as a risk chain of responsibility and we have removed the final matching score. So this is how our matching algorithm works.
And this is a very interesting project. If you are trying to apply this in any application where you have to apply a matching algorithm. So try to apply this chain of responsibility and make a matching algorithm. Okay?
Now let's move on. Our basic match was a factor. If a match is a type, if it is a basic match, if it is an interest-based match, and if it is a location-based match, then it will return the location-based match. And the basic match is returning.
Now let's move on to our final dating application. Our main object was an orchestrator object. We have lists of all users. We have lists of all chat rooms.
We have a match. Now because this is also a single time, we have a private constructor, and we have a get instance name. Okay? Now let's move on.
We have a set-getter set-up. Set-matcher, create-user, get-user by ID. Yes. So the main method was find-near-by-user.
See how it works. It is very simple. It takes a user ID and takes a maximum distance. First of all, it takes a user ID and gets an ID.
So get user by ID. It is got a user. Okay? Now let's check the find-users within maximum distance.
So we have kept the maximum distance and took all the nearby users. How will it work? You know that we have a find-near-by-user in our location service. We will use the list of nearby users.
Now when we get the list of users, we will take out the user by using the list. Because the list of users will also be used. We have said nearby users. So we will take all the users that are given by users.
We will take out the list of the value of the user's list. Okay? What are you doing after that? Filter-out users that don't match preferences or have already been swiped.
So this is also very simple logic. We are just taking out those users that are not matching the preferences or that are already swiped. Okay? So you can see how we have looped through nearby users.
Skip those users that have already been interacted with. How can we check? What is the user's has interacted with? What is the user ID?
Okay? If they have interacted with the user, then we will not take this user. Because we have already seen the user's has been connected. Or we have already talked about it.
So why are these users shown? So whenever we will refresh the user, we will not be showing them new users. Now again, we can take out a match score. So we can take out the score.
So we can check that the score is greater than 0. So we will put it in the list. Otherwise, we will not put it in the list. Look, if the score is above 0, they will meet the basic preference criteria.
Otherwise, they are not meeting the meeting criteria. So if the score is 0, then we are saying that the two users are not matching the meeting criteria. So we will not show it in the list. So we have written here.
Filter-out users. So finally, the user who is a fine nearby. He is just a filtered user and you can see it. Okay?
All users didn't show it. But the location service of the fine nearby user gives you all the users. So then it is the method of the work. So you can see how we have done some filters.
This is also very interesting algorithm. Then the method of swipe is very simple. Users, who do swipe with us? They use the user ID.
They use the target user ID. And they use the action. So the swipe action is left here. So first they will use the user ID.
The target user will use the target user. And they will check whether there is any null. Or if there is no null, then the user will call the swipe. They will see the target user ID and the action.
Now, they will check whether there is a match here. Because when you swipe, then there is a chance that there is a match. Let's say the user has swiped the right. And the user who did the right swipe before was also swiped the right.
So the message says it is a match. So, as such, the user swiped the targeted user. So, as we will see how we will do the swipe. If the action, which is right, and the targeted user has also swiped the user.
Remember, the method of the method has swiped the user ID. We have seen that the targeted user has also swiped the user. If these two are true, the user has already swiped here. What swiped the right swipe?
And if the targeted user swiped the right swipe, then it is a match. What we will do? First of all, we will create a fatafidic chat room. We will create a chat room with ID.
How to use ID? Under the target user ID. So, if user ID is user 1 and user 2 is user 2. So, what is the message of chat room?
What is the name of the message? User 1 and the user 2. Okay. Then we will see a new chat room created.
This is the ID of the chat room. It is user ID and the target user ID. And the chat room is pushed back. In chat rooms.
In chat rooms. In chat rooms. This is a list of chat rooms. We have created a new chat room.
Okay. Once the chat room is created, our work will be notified. So, what we have done is, we have called the get instance. So, we have called the single-tenth instance.
And we have called the notify user. Now, this was an observable. As an observable user, we have to pass the message of the user ID. And we have called the message of the user.
We have called the user you have a new match with this. We have sent the target. Same we have sent the target user ID. You have a new match with the user.
Okay. We have notified both of them. As we have notified both of them. What will they do?
They will call the update method. They will call the user ID. The update method will be called on the console. It will output.
That is, they will get their notification. Okay. Finally, we have another basic method. Get chat room.
It doesn't matter. The user ID is taken. And I mean, both of them get the user ID. And if the chat room is on their name, they get the return.
Otherwise, they get the return. Then we have a send message. You will get the chat room. You can send the message to the other person.
So, how do they send the message? Send the sender ID, receiver ID, and content. These are three things. First of all, we have to take out the chat room.
We have to take out the sender ID, receiver ID, and the message. How? What will the chat room do? You know, what is the chat room?
Sender ID, underscore receiver ID. If we get the chat room from this name, then it is okay. If we don't get it, we will return it in this if we get it. No chat room found, return.
And if we get the chat room, then we will add a message in that chat room. Okay, what will the message do? Who is the sender ID? What message will the sender send?
That is content. We will add it. You will get the message, what will the message do in that chat room? We will add the message in that vector of the list.
We will add the message in that list. Finally, if a message goes to a message, then we will not send notification. So, we will get the notification of the service for instance. And we will use the notify user.
We will send the receiver ID to this message. This message is sent to the new message from this user. Okay, finally, we have a method of display user. The user will display all the details.
How to call the display profile of the user. And we can do our display chat room. How to get the chat room before we bring it to the user ID, on the basis of user twid. If the chat room does not exist, then we will return it.
And if the chat room does exist, then we will call the display chat room. The entire chat room will display the chat room. Okay, now these display methods are generally made. We will only see the output on the console.
The rest of our entire structure is actually run to the flow. These are the output for our output. Right? Now we have seen all the things we have done on our main code.
Now we will discuss our happy flow. Okay, first of all, what we have done is, we have created a dating app for the instance. Okay, we have created two user ones, user one, user two. So, the creator of the app called the creator and the user's ID passed.
Okay, so, first of all, what we have done is, we have set the profile of the user one. So, what we have done is, we have set the profile of the user one. We have created a name, Rohan, 28 of our age. We have created our gender, we have bio, we have software developers.
We have a photo of our own, and we have added three intras. What we have added is, coding, travelling, music. Okay, now, what we have done is, we have created programming, lifestyle and entertainment. Then, we have set our preferences.
So, what we have done is, what we have done is, the gender preference is female. So, we have created 25 to 30 maximum distance, 10 km. And, which one of them should be interested in? We have coding, and we have travelled.
Okay, which one of them is interested in? We have created the second partner, right? We have created the second user. This is the preferences.
Okay, now, what we have done is, we have created the user two. We have set the profile of the user two. Let's say, user one, Rohan. Okay, so, we have created a male.
We have created a female, we have created a male. She has 27 female. And, let's say, her bio is, she would love spending and travelling. Photo is, there is interest in, three, painting travelling music.
And, there are some preferences of her. Let's say, there is interest in the male. The age range is 27 to 30, maximum distance is 15, and there are two interesting, coding and movies. Now, you can see, the user one, the Rohan, and the user two, Neha.
Both of these preferences are almost matched. Look, this one should be 35, when it is 30, its size is 27. This one should be 27 to 30, Rohan is so 28. So, both of these are matching age range.
Look, both of them are matching interest. The user one's preference is, coding and travelling. And, the user two's preference is, coding and movies. So, both of them are matching the coding part.
And, there are also the movies. So, if we take the score, then, how will the score come? Okay. Let's do what we do after that.
Let's set the location. The user one. So, the location one, the user one's location is, its latitude, longitude, we have given some basic, 1.0, 1.0, and some random values. Okay.
And, we have called its set location. Now, what we have done is, we have done the user two, which is Neha. We have done the user one's passput. Okay.
So, the closer to user one, which means within 5 km, so that it shows its list. Okay. So, we have created the latitude, latitude, and set it in its profile. Now, what will we do?
First of all, we will display the user profiles. So, display user one, display user two. Simple, simple, simple display, and we are not doing anything. What will we do?
Find Nearby user call for user one. So, Nearby user for user one, all the users, one's, people will come, we should go to Neha. Okay. So, we will show that, these people have got us.
Okay. After that, we have done an action, that user one swipes right on user two. Then user two swipes right on user one. So, first user one, will swipe right, user two.
That is, Rohan, Neha will swipe right. So, how will we swipe the app? We will call swipes. The user one is the sender, user two is the receiver, and the right is the performed section.
Now, once swipes are swiped, we will check what the match is. But, we will not match now, because user two has swiped the user one. Now, we have performed the action twice. This time, user two has swiped the user one.
So, when the check will be from the other side, it is a match. So, the true will be here, because both of them have matched the other one. So, as the true will be here, there will be a chatroom. So, if the chatroom will be there, then what will be the name of that chatroom?
What will be the name of that chatroom? User one enters the user two. Both of them have an ID. So, what will we do?
First, we will call the chatroom. We will call the app's send message. User one, user two, we will send the message. And what will be the first message?
Let's see how we will not match. Now, what will be the message? User one and user two, we will write a chatroom. User one enters the user two.
It will be met in that chatroom. And, we will call the message in that chatroom. I mean, you saw this. You see, we will write the chatroom, get chatroom by using the center ID and receiver ID, like you have called the message in the chatroom.
And, finally, notification is also based. So, this will happen when the user one message will be sent to the user two. What message will be sent? What message will be sent?
How will it be? Now, the second app is sent to the user two. The message is sent to the user one. I will tell you the important thing.
Okay? So, we can continue the chat like this. We can finally chat once we have done this. We can display the entire chatroom.
For that, we have a concept. Display chatroom. We have given the user two and user two's ID. What will they do?
They will take the chatroom again and again. And, if the chatroom does not get it, then the user will call the display chatroom. Okay? Now, if we run this entire application, then, see, all this has been done.
First of all, we have printed the profile of Rohan. The name of it is, Age, Mail, Amma Software Developer, Photos, Interest, and Location. Now, we will show the profile of Neha, 27 female, Art teacher, Neha's photo, painting, and location. Right?
Now, let's see, we have put the user one in the near by. So, we have checked who is the user of the user one. Found one user, Neha. So, we have found a girl Neha, Rohan.
Let's see the swipe actions. First, user one, swipe right on user two. Then, user two, swipe right on user one. Then, as soon as they send the swipe, they will get the notification.
So, first of all, the notification for the user two. What is the new match with Rohan? What is the notification for the user one? You have new match with Neha.
Right? Now, as soon as the match is done, their chat room will be assigned. First of all, the message will be sent to the user two. Neha, Rohan has got the new message from Rohan.
Same, she got the notification from Neha. And what we have done in the last one, we printed the entire chat. So, we have attached the timestamps. The user has sent the message to the high Neha.
Then, the time stamp is attached. The user has sent the message to the high Rohan. And this is the whole code of our code. Now, if you agree with my suggestion, then do a good job of using this full UML.
And try to write the code yourself. Okay? The algorithm will discuss all this. So, you will have to read the code.
You can go to the gate of your code. You can implement it yourself. In this, there is no wrong answer. Right?
You can see that you will get a matching score. You can check the different dating applications such as the bump, the hinge, how they get the matching score. Okay? Once you do all this, you will get confidence from yourself.
How can you make an application of an LLD? Okay? When you practice all this, you will get better in your LLD. If you are in this playlist, then I can agree that you have already been better in LLD.
Okay? Now, you have to practice questions. You have to improve yourself. Right?
It has no end. You have to practice more. You will get better in your problems. You will get better in your requirements, in your narrow-down, and in your UML diagram.
Right? In this video, I will see you in the next video. Thank you so much. Thank you so much.
Lesson FAQs
What is Build Tinder | Dating Site | System Design about?
حن جی تو کرس start welcome back core to our Landesregierung series OR today's lecture is going to catch up或 because i am the hizo the right so jump fatapathy Chang Bean or个 integrate Ond یہ leche hai sensor kan erste pero tot lo 1000
What key concepts are covered in this lesson?
The lesson covers System Design, Low Level Design, High level Design, System Design for Beginner, System Design for advance level.
What should I learn before Build Tinder | Dating Site | System Design?
Review the previous lessons in System Design Full Course, then use the transcript and key concepts on this page to fill any gaps.
How can I practice after this lesson?
Practice by applying the main concepts: System Design, Low Level Design, High level Design, System Design for Beginner.
Does this lesson include a transcript?
Yes. The full transcript is visible on this page in indexable HTML sections.
Is this lesson free?
Yes. CourseHive lessons and courses are available to learn online for free.
