load_partial_contents_async


Description:

public async bool load_partial_contents_async (Cancellable? cancellable = null, FileReadMoreCallback read_more_callback, out uint8[] contents, out string etag_out) throws Error

Reads the partial contents of a file.

A FileReadMoreCallback should be used to stop reading from the file when appropriate, else this function will behave exactly as load_contents_async. This operation can be finished by load_partial_contents_async.end.

Users of this function should be aware that user_data is passed to both the read_more_callback and the callback .

If cancellable is not null, then the operation can be cancelled by triggering the cancellable object from another thread. If the operation was cancelled, the error g_io_error_cancelled will be returned.

Parameters:

this

input File

cancellable

optional Cancellable object, null to ignore

read_more_callback

a FileReadMoreCallback to receive partial data and to specify whether further data should be read

callback

a TaskReadyCallback to call when the request is satisfied

user_data

the data to pass to the callback functions