Unable to access variable from innerclass : Kotlin android
You should use the inner modifier in your adapter.
This modifier makes the inner class have access to the members of the outer class
Reference: https://kotlinlang.org/docs/reference/nested-classes.html