pub unsafe extern "C" fn svn_repos_get_commit_editor5(
editor: *mut *const svn_delta_editor_t,
edit_baton: *mut *mut c_void,
repos: *mut svn_repos_t,
txn: *mut svn_fs_txn_t,
repos_url_decoded: *const c_char,
base_path: *const c_char,
revprop_table: *mut apr_hash_t,
commit_callback: svn_commit_callback2_t,
commit_baton: *mut c_void,
authz_callback: svn_repos_authz_callback_t,
authz_baton: *mut c_void,
pool: *mut apr_pool_t,
) -> *mut svn_error_t
Expand description
Return an @a editor and @a edit_baton to commit changes to the filesystem of @a repos, beginning at location ‘rev:@a base_path’, where “rev” is the argument given to open_root().
@a repos is a previously opened repository. @a repos_url_decoded is the decoded URL to the base of the repository, and is used to check copyfrom paths. @a txn is a filesystem transaction object to use during the commit, or @c NULL to indicate that this function should create (and fully manage) a new transaction.
Store the contents of @a revprop_table, a hash mapping const char * property names to #svn_string_t values, as properties of the commit transaction, including author and log message if present.
@note #SVN_PROP_REVISION_DATE may be present in @a revprop_table, but it will be overwritten when the transaction is committed.
Iff @a authz_callback is provided, check read/write authorizations on paths accessed by editor operations. An operation which fails due to authz will return SVN_ERR_AUTHZ_UNREADABLE or SVN_ERR_AUTHZ_UNWRITABLE.
Calling @a (*editor)->close_edit completes the commit.
If @a commit_callback is non-NULL, then before @c close_edit returns (but after the commit has succeeded) @c close_edit will invoke @a commit_callback with a filled-in #svn_commit_info_t *, @a commit_baton, and @a pool or some subpool thereof as arguments. The @c repos_root field of the #svn_commit_info_t is @c NULL. If @a commit_callback returns an error, that error will be returned from @c close_edit, otherwise if there was a post-commit hook failure, then that error will be returned with code SVN_ERR_REPOS_POST_COMMIT_HOOK_FAILED. (Note that prior to Subversion 1.6, @a commit_callback cannot be @c NULL; if you don’t need a callback, pass a dummy function.)
Calling @a (*editor)->abort_edit aborts the commit, and will also abort the commit transaction unless @a txn was supplied (not @c NULL). Callers who supply their own transactions are responsible for cleaning them up (either by committing them, or aborting them).
@since New in 1.5. Since 1.6, @a commit_callback can be @c NULL.
@note Yes, @a repos_url_decoded is a decoded URL. We realize that’s sorta wonky. Sorry about that.
@note Like most commit editors, the returned editor requires that the @c copyfrom_path parameter passed to its @c add_file and @c add_directory methods is a full, URI-encoded URL, not a relative path.