File.replaceContentsBytesAsync

void replaceContentsBytesAsync(glib.bytes.Bytes contents, string etag, bool makeBackup, gio.types.FileCreateFlags flags, gio.cancellable.Cancellable cancellable = null, gio.types.AsyncReadyCallback callback = null)

Same as [gio.file.File.replaceContentsAsync] but takes a #GBytes input instead. This function will keep a ref on contents until the operation is done. Unlike [gio.file.File.replaceContentsAsync] this allows forgetting about the content without waiting for the callback.

When this operation has completed, callback will be called with user_user data, and the operation can be finalized with [gio.file.File.replaceContentsFinish].

Parameters

contentsa #GBytes
etaga new entity tag for the file, or null
makeBackuptrue if a backup should be created
flagsa set of #GFileCreateFlags
cancellableoptional #GCancellable object, null to ignore
callbacka #GAsyncReadyCallback to call when the request is satisfied