Room DB
-
(30초 읽기) Room 빌드 오류! annotations 충돌 해결법 🚨Android 개발/오류 해결 2025. 2. 14. 16:28
Room DB 설정 중 "Duplicate class org.intellij.lang.annotations. found in modules annotations-12.0.jar …" 에러 발생? 🤯이건 IntelliJ vs JetBrains annotations 버전 충돌 때문! ⚔️ ✅ 해결 방법 (build.gradle 수정)dependencies { implementation(libs.androidx.room.runtime) implementation(libs.androidx.room.ktx) // 기존 room.compiler 의존성이 있다면 제거하고, 아래 kapt 의존성으로 대체합니다. kapt("androidx.room:room-compiler:2.6.1") { ..
-
(30초 읽기) 초간단! Room DB 시작하기 🖥️개발 환경 설정/데이터베이스(DB) 2025. 2. 14. 14:51
안드로이드에서 Room DB를 쓰려면? 🏗️ 그냥 Gradle에 추가하면 끝!dependencies { // Room 런타임 라이브러리 🏠 implementation "androidx.room:room-runtime:2.6.1" // 코루틴 확장 ✨ implementation "androidx.room:room-ktx:2.6.1" // Annotation Processing 🛠️ implementation "androidx.room:room-compiler:2.6.1" // 선택: 테스트 라이브러리 🧪 testImplementation "androidx.room:room-testing:2.6.1"} ✅ 이제 데이터베이스 준비 완료! 다음 단계? Entit..