BackupAgent.FullBackupFile(File, FullBackupDataOutput) Method

Definition

Write an entire file as part of a full-backup operation.

[Android.Runtime.Register("fullBackupFile", "(Ljava/io/File;Landroid/app/backup/FullBackupDataOutput;)V", "")]
public void FullBackupFile (Java.IO.File? file, Android.App.Backup.FullBackupDataOutput? output);
[<Android.Runtime.Register("fullBackupFile", "(Ljava/io/File;Landroid/app/backup/FullBackupDataOutput;)V", "")>]
member this.FullBackupFile : Java.IO.File * Android.App.Backup.FullBackupDataOutput -> unit

Parameters

file
File

The file to be backed up. The file must exist and be readable by the caller.

output
FullBackupDataOutput

The destination to which the backed-up file data will be sent.

Attributes

Remarks

Write an entire file as part of a full-backup operation. The file's contents will be delivered to the backup destination along with the metadata necessary to place it with the proper location and permissions on the device where the data is restored.

<p class="note">Attempting to back up files in directories that are ignored by the backup system will have no effect. For example, if the app calls this method with a file inside the #getNoBackupFilesDir() directory, it will be ignored. See #onFullBackup(FullBackupDataOutput) for details on what directories are excluded from backups.

Java documentation for android.app.backup.BackupAgent.fullBackupFile(java.io.File, android.app.backup.FullBackupDataOutput).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to