- Learn Kotlin Programming(Second Edition)
- Stephen Samuel Stefan Bocutiu
- 57字
- 2021-06-24 14:13:27
Imports
To enable classes, objects, interfaces, and functions to be used outside of the declared package, we must first import them. We do this using the import keyword, and then listing the class, object, interface, or function to be imported:
import com.packt.myproject.Foo
In the preceding example, the Foo class was imported from the com.packt.myproject package.