ServerConfigRepository
Functions
Link copied to clipboard
abstract suspend fun configForUser(userId: <Error class: unknown class>): Either<StorageFailure, ServerConfig>
Return the server links and metadata for the given userId
Link copied to clipboard
abstract suspend fun fetchApiVersionAndStore(links: ServerConfig.Links): Either<CoreFailure, ServerConfig>
calculate the app/server common api version for a new non stored config and store it locally if the version is valid can return a ServerConfigFailure in case of an invalid version
Link copied to clipboard
abstract suspend fun getOrFetchMetadata(serverLinks: ServerConfig.Links): Either<CoreFailure, ServerConfig>
Link copied to clipboard
abstract suspend fun storeConfig(links: ServerConfig.Links, metadata: ServerConfig.MetaData): Either<StorageFailure, ServerConfig>
Link copied to clipboard
update the api version of a locally stored config