# VersionsRepo

interface VersionsRepo < T > : Repo (source)

This interface has been created due to requirement to work with different versions of databases and make some migrations between versions

#### Type Parameters

T

It is a type of database, which will be used by this repo to retrieve current table version and update it

#### Inheritors

StandardVersionsRepo

## Functions

setTableVersion
Link copied to clipboard
abstract suspend fun setTableVersion (tableName: String , version: Int , onCreate: suspend T .() -> Unit = {}, onUpdate: suspend T .(from: Int , to: Int ) -> Unit = { _, _ ->})

By default, instance of this interface will check that version of table with name tableName is less than version or is absent