📄 client.h
字号:
NOTE: The reason for the _internal suffix of this function's name is to avoid confusion with the public API svn_client_open_ra_session(). */svn_error_t *svn_client__open_ra_session_internal(svn_ra_session_t **ra_session, const char *base_url, const char *base_dir, svn_wc_adm_access_t *base_access, apr_array_header_t *commit_items, svn_boolean_t use_admin, svn_boolean_t read_only_wc, svn_client_ctx_t *ctx, apr_pool_t *pool);/* ---------------------------------------------------------------- *//*** Commit ***//* Get the commit_baton to be used in couple with commit_callback. */svn_error_t *svn_client__commit_get_baton(void **baton, svn_commit_info_t **info, apr_pool_t *pool);/* The commit_callback function for storing svn_client_commit_info_t pointed by commit_baton. If the commit_info supplied by get_baton points to NULL after close_edit, it means the commit is a no-op.*/svn_error_t *svn_client__commit_callback(const svn_commit_info_t *commit_info, void *baton, apr_pool_t *pool);/* ---------------------------------------------------------------- *//*** Status ***//* Verify that the path can be deleted without losing stuff, i.e. ensure that there are no modified or unversioned resources under PATH. This is similar to checking the output of the status command. CTX is used for the client's config options. POOL is used for all temporary allocations. */svn_error_t * svn_client__can_delete(const char *path, svn_client_ctx_t *ctx, apr_pool_t *pool);/* ---------------------------------------------------------------- *//*** Add/delete ***//* Read automatic properties matching PATH from CTX->config. Set *PROPERTIES to a hash containing propname/value pairs (const char * keys mapping to svn_string_t * values), or if auto-props are disabled, set *PROPERTIES to NULL. Set *MIMETYPE to the mimetype, if any, or to NULL. Allocate the hash table, keys, values, and mimetype in POOL. */svn_error_t *svn_client__get_auto_props(apr_hash_t **properties, const char **mimetype, const char *path, svn_client_ctx_t *ctx, apr_pool_t *pool); /* The main logic for client deletion from a working copy. Deletes PATH from ADM_ACCESS. If PATH (or any item below a directory PATH) is modified the delete will fail and return an error unless FORCE is TRUE. If DRY_RUN is TRUE all the checks are made to ensure that the delete can occur, but the working copy is not modifed. If NOTIFY_FUNC is not null, it is called with NOTIFY_BATON for each file or directory deleted. */svn_error_t * svn_client__wc_delete(const char *path, svn_wc_adm_access_t *adm_access, svn_boolean_t force, svn_boolean_t dry_run, svn_wc_notify_func2_t notify_func, void *notify_baton, svn_client_ctx_t *ctx, apr_pool_t *pool);/* Return the list of WC paths to entries which would have been deleted by an update/merge if not in "dry run" mode, or NULL if not in "dry run" mode. MERGE_CMD_BATON contains the list, which is intended for direct modification. */apr_hash_t *svn_client__dry_run_deletions(void *merge_cmd_baton);/* ---------------------------------------------------------------- *//*** Checkout, update and switch ***//* Update a working copy PATH to REVISION, and (if not NULL) set RESULT_REV to the update revision. RECURSE if so commanded; likewise, possibly IGNORE_EXTERNALS. If TIMESTAMP_SLEEP is NULL this function will sleep before returning to ensure timestamp integrity. If TIMESTAMP_SLEEP is not NULL then the function will not sleep but will set *TIMESTAMP_SLEEP to TRUE if a sleep is required, and will not change *TIMESTAMP_SLEEP if no sleep is required. */svn_error_t *svn_client__update_internal(svn_revnum_t *result_rev, const char *path, const svn_opt_revision_t *revision, svn_boolean_t recurse, svn_boolean_t ignore_externals, svn_boolean_t *timestamp_sleep, svn_client_ctx_t *ctx, apr_pool_t *pool);/* Checkout into PATH a working copy of URL at REVISION, and (if not NULL) set RESULT_REV to the checked out revision. RECURSE if so commanded; likewise, possibly IGNORE_EXTERNALS. If TIMESTAMP_SLEEP is NULL this function will sleep before returning to ensure timestamp integrity. If TIMESTAMP_SLEEP is not NULL then the function will not sleep but will set *TIMESTAMP_SLEEP to TRUE if a sleep is required, and will not change *TIMESTAMP_SLEEP if no sleep is required. */svn_error_t *svn_client__checkout_internal(svn_revnum_t *result_rev, const char *URL, const char *path, const svn_opt_revision_t *peg_revision, const svn_opt_revision_t *revision, svn_boolean_t recurse, svn_boolean_t ignore_externals, svn_boolean_t *timestamp_sleep, svn_client_ctx_t *ctx, apr_pool_t *pool);/* Switch a working copy PATH to URL at REVISION, and (if not NULL) set RESULT_REV to the switch revision. RECURSE if so commanded. If TIMESTAMP_SLEEP is NULL this function will sleep before returning to ensure timestamp integrity. If TIMESTAMP_SLEEP is not NULL then the function will not sleep but will set *TIMESTAMP_SLEEP to TRUE if a sleep is required, and will not change *TIMESTAMP_SLEEP if no sleep is required. */svn_error_t *svn_client__switch_internal(svn_revnum_t *result_rev, const char *path, const char *url, const svn_opt_revision_t *revision, svn_boolean_t recurse, svn_boolean_t *timestamp_sleep, svn_client_ctx_t *ctx, apr_pool_t *pool);/* ---------------------------------------------------------------- *//*** Editor for repository diff ***//* Create an editor for a pure repository comparison, i.e. comparing one * repository version against the other. * * TARGET is a working-copy path, the base of the hierarchy to be * compared. It corresponds to the URL opened in RA_SESSION below. * * ADM_ACCESS is an access baton with a write lock for the anchor of * TARGET. It should lock the entire TARGET tree if RECURSE is TRUE. * ADM_ACCESS may be NULL, in which case the DIFF_CMD callbacks will be * passed a NULL access baton. * * DIFF_CMD/DIFF_CMD_BATON represent the callback and calback argument that * implement the file comparison function * * RECURSE is set if the diff is to be recursive. * * DRY_RUN is set if this is a dry-run merge. It is not relevant for diff. * * RA_SESSION defines the additional RA session for requesting file * contents. * * REVISION is the start revision in the comparison. * * If NOTIFY_FUNC is non-null, invoke it with NOTIFY_BATON for each * file and directory operated on during the edit. * * EDITOR/EDIT_BATON return the newly created editor and baton/ */svn_error_t *svn_client__get_diff_editor(const char *target, svn_wc_adm_access_t *adm_access, const svn_wc_diff_callbacks2_t *diff_cmd, void *diff_cmd_baton, svn_boolean_t recurse, svn_boolean_t dry_run, svn_ra_session_t *ra_session, svn_revnum_t revision, svn_wc_notify_func2_t notify_func, void *notify_baton, svn_cancel_func_t cancel_func, void *cancel_baton, const svn_delta_editor_t **editor, void **edit_baton, apr_pool_t *pool);/* ---------------------------------------------------------------- *//*** Editor for diff summary ***//* Create an editor for a repository diff summary, i.e. comparing one * repository version against the other and only providing information * about the changed items without the text deltas. * * @a summarize_func is called with @a summarize_baton as parameter by the * created svn_delta_editor_t for each changed item. * * See svn_client__get_diff_editor() for a description of the other * parameters. */svn_error_t *svn_client__get_diff_summarize_editor(const char *target, svn_client_diff_summarize_func_t summarize_func, void *summarize_baton, svn_ra_session_t *ra_session, svn_revnum_t revision, svn_cancel_func_t cancel_func, void *cancel_baton, const svn_delta_editor_t **editor, void **edit_baton, apr_pool_t *pool);/* ---------------------------------------------------------------- *//*** Commit Stuff ***//* WARNING: This is all new, untested, un-peer-reviewed conceptual stuff. The day that 'svn switch' came into existence, our old commit crawler (svn_wc_crawl_local_mods) became obsolete. It relied far too heavily on the on-disk hierarchy of files and directories, and simply had no way to support disjoint working copy trees or nest working copies. The primary reason for this is that commit process, in order to guarantee atomicity, is a single drive of a commit editor which is based not on working copy paths, but on URLs. With the completion of 'svn switch', it became all too likely that the on-disk working copy hierarchy would no longer be guaranteed to map to a similar in-repository hierarchy. Aside from this new brokenness of the old system, an unrelated feature request had cropped up -- the ability to know in advance of your commit, exactly what would be committed (so that log messages could be initially populated with this information). Since the old
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -