split_changes_sync


Description:

public bool split_changes_sync (ref SList<BookMetaBackendInfo> objects, out SList<BookMetaBackendInfo> out_created_objects, out SList<BookMetaBackendInfo> out_modified_objects, out SList<BookMetaBackendInfo>? out_removed_objects, Cancellable? cancellable = null) throws Error

Splits objects into created/modified/removed lists according to current local cache content.

Only the out_removed_objects can be null, others cannot. The function modifies objects by moving its 'data' to corresponding out lists and sets the objects 'data' to null.

Each output SList should be freed with g_slist_free_full (objects, e_book_meta_backend_info_free); when no longer needed.

The caller is still responsible to free objects as well.

Parameters:

this

an BookMetaBackend

objects

a SList of BookMetaBackendInfo object infos to split

out_created_objects

a SList of BookMetaBackendInfo object infos which had been created

out_modified_objects

a SList of BookMetaBackendInfo object infos which had been modified

out_removed_objects

a SList of BookMetaBackendInfo object infos which had been removed; it can be null, to not gather list of removed object infos

cancellable

optional Cancellable object, or null

Returns:

Whether succeeded.