Class MessageBackup
-
- All Implemented Interfaces:
public class MessageBackupMessage-backup-related functionality.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public classMessageBackup.ValidationResultResult produced on a successful validation.
Contains information about non-fatal validation issues.
public enumMessageBackup.Purpose
-
Constructor Summary
Constructors Constructor Description MessageBackup()
-
Method Summary
Modifier and Type Method Description static MessageBackup.ValidationResultvalidate(MessageBackupKey key, MessageBackup.Purpose purpose, Supplier<InputStream> streamFactory, long streamLength)Validates an encrypted message backup bundle. -
-
Method Detail
-
validate
static MessageBackup.ValidationResult validate(MessageBackupKey key, MessageBackup.Purpose purpose, Supplier<InputStream> streamFactory, long streamLength)
Validates an encrypted message backup bundle.
Returns an error if the input cannot be read or if validation fails.
- Parameters:
key- the key to use to decrypt the backuppurpose- whether the input was created for device-to-device transfer or remote backupstreamFactory- a factory forInputStreams that produce the inputstreamLength- the number of bytes eachInputStreamwill produce- Returns:
informational result about the successful validation
-
-
-
-