UserStorage

interface UserStorage

A type representing storage

Already registered users will be kept in it between app launches.

Methods of this interface must not be called outside of the SDK, as they are intended for internal use only.

Note that this interface does not provide any data encryption. Developers must ensure data is encrypted as needed.

By default, this SDK uses a concrete implementation of this interface RoomUserStorage.

Functions

Link copied to clipboard
abstract fun add(user: UserDto)

Adds a registered user to the user storage.

Link copied to clipboard
abstract fun all(): List<UserDto>

Returns all users from the user storage.

Link copied to clipboard
abstract fun delete(user: UserDto)

Deletes a registered user and its identities from the user storage.

Link copied to clipboard
abstract fun getUser(userId: String, projectId: String): UserDto?

Retrieves a registered user from the user storage.

Link copied to clipboard
abstract fun loadStorage()

Prepares the user storage to be used.

Link copied to clipboard
abstract fun update(user: UserDto)

Updates a registered user in the user storage.