app / de.uniks.codliners.stock_simulator.repository / QuoteRepository / fetchQuote

fetchQuote

suspend fun fetchQuote(id: String, type: Type): Boolean

Fetches the Quote and HistoricalPrices for the requested asset from the respective API, then stores them in the StockAppDatabase.

Parameters

id - The id of the asset.

type - The Symbol.Type of the asset.

Return
true if the operation was successful and false otherwise.