📄 svn_ra.h
字号:
* The stream handlers for @a stream may not perform any RA * operations using @a session. * * @since New in 1.2. */svn_error_t *svn_ra_get_file(svn_ra_session_t *session, const char *path, svn_revnum_t revision, svn_stream_t *stream, svn_revnum_t *fetched_rev, apr_hash_t **props, apr_pool_t *pool);/** * If @a dirents is non @c NULL, set @a *dirents to contain all the entries * of directory @a path at @a revision. The keys of @a dirents will be * entry names (<tt>const char *</tt>), and the values dirents * (<tt>@c svn_dirent_t *</tt>). Use @a pool for all allocations. * * @a dirent_fields controls which portions of the <tt>@c svn_dirent_t</tt> * objects are filled in. To have them completely filled in just pass * @c SVN_DIRENT_ALL, otherwise pass the bitwise OR of all the @c SVN_DIRENT_ * fields you would like to have returned to you. * * @a path is interpreted relative to the URL in @a session. * * If @a revision is @c SVN_INVALID_REVNUM (meaning 'head') and * @a *fetched_rev is not @c NULL, then this function will set * @a *fetched_rev to the actual revision that was retrieved. (Some * callers want to know, and some don't.) * * If @a props is non @c NULL, set @a *props to contain the properties of * the directory. This means @em all properties: not just ones controlled by * the user and stored in the repository fs, but non-tweakable ones * generated by the SCM system itself (e.g. 'wcprops', 'entryprops', * etc.) The keys are <tt>const char *</tt>, values are * <tt>@c svn_string_t *</tt>. * * @since New in 1.4. */svn_error_t *svn_ra_get_dir2(svn_ra_session_t *session, apr_hash_t **dirents, svn_revnum_t *fetched_rev, apr_hash_t **props, const char *path, svn_revnum_t revision, apr_uint32_t dirent_fields, apr_pool_t *pool);/** * Similar to @c svn_ra_get_dir2, but with @c SVN_DIRENT_ALL for the * @a dirent_fields parameter. * * @since New in 1.2. * * @deprecated Provided for compatibility with the 1.3 API. */svn_error_t *svn_ra_get_dir(svn_ra_session_t *session, const char *path, svn_revnum_t revision, apr_hash_t **dirents, svn_revnum_t *fetched_rev, apr_hash_t **props, apr_pool_t *pool);/** * Ask the RA layer to update a working copy. * * The client initially provides an @a update_editor/@a baton to the * RA layer; this editor contains knowledge of where the change will * begin in the working copy (when @c open_root() is called). * * In return, the client receives a @a reporter/@a report_baton. The * client then describes its working-copy revision numbers by making * calls into the @a reporter structure; the RA layer assumes that all * paths are relative to the URL used to open @a session. * * When finished, the client calls @a reporter->finish_report(). The * RA layer then does a complete drive of @a update_editor, ending with * close_edit(), to update the working copy. * * @a update_target is an optional single path component to restrict * the scope of the update to just that entry (in the directory * represented by the @a session's URL). If @a update_target is the * empty string, the entire directory is updated. * * If @a recurse is true and the target is a directory, update * recursively; otherwise, update just the target and its immediate * entries, but not its child directories (if any). * * The working copy will be updated to @a revision_to_update_to, or the * "latest" revision if this arg is invalid. * * The caller may not perform any RA operations using @a session before * finishing the report, and may not perform any RA operations using * @a session from within the editing operations of @a update_editor. * * Use @a pool for memory allocation. * * @note The reporter provided by this function does NOT supply copy- * from information to the diff editor callbacks. * * @since New in 1.2. */svn_error_t *svn_ra_do_update(svn_ra_session_t *session, const svn_ra_reporter2_t **reporter, void **report_baton, svn_revnum_t revision_to_update_to, const char *update_target, svn_boolean_t recurse, const svn_delta_editor_t *update_editor, void *update_baton, apr_pool_t *pool);/** * Ask the RA layer to 'switch' a working copy to a new * @a switch_url; it's another form of svn_ra_do_update(). * * The client initially provides a @a switch_editor/@a baton to the RA * layer; this editor contains knowledge of where the change will * begin in the working copy (when open_root() is called). * * In return, the client receives a @a reporter/@a report_baton. The * client then describes its working-copy revision numbers by making * calls into the @a reporter structure; the RA layer assumes that all * paths are relative to the URL used to create @a session_baton. * * When finished, the client calls @a reporter->finish_report(). The * RA layer then does a complete drive of @a switch_editor, ending with * close_edit(), to switch the working copy. * * @a switch_target is an optional single path component will restrict * the scope of things affected by the switch to an entry in the * directory represented by the @a session's URL, or empty if the * entire directory is meant to be switched. * * If @a recurse is true and the target is a directory, switch * recursively; otherwise, switch just the target and its immediate * entries, but not its child directories (if any). * * The working copy will be switched to @a revision_to_switch_to, or the * "latest" revision if this arg is invalid. * * The caller may not perform any RA operations using * @a session before finishing the report, and may not perform * any RA operations using @a session_baton from within the editing * operations of @a switch_editor. * * Use @a pool for memory allocation. * * @note The reporter provided by this function does NOT supply copy- * from information to the diff editor callbacks. * * @since New in 1.2. */svn_error_t *svn_ra_do_switch(svn_ra_session_t *session, const svn_ra_reporter2_t **reporter, void **report_baton, svn_revnum_t revision_to_switch_to, const char *switch_target, svn_boolean_t recurse, const char *switch_url, const svn_delta_editor_t *switch_editor, void *switch_baton, apr_pool_t *pool);/** * Ask the RA layer to describe the status of a working copy with respect * to @a revision of the repository (or HEAD, if @a revision is invalid). * * The client initially provides a @a status_editor/@a baton to the RA * layer; this editor contains knowledge of where the change will * begin in the working copy (when open_root() is called). * * In return, the client receives a @a reporter/@a report_baton. The * client then describes its working-copy revision numbers by making * calls into the @a reporter structure; the RA layer assumes that all * paths are relative to the URL used to open @a session. * * When finished, the client calls @a reporter->finish_report(). The RA * layer then does a complete drive of @a status_editor, ending with * close_edit(), to report, essentially, what would be modified in * the working copy were the client to call do_update(). * @a status_target is an optional single path component will restrict * the scope of the status report to an entry in the directory * represented by the @a session_baton's URL, or empty if the entire * directory is meant to be examined. * * If @a recurse is true and the target is a directory, get status * recursively; otherwise, get status for just the target and its * immediate entries, but not its child directories (if any). * * The caller may not perform any RA operations using @a session * before finishing the report, and may not perform any RA operations * using @a session from within the editing operations of @a status_editor. * * Use @a pool for memory allocation. * * @note The reporter provided by this function does NOT supply copy- * from information to the diff editor callbacks. * * @since New in 1.2. */svn_error_t *svn_ra_do_status(svn_ra_session_t *session, const svn_ra_reporter2_t **reporter, void **report_baton, const char *status_target, svn_revnum_t revision, svn_boolean_t recurse, const svn_delta_editor_t *status_editor, void *status_baton, apr_pool_t *pool);/** * Ask the RA layer to 'diff' a working copy against @a versus_url; * it's another form of svn_ra_do_update(). * * @note This function cannot be used to diff a single file, only a * working copy directory. See the svn_ra_do_switch() function * for more details. * * The client initially provides a @a diff_editor/@a baton to the RA * layer; this editor contains knowledge of where the common diff * root is in the working copy (when open_root() is called). * * In return, the client receives a @a reporter/@a report_baton. The * client then describes its working-copy revision numbers by making * calls into the @a reporter structure; the RA layer assumes that all * paths are relative to the URL used to open @a session. * * When finished, the client calls @a reporter->finish_report(). The * RA layer then does a complete drive of @a diff_editor, ending with * close_edit(), to transmit the diff. * * @a diff_target is an optional single path component will restrict * the scope of the diff to an entry in the directory represented by * the @a session's URL, or empty if the entire directory is meant to be * one of the diff paths. * * The working copy will be diffed against @a versus_url as it exists * in revision @a revision, or as it is in head if @a revision is * @c SVN_INVALID_REVNUM. * * Use @a ignore_ancestry to control whether or not items being * diffed will be checked for relatedness first. Unrelated items * are typically transmitted to the editor as a deletion of one thing * and the addition of another, but if this flag is @c TRUE, * unrelated items will be diffed as if they were related. * * If @a recurse is true and the target is a directory, diff * recursively; otherwise, diff just target and its immediate entries, * but not its child directories (if any). * * The caller may not perform any RA operations using @a session before * finishing the report, and may not perform any RA operations using * @a session from within the editing operations of @a diff_editor. * * @a text_deltas instructs the driver of the @a diff_editor to enable * the generation of text deltas. If @a text_deltas is FALSE the window * handler returned by apply_textdelta will be called once with a NULL * @c svn_txdelta_window_t pointer. * * Use @a pool for memory allocation. * * @note The reporter provided by this function does NOT supply copy- * from information to the diff editor callbacks. * * @since New in 1.4. */svn_error_t *svn_ra_do_diff2(svn_ra_session_t *session, const svn_ra_reporter2_t **reporter, void **report_baton, svn_revnum_t revision, const char *diff_target, svn_boolean_t recurse, svn_boolean_t ignore_ancestry, svn_boolean_t text_deltas, const char *versus_url, const svn_delta_editor_t *diff_editor, void *diff_baton, apr_pool_t *pool);/** * Similar to svn_ra_do_diff2(), but with @a text_deltas set to @c TRUE. * * @deprecated Provided for backward compatibility with the 1.3 API. */svn_error_t *svn_ra_do_diff(svn_ra_session_t *session, const svn_ra_reporter2_t **reporter, void **report_baton, svn_revnum_t revision, const char *diff_target, svn_boolean_t recurse, svn_boolean_t ignore_ancestry, const char *versus_url, const svn_delta_editor_t *diff_editor, void *diff_baton, apr_pool_t *pool);/** * Invoke @a receiver with @a receiver_baton on each log message from * @a start to @a end. @a start may be greater or less than @a end; * this just controls whether the log messages are processed in descending * or ascending revision number order. * * If @a start or @a end is @c SVN_INVALID_REVNUM, it defaults to youngest. * * If @a paths is non-null and has one or more elements, then only show * revisions in which at least one of @a paths was changed (i.e., if * file, text or props changed; if dir, props changed or an entry * was added or deleted). Each path is an <tt>const char *</tt>, relative * to the @a session's common parent. * * If @a limit is non-zero only invoke @a receiver on the first @a limit * logs. * * If @a discover_changed_paths, then each call to receiver passes a * <tt>const apr_hash_t *</tt> for the receiver's @a changed_paths argument; * the hash's keys are all the paths committed in that revision. * Otherwise, each call to receiver passes null for @a changed_paths.
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -