diff --git a/app/src/main/java/org/android/go/sopt/remote/remoteData/datasource/LoginDataSource.kt b/app/src/main/java/org/android/go/sopt/remote/remoteData/datasource/LoginDataSource.kt deleted file mode 100644 index afac4da..0000000 --- a/app/src/main/java/org/android/go/sopt/remote/remoteData/datasource/LoginDataSource.kt +++ /dev/null @@ -1,4 +0,0 @@ -package org.android.go.sopt.remote.remoteData.datasource - -class LoginDataSource { -} \ No newline at end of file diff --git a/app/src/main/java/org/android/go/sopt/remote/remoteData/datasource/LoginPageDataSource.kt b/app/src/main/java/org/android/go/sopt/remote/remoteData/datasource/LoginPageDataSource.kt new file mode 100644 index 0000000..ed3bb90 --- /dev/null +++ b/app/src/main/java/org/android/go/sopt/remote/remoteData/datasource/LoginPageDataSource.kt @@ -0,0 +1,26 @@ +package org.android.go.sopt.remote.remoteData.datasource + +import org.android.go.sopt.RequestSignUpDto +import org.android.go.sopt.ResponseSignUpDto +import org.android.go.sopt.remote.domain.LoginPageRepo +import org.android.go.sopt.remote.remoteData.model.MyProfileDto +import org.android.go.sopt.remote.remoteData.model.RequestLogInDto +import org.android.go.sopt.remote.remoteData.model.ResponseLogInDto +import org.android.go.sopt.remote.service.LogInPageService +import retrofit2.Response + +class LoginPageDataSource(private val apiService:LogInPageService):LoginPageRepo{ + override suspend fun login(request: RequestLogInDto): Response { + return apiService.login(request) + } + + override suspend fun signUp(request: RequestSignUpDto): Response { + return apiService.signUp(request) + } + + override suspend fun myProfile(userId: String): Response { + return apiService.myProfile(userId) + } + + +} \ No newline at end of file diff --git a/app/src/main/java/org/android/go/sopt/remote/remoteData/datasource/MainPageDataSource.kt b/app/src/main/java/org/android/go/sopt/remote/remoteData/datasource/MainPageDataSource.kt new file mode 100644 index 0000000..328af23 --- /dev/null +++ b/app/src/main/java/org/android/go/sopt/remote/remoteData/datasource/MainPageDataSource.kt @@ -0,0 +1,12 @@ +package org.android.go.sopt.remote.remoteData.datasource + +import org.android.go.sopt.remote.domain.MainPageRepo +import org.android.go.sopt.remote.remoteData.model.ResponseListUsersDto +import org.android.go.sopt.remote.service.MainPageService +import retrofit2.Response + +class MainPageDataSource(private val apiService:MainPageService):MainPageRepo { + override suspend fun getUserList(): Response { + return apiService.getListUsers() + } +} \ No newline at end of file