Summary

In this chapter, we learned about one of the most exciting features of Kotlin: interoperability. Here, we can call Kotlin code in Java and vice versa. We started this chapter by calling Java static variables and functions in Kotlin, then we moved onto the Java collections, and we explored some examples of calling Java classes in Kotlin.

We then discussed how to handle the Kotlin reserve words and utilized Kotlin written code in Java with variables, functions, extension functions, and the Kotlin class. We also discussed the replacement of Kotlin filenames and function names by using a Kotlin-provided JVM annotation. Finally, we had a quick look at how to call Kotlin's object class in Java. In next chapter we will discuss about regular expression and serialisation in kotlin. 

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.17.176.72