S.O.L.I.D. | Dependency Inversion Principle feat. Kotlin

Поделиться
HTML-код
  • Опубликовано: 18 янв 2025

Комментарии • 32

  • @CastAsHuman
    @CastAsHuman 4 года назад +5

    Another gem from Mr Reppas!!! Can’t wait to see what’s next!

  • @amineharbaoui7408
    @amineharbaoui7408 2 года назад +2

    Thanks for the video, the only one made me understand the Dependency Inversion

  • @emanalsbeiheen5619
    @emanalsbeiheen5619 2 года назад +1

    Great video,,,, thank you so much 🌹🌹🌹🌹🌹🌹

  • @Jan-bl9xg
    @Jan-bl9xg 2 года назад +2

    Thanks alot, you made this principle and its advantages very clear to me!

  • @johnny5gr
    @johnny5gr 3 года назад +2

    Finally an awesome explanation. I like the way you combine the principles in your explanation. Also, a real world example helps a lot. I was always confused by the dependency inversion while I thought I would still depend on the low level module if I instantiate the concrete implementation in the high level module. But as you simply explained it, this part can be tackled by dependency injection. Thanks man! I will definitely check out others videos you have regarding SOLID principles and coding. Φοβερος!

  • @Pauhoihoi
    @Pauhoihoi 4 года назад +2

    Nice explanation, thank you

  • @rafaelcagliari6747
    @rafaelcagliari6747 Год назад

    Great vid!

  • @kuldeepj2127
    @kuldeepj2127 3 года назад +1

    Very well explained. Thank you!

  • @SteveBurkert
    @SteveBurkert 2 года назад

    Great series! Thank for that. Enjoyed watching and learning.

  • @paulndibe250
    @paulndibe250 3 года назад

    you should be given an award. You just made the Dependency inversion principle very easy to understand, thanks and you just gained a new subscriber👍

  • @EhsanIrshad
    @EhsanIrshad 9 месяцев назад

    Thank You

  • @santanujenabls
    @santanujenabls 2 года назад +1

    Great explanation !
    Q: Do we need to always declare the interface under high level module? What will happen if we declare the interface under low level module?

  • @amirhbagheri9929
    @amirhbagheri9929 2 года назад

    Thanks, It's a great video and I subscribed to your channel.

  • @mohamedalaa6yahoo
    @mohamedalaa6yahoo 2 года назад

    many thanks💙💙💙
    could you please tell me how to inject the interface in the constructor ?
    I know that abstract classes and interfaces can not be instantiated
    so how will you use NotificationSettings class ??

    • @KonstantinosReppas
      @KonstantinosReppas  Год назад +1

      Thank you.
      You will need to pass an implementation of the interface/abstract class. So the constructor has an interface as an argument, but thanks to polymorphism we can pass an actual object as long as it implements/extends the abstract interface.

  • @mikochu7746
    @mikochu7746 4 года назад +1

    Please show us how to use Clean Architecture. In the books Uncle Bob used an interactor pattern to initialize the dependencies -- would be nice if you could also, thank you for the tutorial.

    • @KonstantinosReppas
      @KonstantinosReppas  4 года назад +1

      Planning on creating a series on AndroidnClean Architecture so keep an eye out in the near future! Glad you liked it:)

    • @mikochu7746
      @mikochu7746 4 года назад

      @@KonstantinosReppas lovely!!!

  • @SagarPatel288
    @SagarPatel288 2 года назад +1

    This is the best explanation I have found so far! ❤️
    If class A uses class B, then class A is a high-level module and class B is a low-level module. Is that correct?

  • @1990zainmalik
    @1990zainmalik 2 года назад

    Hi Mr. Reppas, Thanks for your videos. I need proper definition of Application Class and How to implement it if there is no Application Class in Android Project. A small app will b beneficial.

  • @mrrobot8923
    @mrrobot8923 Год назад

    Awesome! Please, make some videos about patterns - Builder, Factory, Adapter etc... Without android, on clean examples.

  • @DLDLDL1010
    @DLDLDL1010 4 года назад +2

    Tenet Protagonist after shooting an inverted bullet:
    ...wow.

  • @Attee_Q
    @Attee_Q 2 года назад

    I can't see in your video how you can handle the NotificationSettings class in your Activity.

  • @Attee_Q
    @Attee_Q 2 года назад

    I have tried follow this way in my app. I gave the Preferences interface in to my Activity constructor.
    class MainActivity(val iPrefs: IPreferences) : AppCompatActivity()
    It does not work:
    java.lang.RuntimeException: Unable to instantiate activity ComponentInfo{***********.MainActivity}: java.lang.InstantiationException: java.lang.Class has no zero argument constructor