Last active
July 26, 2019 19:25
-
-
Save aronbalog/e6205803dd492fc29212bba5c9a4449e to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.example.demo.dao | |
import com.example.demo.repository.PersonRepository | |
import org.springframework.stereotype.Component | |
@Component | |
class PersonDao( | |
private val personRepository: PersonRepository | |
) { | |
fun getPersonById(id: String) = | |
personRepository.findById(id) | |
fun getPersonsByName(name: String) = | |
personRepository.findByNameLike(name) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment