This file contains 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
@Dao | |
abstract class CurrencyDao { | |
@Query("SELECT * FROM Currencies") | |
abstract fun getCurrency(): List<CurrencyEntity> | |
@Insert(onConflict = OnConflictStrategy.REPLACE) | |
abstract fun insertCurrency(rate: CurrencyEntity) |
This file contains 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
/** | |
* Created by Aks on 02.04.2017. | |
* | |
* Local database API | |
* | |
* @param context parent context | |
*/ | |
public class LocalDatabaseAPI(private val context: Context) { |