[][src]Function ejdb_sys::ejdbimport

pub unsafe extern "C" fn ejdbimport(
    jb: *mut EJDB,
    path: *const c_char,
    cnames: *mut TCLIST,
    flags: c_int,
    log: *mut TCXSTR
) -> bool

Imports previously exported collections data into ejdb. Global database write lock will be applied during import operation.

NOTE: Only data exported as BSONs can be imported with ejdbimport()

@param jb EJDB database handle. @param path The directory path in which data resides. @param cnames List of collection names to import. NULL implies that all collections found in path will be imported. @param flags Can be one of: JBIMPORTUPDATE Update existing collection entries with imported ones. Existing collections will not be recreated. For existing collections options will not be imported.

        `JBIMPORTREPLACE` Recreate existing collections and replace
                          all their data with imported entries.
                          Collections options will be imported.

        `0`              Implies `JBIMPORTUPDATE`

@param log Optional operation log buffer. @return