Notice
Recent Posts
Recent Comments
Link
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
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 |
Tags
- sqlite
- DataBinding
- Coroutine
- Navigation
- room
- kotlin
- notification
- lifecycle
- HTTP
- Behavior
- 알고리즘
- onMeasure
- recyclerview
- CoordinatorLayout
- View
- Android
- Algorithm
- onLayout
- 안드로이드
- LiveData
- activity
- hilt
- ViewModel
- AppBarLayout
- 알림
- 코틀린
- BOJ
- 백준
- CustomView
- CollapsingToolbarLayout
Archives
- Today
- Total
목록클래스 (1)
개발일지
Kotlin in A..Z (13) - 클래스
- 클래스 선언하기 코드 // 클래스 선언 class Something { // 프로퍼티 val id:Long = 0 // 메서드 fun action() { } } - 인스턴스 선언하기 생성자를 통해 인스턴스를 생성할 수 있다. 코드 val something = Something() - 주 생성자 코드 // 주 생성자 정의 class Something constructor(_id:Long) { val id: Long = _id } fun main() { // 주 생성자로 인스턴스 생성 val something = Something(123L) } - constructor를 생략한 주 생성자 코드 // 주 생성자 정의 class Something(_id:Long) { val id: Long = _id } f..
Kotlin (코틀린)
2020. 7. 15. 11:51