[][src]Type Definition melib::backends::notmuch::bindings::notmuch_database_get_directory

type notmuch_database_get_directory = unsafe extern "C" fn(database: *mut notmuch_database_t, path: *const c_char, directory: *mut *mut notmuch_directory_t) -> notmuch_status_t;

Retrieve a directory object from the database for 'path'.

Here, 'path' should be a path relative to the path of 'database' (see notmuch_database_get_path), or else should be an absolute path with initial components that match the path of 'database'.

If this directory object does not exist in the database, this returns NOTMUCH_STATUS_SUCCESS and sets *directory to NULL.

Otherwise the returned directory object is owned by the database and as such, will only be valid until notmuch_database_destroy is called.

Return value:

NOTMUCH_STATUS_SUCCESS: Successfully retrieved directory.

NOTMUCH_STATUS_NULL_POINTER: The given 'directory' argument is NULL.

NOTMUCH_STATUS_XAPIAN_EXCEPTION: A Xapian exception occurred; directory not retrieved.

NOTMUCH_STATUS_UPGRADE_REQUIRED: The caller must upgrade the database to use this function.