Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- class MyClass(val doThis: () -> Unit, val doThat: (number: Int) -> Unit = {}) {
- fun someFunction(){
- doThis()
- doThat(12)
- }
- }
- class UserClass {
- val myClass = MyClass(::doThis, ::doThat)
- private fun doThis() {
- }
- private fun doThat(number: Int) {
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement