KeySearchViewModel

class KeySearchViewModel @Inject constructor(keyserverClient: KeyserverClient, keyRepository: KeyRepository, settingsRepository: SettingsRepository) : ViewModel

ViewModel that performs keyserver lookups and imports the fetched public key into the local repository.

Constructors

Link copied to clipboard
@Inject
constructor(keyserverClient: KeyserverClient, keyRepository: KeyRepository, settingsRepository: SettingsRepository)

Properties

Link copied to clipboard
val uiState: StateFlow<KeySearchUiState>

Functions

Link copied to clipboard
open fun addCloseable(closeable: AutoCloseable)
fun addCloseable(key: String, closeable: AutoCloseable)
Link copied to clipboard
Link copied to clipboard
fun search()

Fetches a key from the configured keyserver and imports it as public.

Link copied to clipboard
fun setQuery(value: String)

Updates the search query text.