Hilt Modules, @Provides, @InstallIn Annotation Android Tutorial - CheezyCode (Hindi)

  Рет қаралды 18,625

Cheezy Code

Cheezy Code

Күн бұрын

Learn Hilt Dependency Injection in Android. Learn how modules are implemented in Hilt. How they are different from Dagger2 Modules. Learn about @Provides annotation along with @InstallIn annotation in HILT. These annotations are required when you cannot use @Inject annotation on the constructor of classes or for scenarios where you have interfaces or abstract classes or classes that requires some patterns for object creation. For instance, room database requires builder pattern, for this we need modules.
Learn about predefined set of components for each android class in Hilt. i.e. Singleton Component, Activity Component, Fragment Component in Hilt. Learn step by step - how to implement Hilt in Android Applications with simple example in Hindi
Topics covered -
1. Need of Modules in Hilt Dependency Injection.
2. Difference between dagger modules and hilt modules.
3. @InstallIn annotation and built-in components.
4. @Module and @Provides in Hilt.
5. Complete Example of Dagger Hilt in Android.
Complete Dependency Injection Playlist Link -
• Dagger 2 - Dependency ...
Complete Android Architecture Components Playlist -
• Android Architecture C...
Beginner series in Android Playlist (Hindi) -
• Android Tutorials Step...
Kotlin Beginners Tutorial Series -
• Kotlin Beginner Tutori...
For more info - visit the below link
www.cheezycode.com
We are social. Follow us at -
Facebook - / cheezycode
Twitter - / cheezycode
Instagram - / cheezycode

Пікірлер: 74
@harshpanchal3761
@harshpanchal3761 Жыл бұрын
Video aise banao ki sirf 4 logo ko nahi, sabko samaj me aa jaye, Clear and concise! Great explanation. Thanks for video.
@hardcodeandroid
@hardcodeandroid 2 жыл бұрын
Sir i am fan of your teaching style, really.
@CheezyCode
@CheezyCode 2 жыл бұрын
Cheers 🔥
@DnyaneshwarMahajan-e8b
@DnyaneshwarMahajan-e8b 9 ай бұрын
Sir, the way you explain the things is excellent, you make complex things very simple. Keep it up. Hats off to you!
@than0s869
@than0s869 3 ай бұрын
very good explanation sir.
@anitavaghasiya369
@anitavaghasiya369 Жыл бұрын
your explanation is soo easy and understading
@CheezyCode
@CheezyCode Жыл бұрын
Thank you 😊
@amitray769
@amitray769 Жыл бұрын
I have watched many channels by different foreigners and google developers. But the way you explain, Sir. It's so awesome. First time ever I'm able to understand dependency injection in a best way. Subscribed your channel. thanks Sir.
@xlivetrend
@xlivetrend 2 жыл бұрын
Sir your way of explaining is next level 🔥
@CheezyCode
@CheezyCode 2 жыл бұрын
Thanks Gurwinder
@adarshpandey3316
@adarshpandey3316 2 жыл бұрын
Best Tutorial Available for Dagger Hlit on Internet
@CheezyCode
@CheezyCode 2 жыл бұрын
Thanks Adarsh
@aniketkanitkar4041
@aniketkanitkar4041 2 жыл бұрын
Really very good way of giving explanation 👍👍👍 Because of your videos understanding Dagger2 and Hilt has become very easy. Thanks a lot for explaining such a difficult topics in very easy manner 👍
@CheezyCode
@CheezyCode 2 жыл бұрын
Thanks a ton 👍
@kawsarhossain8931
@kawsarhossain8931 2 жыл бұрын
@@CheezyCode awesome.....😍
@kumarprince5054
@kumarprince5054 Жыл бұрын
I have watched as many channels in search of clear explanation, now I think I found one. I have watched every playlist of yours and I want to say thank you so much, they are amazing and top of my recommendation lists.
@CheezyCode
@CheezyCode Жыл бұрын
Thanks 😊
@user-zy2zp9sx7n
@user-zy2zp9sx7n 10 ай бұрын
Your explanation expedited my learning, Thanks!!!
@jatinvashisht4293
@jatinvashisht4293 2 жыл бұрын
Sir your way of explaining is next level 🔥 Thank you for these tutorials :)
@CheezyCode
@CheezyCode 2 жыл бұрын
Cheers 🔥
@amitsen656
@amitsen656 Жыл бұрын
you are amazing.......From last few days you are like my guru.......Happy Teachers day sir.... 🙂
@CheezyCode
@CheezyCode Жыл бұрын
Thank you 🙏
@makarandthakare9174
@makarandthakare9174 Жыл бұрын
thank you for explaining it like a story. I would rather binge watch your series than netflix. ✌
@CheezyCode
@CheezyCode Жыл бұрын
Cheers 🤘
@anupsarkar3063
@anupsarkar3063 2 жыл бұрын
awwwwwwwwwssssome explanation ...
@CheezyCode
@CheezyCode 2 жыл бұрын
Thanks Anup
@factpoint00
@factpoint00 Жыл бұрын
good tutorial
@CheezyCode
@CheezyCode Жыл бұрын
Thank you Adil
@rajkumarsingh8664
@rajkumarsingh8664 Жыл бұрын
Superb dear sir🙏👌
@vishaltorgal3372
@vishaltorgal3372 9 ай бұрын
Really nice explanation
@ektajain3983
@ektajain3983 2 жыл бұрын
LOVED IT, YOU MADE HILT EASY :)
@CheezyCode
@CheezyCode 2 жыл бұрын
Thank you! 😊
@lavishgarg5090
@lavishgarg5090 2 жыл бұрын
Sir kese ho, bhul to nhi gye ?, bhut hi acche se explain kiya aapne , keep making such videos, sir aaj recycler view ke liye ( evant data binding ) bhut use ho rhi he, usme adapter nhi banana pdta RV ka, i think vo kisi ne cover nhi kiya he.
@CheezyCode
@CheezyCode 2 жыл бұрын
Hey Lavish...Long time...Kya chal rha hai?? Placement hogayi?
@lavishgarg5090
@lavishgarg5090 2 жыл бұрын
@@CheezyCode badiya chal rha he sir,ha acchi jagah placement ho gyi ,connect krta hu aapse me .
@shalenmathew980
@shalenmathew980 9 ай бұрын
Great video
@sahayavision
@sahayavision 2 жыл бұрын
By far best tutorial videos available on internet...sir can I request u to make videos on Unit and Instrumentation testing in android it will be really helpful thanks
@CheezyCode
@CheezyCode 2 жыл бұрын
For sure...noted
@sanjaysharma0812
@sanjaysharma0812 2 жыл бұрын
Great work
@CheezyCode
@CheezyCode 2 жыл бұрын
Thank you so much 😀
@Jenis_Sanghani
@Jenis_Sanghani 7 ай бұрын
Thank You 🖤
@mohitkaranjawala7664
@mohitkaranjawala7664 2 жыл бұрын
Hello sir that's great you making video on topic its really helpful for us can you please make videos on SOLID principles with examples
@CheezyCode
@CheezyCode 2 жыл бұрын
Sure I will...but will take time....
@shreyashachoudhary480
@shreyashachoudhary480 Жыл бұрын
Great videos!
@vinaykumarpatel649
@vinaykumarpatel649 2 жыл бұрын
Thankn you
@CheezyCode
@CheezyCode 2 жыл бұрын
Thank you Vinay
@sulemankhan523
@sulemankhan523 Жыл бұрын
UserRepository is interface and we are having that param in view model, based on firebase or sql wherver is injected, we will get that dependency to use how we can access live data in fragment inside of user repoistory or firebase or sql repistory to update ui state whether success or failure, one way which i am able to do is by checking instance type in fragment and access live data than is there any better way to do this Please help
@shreyashachoudhary480
@shreyashachoudhary480 Жыл бұрын
Amazing!
@AhmadShahwaiz
@AhmadShahwaiz 11 ай бұрын
what if i want to use it in the viewmodel? then i will use SingletonComponents?
@AbhishekDhiman-cy4fi
@AbhishekDhiman-cy4fi 4 ай бұрын
So I understood that inside UserModule we created a function to return FirebaseRepository. What should I do if I have to get an SQLRepository instance in one place and a FirebaseRepository in another? What will the UserModule class look like in that case?
@CheezyCode
@CheezyCode 4 ай бұрын
Named import? @Inject them directly
@kawsarhossain8931
@kawsarhossain8931 2 жыл бұрын
Can we go through with complex and production-level app projects, please? Because I feel easy to understand your explanation
@CheezyCode
@CheezyCode 2 жыл бұрын
Done deal
@vikrantsaini437
@vikrantsaini437 Жыл бұрын
I followed you rDagger 2 tutorial and understood the concept. But what do we have to do in Hilt to pass dynamic values at runtime in an injected constructor?
@CheezyCode
@CheezyCode Жыл бұрын
Good point...generally as per hilt doc - if you have to pass dynamic values then design is not good so they have not provided anything. But they have one concept of assisted inject. You can read about that.
@vikrantsaini437
@vikrantsaini437 Жыл бұрын
@@CheezyCode Thanks for the quick response. I really liked your way of teaching any concept. Kudos to you.
@mdafzalali5666
@mdafzalali5666 2 жыл бұрын
please make a video on Retrofit with Hilt.
@CheezyCode
@CheezyCode 2 жыл бұрын
kzbin.info/www/bejne/qZfNfGVnmLWImtU kzbin.info/www/bejne/bYuZhGN4qsSJppI kzbin.info/www/bejne/hKLMoqaInrKHZ7M Watch these in sequence... already covered
@utkarshkumar1080
@utkarshkumar1080 2 жыл бұрын
I install my module in ActivityComponent and try to accees a class in my MainActivity.java then why i am getiing missing binding error,plz help sir
@CheezyCode
@CheezyCode 2 жыл бұрын
Error pe thora aur prakash daale.... can't tell you without seeing the code
@utkarshkumar1080
@utkarshkumar1080 2 жыл бұрын
@@CheezyCode I fixed that error now, thank you so much sir you are really doing a wonderful thing and i love the way you teach 😍😍,sir can you plz make a playlist on Singletons.
@poonammishra6276
@poonammishra6276 2 жыл бұрын
well Explained sir! would you mind explaining Koin also?
@CheezyCode
@CheezyCode 2 жыл бұрын
Yes but will do it later...
@junigates
@junigates Жыл бұрын
bro can we give array of components in module installin?
@RahulYadav-vs2wd
@RahulYadav-vs2wd 2 жыл бұрын
How can we provide value at run time in hilt? Suppose a class has a constructor parameter like int or string.
@CheezyCode
@CheezyCode 2 жыл бұрын
Got it... assisted inject...although as per google you might need to reconsider the structure of your codebase to avoid this situation...
@CheezyCode
@CheezyCode 2 жыл бұрын
Long live Dagger kuch control tha hamare pass...isme nahi h
@RahulYadav-vs2wd
@RahulYadav-vs2wd 2 жыл бұрын
Matlab ye disadvantage h hilt me.
@techByteswithfarooq
@techByteswithfarooq 2 жыл бұрын
Great Tutorial. Sir how do we create SQLRepository object instance in the main activity just like you create FirebaseRepository instance. I tried but got some exceptions. Thank you!
@CheezyCode
@CheezyCode 2 жыл бұрын
Let me check kuch qualifiers lagane padege shayad
@techByteswithfarooq
@techByteswithfarooq 2 жыл бұрын
​@@CheezyCode Done with qualifiers. Thank you!
@shikharsoni2249
@shikharsoni2249 Жыл бұрын
HISENBERG AND JESSI IN THE HOUSE GUIZ...
@CheezyCode
@CheezyCode Жыл бұрын
Yes we are breaking it bad 🤣
Hilt and dependency injection - MAD Skills
13:06
Android Developers
Рет қаралды 47 М.
Amazing Parenting Hacks! 👶✨ #ParentingTips #LifeHacks
00:18
Snack Chat
Рет қаралды 10 МЛН
WILL IT BURST?
00:31
Natan por Aí
Рет қаралды 47 МЛН
The CUTEST flower girl on YouTube (2019-2024)
00:10
Hungry FAM
Рет қаралды 48 МЛН
Clean Architecture in Android in 5 minutes
5:17
Renaro Santos
Рет қаралды 20 М.
How to Hide & Protect API Keys in Your Android App (Reverse Engineering)
10:13
What is Dependency Injection in Android kotlin using dagger hiilt in Hindi
12:06
Hilt testing best practices - MAD Skills
10:29
Android Developers
Рет қаралды 20 М.
Dependency Injection in Android - Dagger Basics
4:30
Simplified Coding
Рет қаралды 14 М.
Amazing Parenting Hacks! 👶✨ #ParentingTips #LifeHacks
00:18
Snack Chat
Рет қаралды 10 МЛН