ExportableBackupProvider

Interface for backup providers that support file import/export.

This is only implemented by LocalFileBackupProvider. Cloud providers do not support manual file import/export.

Functions

Link copied to clipboard
abstract suspend fun deleteBackup(): Result<Unit>

Delete the backup.

Link copied to clipboard
abstract suspend fun exportToDownloads(): Result<String>

Export the backup file to the device's Downloads folder.

Link copied to clipboard
abstract suspend fun hasBackup(): Boolean

Check if a backup exists.

Link copied to clipboard
abstract suspend fun importFromPath(sourcePath: String): Result<Unit>

Import a backup file from an external path.

Link copied to clipboard
abstract suspend fun loadBackup(): Result<ByteArray>

Load encrypted backup data.

Link copied to clipboard
abstract suspend fun saveBackup(encryptedData: ByteArray): Result<Unit>

Save encrypted backup data.