This repository has been archived on 2018-02-23. You can view files and clone it, but cannot push or open issues or pull requests.
url-shortener/src/main/kotlin/net/cismon/urlshortener/dao/UrlDao.kt

19 lines
474 B
Kotlin

package net.cismon.urlshortener.dao
import net.cismon.urlshortener.model.UrlModel
import org.springframework.data.repository.CrudRepository
import org.springframework.transaction.annotation.Transactional
@Transactional
interface UrlDao : CrudRepository<UrlModel, Long> {
fun findById(id: Long): UrlModel?
fun findByUid(uid: Long) : List<UrlModel>
fun findByUuid(uuid: String): UrlModel?
fun deleteById(id: Long)
fun save(url: UrlModel): UrlModel
}