85chong

  • 홈
  • 태그
  • 방명록

callback 1

CallBack 함수 in Kotlin 사용 예

B class -> A class callback 호출 할때, * A class 준비 : A class { ... var b = B() b.setListener{name, age -> Log.d("log","name : ${name}") Log.d("log","age : ${age}") } ... } * B class 준비 : B class { ... private var listener: ((String, Int) -> Unit)? = null ... fun setListener{listener: (String,Int) -> Unit) { this.listener = listener } ... listener?.invoke("만식이",10)// A class 전달할 곳에서 호출 } 위처럼 A 에서는 호..

Kotlin Study 2021.01.26
이전
1
다음
더보기
프로필사진

85chong

#Challenge #Analysis #Record #Upgrade

  • 분류 전체보기 (213)
    • Kotlin Study (18)
    • JAVA Study (9)
    • Swift Study (3)
    • Android Study (111)
    • iOS Study (9)
    • illustrator (4)
    • Git Study (8)
    • Good Sentence (3)
    • MAC Book Menual (2)
    • Exception Study (13)
    • Etc (8)
    • CrossPlatform (1)
    • iOS Reject Case (1)
    • MyMemo (1)
    • HotKeys (3)
    • Python (7)

Tag

Android, drawableEnd, layout하위폴더, crashlytics, ios 12.4, androidstudio4.1.1, the following depencies on the complile classpath, Kotlin, res layout, apple login, firebase, android4.1.1, java, drawableStart, Xcode 12.5, nestedscrollview, apk, TextView, classpath are found to contain annotation processor, bluetooth receiver,

최근글과 인기글

  • 최근글
  • 인기글

최근댓글

공지사항

페이스북 트위터 플러그인

  • Facebook
  • Twitter

Archives

Calendar

«   2025/05   »
일 월 화 수 목 금 토
1 2 3
4 5 6 7 8 9 10
11 12 13 14 15 16 17
18 19 20 21 22 23 24
25 26 27 28 29 30 31

방문자수Total

  • Today :
  • Yesterday :

Copyright © Kakao Corp. All rights reserved.

티스토리툴바