Subclassing

When calling the constructor, we always instantiate the class we specify. On the other hand, calling a Static Factory Method may produce either instance of the class, or one of its subclasses. We'll come to this after discussing the implementation of this design pattern in Kotlin.

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

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