Published On Premiered Sep 29, 2021
In this episode we go over what interfaces are and how to use them. We also discuss the concepts of dependency inversion, dependency injection and abstraction. Interfaces are an unbelievably powerful tool that allows you to use abstraction to create more robust and flexible code. It also gives you the ability to completely decouple your UI from the actual implementation of your business logic it retrieves data from. There are few tools as powerful as interfaces in an OOP developers toolset.
Interface Tutorial GitHub Link: https://github.com/Coding-With-The-Fo...
Video Explaining Constructors: • Constructors | Java | Tutorial 28
Please consider donating to help continue to improve the content produced for Coding With The Force: https://www.paypal.com/donate?busines...
Get Coding With The Force Merch Here: https://my-store-d20559.creator-sprin...
Follow all of our social media here:
Patreon: / codingwiththeforce
Github: https://github.com/Coding-With-The-Force
Facebook: / codingwiththeforce
Twitter: / coding_force
Instagram: / codingwiththeforce
Salesforce development books I recommend:
Advanced Apex Programming: https://amzn.to/3lXi8to
Salesforce Lightning Platform Enterprise Architecture: https://amzn.to/2R0D4BQ
Mastering Salesforce DevOps: https://amzn.to/3lTtTRN
Apex Design Patterns Book: https://amzn.to/3DwqljP
Good Non-SF Specific Development Books:
Clean Code: https://amzn.to/35PuMDU
Clean Architecture: https://amzn.to/35FYo6A
Design Patterns: Elements of Reusable Object-Oriented Software Book: https://amzn.to/3LhvHBd
-----------------------------------------------------------------------------------------------------------------------
Table of Contents:
0:00 - Intro
0:20 - What we're covering in this video
0:45 - Get Free SF Certs! Vote on New Videos! Get a Channel Membership!
2:45 - What is an Interface?
6:50 - Why use an Interface?
13:35 - How to create and use an interface (Creating an Abstract Clone Component)
14:04 - Creating the Interface
17:05 - Creating the LWC, Controller and Generic Service Class Shells
22:54 - Explaining Dependency Injection
27:38 - Creating our concrete service classes that implement our interface
39:38 - Dynamically initializing an apex class from a string
52:35 - Outro
DISCLAIMER: The views and ideas expressed on this YouTube channel and blog are based on past development experiences and may not always work for your particular scenarios. The advice in these videos may also become outdated as technology advances. They should be used as examples for educational purposes only. Using any shown solutions in your own org is not advisable since they are example scenarios.