get_folder_info_sync


Description:

[ Version ( since = "3.0" ) ]
public virtual FolderInfo? get_folder_info_sync (string? top, StoreGetFolderInfoFlags flags, Cancellable? cancellable = null) throws Error

This fetches information about the folder structure of this, starting with top, and returns a tree of FolderInfo structures.

If flags includes camel_store_folder_info_subscribed, only subscribed folders will be listed. If the store doesn't support subscriptions, then it will list all folders. If flags includes camel_store_folder_info_recursive, the returned tree will include all levels of hierarchy below top. If not, it will only include the immediate subfolders of top. If flags includes camel_store_folder_info_fast, the unread_message_count fields of some or all of the structures may be set to -1, if the store cannot determine that information quickly. If flags includes camel_store_folder_info_no_virtual, don't include special virtual folders (such as vTrash or vJunk).

The returned FolderInfo tree should be freed with free.

The CAMEL_STORE_FOLDER_INFO_FAST flag should be considered deprecated; most backends will behave the same whether it is supplied or not. The only guaranteed way to get updated folder counts is to both open the folder and invoke refresh_info it.

Parameters:

this

a Store

top

the name of the folder to start from

flags

various CAMEL_STORE_FOLDER_INFO_* flags to control behavior

cancellable

optional Cancellable object, or null

Returns:

a FolderInfo tree, or null on error




2022 vala-language.org