Skip to content
This repository has been archived by the owner on Oct 23, 2023. It is now read-only.

Commit

Permalink
feat(access): add use case
Browse files Browse the repository at this point in the history
  • Loading branch information
AndreaBrighi committed May 2, 2023
1 parent 4fad15e commit 4abf29b
Showing 1 changed file with 17 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
package com.intelligentbackpack.accessdomain.usecase

import com.intelligentbackpack.accessdomain.entities.User
import com.intelligentbackpack.accessdomain.repository.AccessDomainRepository

class AccessUseCase(private val repository: AccessDomainRepository) {

suspend fun createUser(user: User) = repository.createUser(user)

suspend fun isUserLogged() = repository.isUserLogged()

suspend fun loginWithData(username: String, password: String) = repository.loginWithData(username, password)

suspend fun automaticLogin() = repository.automaticLogin()

suspend fun logoutUser() = repository.logoutUser()
}

0 comments on commit 4abf29b

Please sign in to comment.