Kotlin Extension Functions & Inline Functions | Cheezycode #36

Publié le: 02 août 2020
sur la chaîne: Cheezy Code
28,154
577

In this tutorial, learn what are extension functions and how to define them. It is useful when you want to extend the functionality of a class by adding members external to the class. Inline functions are defined by just adding an inline keyword before the function declaration. It improves performance by reducing the number of objects created. Behind the scenes, Kotlin creates a class and instance for lambdas which can impact the performance if we use a large number of lambdas. You can use the inline keyword to improve its performance. What it does is - Just copy paste the body of the function wherever it is called. This tutorial is part #36 of Kotlin Programming For Beginners Series. Learn Object Oriented Programming in Kotlin. Everything is explained in Hindi. Brief topics covered -

1. What are extension functions?
2. How to define the extension function in Kotlin?
3. Disadvantages of defining lambdas
4. Improve performance by marking functions as inline in Kotlin
5. Compare bytecode of the functions with or without inline keyword

Learn all this in Hindi (हिंदी में )

Kotlin Lambda Expression and Lambda Functions -
   • Kotlin Lambdas Expressions | Higher O...  

Kotlin Beginners Tutorial Series -
   • Kotlin Beginner Tutorials Hindi | Com...  

For more info - visit below link
http://www.cheezycode.com

We are social. Follow us at -
Facebook -   / cheezycode  
Twitter -   / cheezycode  


Sur cette page du site, vous pouvez voir la vidéo en ligne Kotlin Extension Functions & Inline Functions | Cheezycode #36 durée heure minute seconde en bonne qualité , qui a été Téléchargé par l'utilisateur Cheezy Code 02 août 2020, Partagez le lien avec vos amis et connaissances, sur youtube cette vidéo a déjà été regardée 28,154 fois et il a aimé 577 téléspectateurs. Bon visionnage!