Function deltachat::imex::imex

source ·
pub async fn imex(
    context: &Context,
    what: ImexMode,
    path: &Path,
    passphrase: Option<String>
) -> Result<()>
Expand description

Import/export things.

What to do is defined by the what parameter.

During execution of the job, some events are sent out:

  • A number of DC_EVENT_IMEX_PROGRESS events are sent and may be used to create a progress bar or stuff like that. Moreover, you’ll be informed when the imex-job is done.

  • For each file written on export, the function sends DC_EVENT_IMEX_FILE_WRITTEN

Only one import-/export-progress can run at the same time. To cancel an import-/export-progress, drop the future returned by this function.