From b4ada04647336c30a7c3a27e4ab6340ebdadb09b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EA=B9=80=EB=AA=85=EC=84=9D?= Date: Thu, 9 Feb 2023 09:15:31 +0900 Subject: [PATCH] =?UTF-8?q?Issues=20#287=20feat:=20database=20internal=20?= =?UTF-8?q?=EC=B6=94=EA=B0=80=20=EB=B0=8F=20=ED=8C=8C=EC=9D=BC=20=EC=9D=B4?= =?UTF-8?q?=EB=8F=99?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../lighthouse/data/database/{ => database}/BeepDatabase.kt | 2 +- .../data/database/di/{DataBaseModule.kt => DatabaseModule.kt} | 4 ++-- .../lighthouse/data/database/exception/DBDeleteException.kt | 2 +- .../lighthouse/data/database/exception/DBInsertException.kt | 2 +- .../lighthouse/data/database/exception/DBNotFoundException.kt | 2 +- .../lighthouse/data/database/exception/DBSelectException.kt | 2 +- .../lighthouse/data/database/exception/DBUpdateException.kt | 2 +- .../main/java/com/lighthouse/data/database/ext/KotlinExt.kt | 2 +- 8 files changed, 9 insertions(+), 9 deletions(-) rename data/data-database/src/main/java/com/lighthouse/data/database/{ => database}/BeepDatabase.kt (97%) rename data/data-database/src/main/java/com/lighthouse/data/database/di/{DataBaseModule.kt => DatabaseModule.kt} (93%) diff --git a/data/data-database/src/main/java/com/lighthouse/data/database/BeepDatabase.kt b/data/data-database/src/main/java/com/lighthouse/data/database/database/BeepDatabase.kt similarity index 97% rename from data/data-database/src/main/java/com/lighthouse/data/database/BeepDatabase.kt rename to data/data-database/src/main/java/com/lighthouse/data/database/database/BeepDatabase.kt index 168c45f2f..5c506ca8d 100644 --- a/data/data-database/src/main/java/com/lighthouse/data/database/BeepDatabase.kt +++ b/data/data-database/src/main/java/com/lighthouse/data/database/database/BeepDatabase.kt @@ -1,4 +1,4 @@ -package com.lighthouse.data.database +package com.lighthouse.data.database.database import androidx.room.Database import androidx.room.RoomDatabase diff --git a/data/data-database/src/main/java/com/lighthouse/data/database/di/DataBaseModule.kt b/data/data-database/src/main/java/com/lighthouse/data/database/di/DatabaseModule.kt similarity index 93% rename from data/data-database/src/main/java/com/lighthouse/data/database/di/DataBaseModule.kt rename to data/data-database/src/main/java/com/lighthouse/data/database/di/DatabaseModule.kt index 783df59e6..3b6fc2c4a 100644 --- a/data/data-database/src/main/java/com/lighthouse/data/database/di/DataBaseModule.kt +++ b/data/data-database/src/main/java/com/lighthouse/data/database/di/DatabaseModule.kt @@ -2,11 +2,11 @@ package com.lighthouse.data.database.di import android.content.Context import androidx.room.Room -import com.lighthouse.data.database.BeepDatabase import com.lighthouse.data.database.dao.BrandLocationDao import com.lighthouse.data.database.dao.GifticonEditDao import com.lighthouse.data.database.dao.GifticonSearchDao import com.lighthouse.data.database.dao.GifticonUsageHistoryDao +import com.lighthouse.data.database.database.BeepDatabase import dagger.Module import dagger.Provides import dagger.hilt.InstallIn @@ -16,7 +16,7 @@ import dagger.hilt.components.SingletonComponent @Suppress("unused") @Module @InstallIn(SingletonComponent::class) -internal object DataBaseModule { +internal object DatabaseModule { @Provides fun provideBeepDatabase( diff --git a/data/data-database/src/main/java/com/lighthouse/data/database/exception/DBDeleteException.kt b/data/data-database/src/main/java/com/lighthouse/data/database/exception/DBDeleteException.kt index c1d5491b5..a6ca8fc49 100644 --- a/data/data-database/src/main/java/com/lighthouse/data/database/exception/DBDeleteException.kt +++ b/data/data-database/src/main/java/com/lighthouse/data/database/exception/DBDeleteException.kt @@ -1,3 +1,3 @@ package com.lighthouse.data.database.exception -class DBDeleteException(message: String = "데이터 Delete 에 실패 했습니다.") : Exception(message) +internal class DBDeleteException(message: String = "데이터 Delete 에 실패 했습니다.") : Exception(message) diff --git a/data/data-database/src/main/java/com/lighthouse/data/database/exception/DBInsertException.kt b/data/data-database/src/main/java/com/lighthouse/data/database/exception/DBInsertException.kt index c598cf852..1fb1c6d09 100644 --- a/data/data-database/src/main/java/com/lighthouse/data/database/exception/DBInsertException.kt +++ b/data/data-database/src/main/java/com/lighthouse/data/database/exception/DBInsertException.kt @@ -1,3 +1,3 @@ package com.lighthouse.data.database.exception -class DBInsertException(message: String = "데이터 Insert 에 실패 했습니다.") : Exception(message) +internal class DBInsertException(message: String = "데이터 Insert 에 실패 했습니다.") : Exception(message) diff --git a/data/data-database/src/main/java/com/lighthouse/data/database/exception/DBNotFoundException.kt b/data/data-database/src/main/java/com/lighthouse/data/database/exception/DBNotFoundException.kt index c634a91e3..65bc9716f 100644 --- a/data/data-database/src/main/java/com/lighthouse/data/database/exception/DBNotFoundException.kt +++ b/data/data-database/src/main/java/com/lighthouse/data/database/exception/DBNotFoundException.kt @@ -1,3 +1,3 @@ package com.lighthouse.data.database.exception -class DBNotFoundException(message: String = "데이터를 찾을 수 없습니다.") : Exception(message) +internal class DBNotFoundException(message: String = "데이터를 찾을 수 없습니다.") : Exception(message) diff --git a/data/data-database/src/main/java/com/lighthouse/data/database/exception/DBSelectException.kt b/data/data-database/src/main/java/com/lighthouse/data/database/exception/DBSelectException.kt index cd73c0e50..628cdc22b 100644 --- a/data/data-database/src/main/java/com/lighthouse/data/database/exception/DBSelectException.kt +++ b/data/data-database/src/main/java/com/lighthouse/data/database/exception/DBSelectException.kt @@ -1,3 +1,3 @@ package com.lighthouse.data.database.exception -class DBSelectException(message: String = "데이터 Select 에 실패 했습니다.") : Exception(message) +internal class DBSelectException(message: String = "데이터 Select 에 실패 했습니다.") : Exception(message) diff --git a/data/data-database/src/main/java/com/lighthouse/data/database/exception/DBUpdateException.kt b/data/data-database/src/main/java/com/lighthouse/data/database/exception/DBUpdateException.kt index 95336c0bc..514c9bdfa 100644 --- a/data/data-database/src/main/java/com/lighthouse/data/database/exception/DBUpdateException.kt +++ b/data/data-database/src/main/java/com/lighthouse/data/database/exception/DBUpdateException.kt @@ -1,3 +1,3 @@ package com.lighthouse.data.database.exception -class DBUpdateException(message: String = "데이터 Update 에 실패 했습니다.") : Exception(message) +internal class DBUpdateException(message: String = "데이터 Update 에 실패 했습니다.") : Exception(message) diff --git a/data/data-database/src/main/java/com/lighthouse/data/database/ext/KotlinExt.kt b/data/data-database/src/main/java/com/lighthouse/data/database/ext/KotlinExt.kt index 0700ef793..674918e1b 100644 --- a/data/data-database/src/main/java/com/lighthouse/data/database/ext/KotlinExt.kt +++ b/data/data-database/src/main/java/com/lighthouse/data/database/ext/KotlinExt.kt @@ -1,8 +1,8 @@ package com.lighthouse.data.database.ext +import com.lighthouse.beep.model.exception.common.NotFoundException import com.lighthouse.beep.model.exception.db.DeleteException import com.lighthouse.beep.model.exception.db.InsertException -import com.lighthouse.beep.model.exception.db.NotFoundException import com.lighthouse.beep.model.exception.db.SelectException import com.lighthouse.beep.model.exception.db.UpdateException import com.lighthouse.data.database.exception.DBDeleteException