svn_ra.h File Reference

Repository Access. More...

#include <apr_pools.h>
#include <apr_tables.h>
#include "svn_error.h"

Go to the source code of this file.

Data Structures

struct  svn_ra_reporter3_t
 The update Reporter. More...
struct  svn_ra_reporter2_t
 Similar to svn_ra_reporter3_t, but without support for depths. More...
struct  svn_ra_reporter_t
 Similar to svn_ra_reporter2_t, but without support for lock tokens. More...
struct  svn_ra_callbacks2_t
 A collection of callbacks implemented by libsvn_client which allows an RA layer to "pull" information from the client application, or possibly store information. More...
struct  svn_ra_callbacks_t
 Similar to svn_ra_callbacks2_t, except that the progress notification function and baton is missing. More...
struct  svn_ra_plugin_t
 Using this callback struct is similar to calling the newer public interface that is based on svn_ra_session_t. More...

Typedefs

typedef svn_error_t *(* svn_ra_get_wc_prop_func_t )(void *baton, const char *relpath, const char *name, const svn_string_t **value, apr_pool_t *pool)
 This is a function type which allows the RA layer to fetch working copy (WC) properties.
typedef svn_error_t *(* svn_ra_set_wc_prop_func_t )(void *baton, const char *path, const char *name, const svn_string_t *value, apr_pool_t *pool)
 This is a function type which allows the RA layer to store new working copy properties during update-like operations.
typedef svn_error_t *(* svn_ra_push_wc_prop_func_t )(void *baton, const char *path, const char *name, const svn_string_t *value, apr_pool_t *pool)
 This is a function type which allows the RA layer to store new working copy properties as part of a commit.
typedef svn_error_t *(* svn_ra_invalidate_wc_props_func_t )(void *baton, const char *path, const char *name, apr_pool_t *pool)
 This is a function type which allows the RA layer to invalidate (i.e., remove) wcprops recursively.
typedef svn_error_t *(* svn_ra_get_latest_revnum_func_t )(void *session_baton, svn_revnum_t *latest_revnum)
 A function type for retrieving the youngest revision from a repos.
typedef svn_error_t *(* svn_ra_get_client_string_func_t )(void *baton, const char **name, apr_pool_t *pool)
 A function type which allows the RA layer to ask about any customizations to the client name string.
typedef svn_error_t *(* svn_ra_file_rev_handler_t )(void *baton, const char *path, svn_revnum_t rev, apr_hash_t *rev_props, svn_txdelta_window_handler_t *delta_handler, void **delta_baton, apr_array_header_t *prop_diffs, apr_pool_t *pool)
 A callback function type for use in get_file_revs.
typedef svn_error_t *(* svn_ra_lock_callback_t )(void *baton, const char *path, svn_boolean_t do_lock, const svn_lock_t *lock, svn_error_t *ra_err, apr_pool_t *pool)
 Callback function type for locking and unlocking actions.
typedef void(* svn_ra_progress_notify_func_t )(apr_off_t progress, apr_off_t total, void *baton, apr_pool_t *pool)
 Callback function type for progress notification.
typedef svn_error_t *(* svn_ra_replay_revstart_callback_t )(svn_revnum_t revision, void *replay_baton, const svn_delta_editor_t **editor, void **edit_baton, apr_hash_t *rev_props, apr_pool_t *pool)
 Callback function type for replay_range actions.
typedef svn_error_t *(* svn_ra_replay_revfinish_callback_t )(svn_revnum_t revision, void *replay_baton, const svn_delta_editor_t *editor, void *edit_baton, apr_hash_t *rev_props, apr_pool_t *pool)
 Callback function type for replay_range actions.
typedef svn_ra_reporter3_t svn_ra_reporter3_t
 The update Reporter.
typedef svn_ra_reporter2_t svn_ra_reporter2_t
 Similar to svn_ra_reporter3_t, but without support for depths.
typedef svn_ra_reporter_t svn_ra_reporter_t
 Similar to svn_ra_reporter2_t, but without support for lock tokens.
typedef svn_ra_callbacks2_t svn_ra_callbacks2_t
 A collection of callbacks implemented by libsvn_client which allows an RA layer to "pull" information from the client application, or possibly store information.
typedef svn_ra_callbacks_t svn_ra_callbacks_t
 Similar to svn_ra_callbacks2_t, except that the progress notification function and baton is missing.
typedef svn_ra_session_t svn_ra_session_t
 A repository access session.
typedef svn_ra_plugin_t svn_ra_plugin_t
 Using this callback struct is similar to calling the newer public interface that is based on svn_ra_session_t.
typedef svn_error_t *(* svn_ra_init_func_t )(int abi_version, apr_pool_t *pool, apr_hash_t *hash)
 All "ra_FOO" implementations *must* export a function named svn_ra_FOO_init() of type svn_ra_init_func_t.

Functions

const svn_version_tsvn_ra_version (void)
 Get libsvn_ra version information.
svn_error_tsvn_ra_initialize (apr_pool_t *pool)
 Initialize the RA library.
svn_error_tsvn_ra_create_callbacks (svn_ra_callbacks2_t **callbacks, apr_pool_t *pool)
 Initialize a callback structure.
svn_error_tsvn_ra_open3 (svn_ra_session_t **session_p, const char *repos_URL, const char *uuid, const svn_ra_callbacks2_t *callbacks, void *callback_baton, apr_hash_t *config, apr_pool_t *pool)
 Open a repository session to repos_URL.
SVN_DEPRECATED svn_error_tsvn_ra_open2 (svn_ra_session_t **session_p, const char *repos_URL, const svn_ra_callbacks2_t *callbacks, void *callback_baton, apr_hash_t *config, apr_pool_t *pool)
 Similiar to svn_ra_open3(), but with uuid set to NULL.
SVN_DEPRECATED svn_error_tsvn_ra_open (svn_ra_session_t **session_p, const char *repos_URL, const svn_ra_callbacks_t *callbacks, void *callback_baton, apr_hash_t *config, apr_pool_t *pool)
svn_error_tsvn_ra_reparent (svn_ra_session_t *ra_session, const char *url, apr_pool_t *pool)
 Change the root URL of an open ra_session to point to a new path in the same repository.
svn_error_tsvn_ra_get_session_url (svn_ra_session_t *ra_session, const char **url, apr_pool_t *pool)
 Set *url to the repository URL to which ra_session was opened or most recently reparented.
svn_error_tsvn_ra_get_latest_revnum (svn_ra_session_t *session, svn_revnum_t *latest_revnum, apr_pool_t *pool)
 Get the latest revision number from the repository of session.
svn_error_tsvn_ra_get_dated_revision (svn_ra_session_t *session, svn_revnum_t *revision, apr_time_t tm, apr_pool_t *pool)
 Get the latest revision number at time tm in the repository of session.
svn_error_tsvn_ra_change_rev_prop (svn_ra_session_t *session, svn_revnum_t rev, const char *name, const svn_string_t *value, apr_pool_t *pool)
 Set the property name to value on revision rev in the repository of session.
svn_error_tsvn_ra_rev_proplist (svn_ra_session_t *session, svn_revnum_t rev, apr_hash_t **props, apr_pool_t *pool)
 Set *props to the list of unversioned properties attached to revision rev in the repository of session.
svn_error_tsvn_ra_rev_prop (svn_ra_session_t *session, svn_revnum_t rev, const char *name, svn_string_t **value, apr_pool_t *pool)
 Set *value to the value of unversioned property name attached to revision rev in the repository of session.
svn_error_tsvn_ra_get_commit_editor3 (svn_ra_session_t *session, const svn_delta_editor_t **editor, void **edit_baton, apr_hash_t *revprop_table, svn_commit_callback2_t callback, void *callback_baton, apr_hash_t *lock_tokens, svn_boolean_t keep_locks, apr_pool_t *pool)
 Set *editor and *edit_baton to an editor for committing changes to the repository of session, setting the revision properties from revprop_table.
SVN_DEPRECATED svn_error_tsvn_ra_get_commit_editor2 (svn_ra_session_t *session, const svn_delta_editor_t **editor, void **edit_baton, const char *log_msg, svn_commit_callback2_t callback, void *callback_baton, apr_hash_t *lock_tokens, svn_boolean_t keep_locks, apr_pool_t *pool)
 Same as svn_ra_get_commit_editor3(), but with revprop_table set to a hash containing the SVN_PROP_REVISION_LOG property set to the value of log_msg.
SVN_DEPRECATED svn_error_tsvn_ra_get_commit_editor (svn_ra_session_t *session, const svn_delta_editor_t **editor, void **edit_baton, const char *log_msg, svn_commit_callback_t callback, void *callback_baton, apr_hash_t *lock_tokens, svn_boolean_t keep_locks, apr_pool_t *pool)
 Same as svn_ra_get_commit_editor2(), but uses svn_commit_callback_t.
svn_error_tsvn_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)
 Fetch the contents and properties of file path at revision.
svn_error_tsvn_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)
 If dirents is non NULL, set *dirents to contain all the entries of directory path at revision.
SVN_DEPRECATED svn_error_tsvn_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)
 Similar to svn_ra_get_dir2, but with SVN_DIRENT_ALL for the dirent_fields parameter.
svn_error_tsvn_ra_get_mergeinfo (svn_ra_session_t *session, svn_mergeinfo_catalog_t *catalog, const apr_array_header_t *paths, svn_revnum_t revision, svn_mergeinfo_inheritance_t inherit, svn_boolean_t include_descendants, apr_pool_t *pool)
 Set *catalog to a mergeinfo catalog for the paths in paths.
svn_error_tsvn_ra_do_update2 (svn_ra_session_t *session, const svn_ra_reporter3_t **reporter, void **report_baton, svn_revnum_t revision_to_update_to, const char *update_target, svn_depth_t depth, svn_boolean_t send_copyfrom_args, const svn_delta_editor_t *update_editor, void *update_baton, apr_pool_t *pool)
 Ask the RA layer to update a working copy.
SVN_DEPRECATED svn_error_tsvn_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)
 Similar to svn_ra_do_update2(), but taking svn_ra_reporter2_t instead of svn_ra_reporter3_t; if recurse is true, pass svn_depth_infinity for depth, else pass svn_depth_files; and with send_copyfrom_args always false.
svn_error_tsvn_ra_do_switch2 (svn_ra_session_t *session, const svn_ra_reporter3_t **reporter, void **report_baton, svn_revnum_t revision_to_switch_to, const char *switch_target, svn_depth_t depth, const char *switch_url, const svn_delta_editor_t *switch_editor, void *switch_baton, apr_pool_t *pool)
 Ask the RA layer to 'switch' a working copy to a new switch_url; it's another form of svn_ra_do_update().
SVN_DEPRECATED svn_error_tsvn_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)
 Similar to svn_ra_do_switch2(), but taking svn_ra_reporter2_t instead of svn_ra_reporter3_t, and therefore only able to report svn_depth_infinity for depths.
svn_error_tsvn_ra_do_status2 (svn_ra_session_t *session, const svn_ra_reporter3_t **reporter, void **report_baton, const char *status_target, svn_revnum_t revision, svn_depth_t depth, const svn_delta_editor_t *status_editor, void *status_baton, apr_pool_t *pool)
 Ask the RA layer to describe the status of a working copy with respect to revision of the repository (or HEAD, if revision is invalid).
SVN_DEPRECATED svn_error_tsvn_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)
 Similar to svn_ra_do_status2(), but taking svn_ra_reporter2_t instead of svn_ra_reporter3_t, and therefore only able to report svn_depth_infinity for depths.
svn_error_tsvn_ra_do_diff3 (svn_ra_session_t *session, const svn_ra_reporter3_t **reporter, void **report_baton, svn_revnum_t revision, const char *diff_target, svn_depth_t depth, 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)
 Ask the RA layer to 'diff' a working copy against versus_url; it's another form of svn_ra_do_update2().
SVN_DEPRECATED svn_error_tsvn_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_diff3(), but taking svn_ra_reporter2_t instead of svn_ra_reporter3_t, and therefore only able to report svn_depth_infinity for depths.
SVN_DEPRECATED svn_error_tsvn_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)
 Similar to svn_ra_do_diff2(), but with text_deltas set to TRUE.
svn_error_tsvn_ra_get_log2 (svn_ra_session_t *session, const apr_array_header_t *paths, svn_revnum_t start, svn_revnum_t end, int limit, svn_boolean_t discover_changed_paths, svn_boolean_t strict_node_history, svn_boolean_t include_merged_revisions, const apr_array_header_t *revprops, svn_log_entry_receiver_t receiver, void *receiver_baton, apr_pool_t *pool)
 Invoke receiver with receiver_baton on each log message from start to end.
SVN_DEPRECATED svn_error_tsvn_ra_get_log (svn_ra_session_t *session, const apr_array_header_t *paths, svn_revnum_t start, svn_revnum_t end, int limit, svn_boolean_t discover_changed_paths, svn_boolean_t strict_node_history, svn_log_message_receiver_t receiver, void *receiver_baton, apr_pool_t *pool)
 Similar to svn_ra_get_log2(), but uses svn_log_message_receiver_t instead of svn_log_entry_receiver_t.
svn_error_tsvn_ra_check_path (svn_ra_session_t *session, const char *path, svn_revnum_t revision, svn_node_kind_t *kind, apr_pool_t *pool)
 Set *kind to the node kind associated with path at revision.
svn_error_tsvn_ra_stat (svn_ra_session_t *session, const char *path, svn_revnum_t revision, svn_dirent_t **dirent, apr_pool_t *pool)
 Set *dirent to an svn_dirent_t associated with path at revision.
svn_error_tsvn_ra_get_uuid2 (svn_ra_session_t *session, const char **uuid, apr_pool_t *pool)
 Set *uuid to the repository's UUID, allocated in pool.
SVN_DEPRECATED svn_error_tsvn_ra_get_uuid (svn_ra_session_t *session, const char **uuid, apr_pool_t *pool)
 Similar to svn_ra_get_uuid2(), but returns the value allocated in session's pool.
svn_error_tsvn_ra_get_repos_root2 (svn_ra_session_t *session, const char **url, apr_pool_t *pool)
 Set *url to the repository's root URL, allocated in pool.
SVN_DEPRECATED svn_error_tsvn_ra_get_repos_root (svn_ra_session_t *session, const char **url, apr_pool_t *pool)
 Similar to svn_ra_get_repos_root2(), but returns the value allocated in session's pool.
svn_error_tsvn_ra_get_locations (svn_ra_session_t *session, apr_hash_t **locations, const char *path, svn_revnum_t peg_revision, apr_array_header_t *location_revisions, apr_pool_t *pool)
 Set *locations to the locations (at the repository revisions location_revisions) of the file identified by path in peg_revision.
svn_error_tsvn_ra_get_location_segments (svn_ra_session_t *session, const char *path, svn_revnum_t peg_revision, svn_revnum_t start_rev, svn_revnum_t end_rev, svn_location_segment_receiver_t receiver, void *receiver_baton, apr_pool_t *pool)
 Call receiver (with receiver_baton) for each segment in the location history of path in peg_revision, working backwards in time from start_rev to end_rev.
svn_error_tsvn_ra_get_file_revs2 (svn_ra_session_t *session, const char *path, svn_revnum_t start, svn_revnum_t end, svn_boolean_t include_merged_revisions, svn_file_rev_handler_t handler, void *handler_baton, apr_pool_t *pool)
 Retrieve a subset of the interesting revisions of a file path as seen in revision end (see svn_fs_history_prev() for a definition of "interesting revisions").
SVN_DEPRECATED svn_error_tsvn_ra_get_file_revs (svn_ra_session_t *session, const char *path, svn_revnum_t start, svn_revnum_t end, svn_ra_file_rev_handler_t handler, void *handler_baton, apr_pool_t *pool)
 Similiar to svn_ra_get_file_revs2(), but with include_merged_revisions set to FALSE.
svn_error_tsvn_ra_lock (svn_ra_session_t *session, apr_hash_t *path_revs, const char *comment, svn_boolean_t steal_lock, svn_ra_lock_callback_t lock_func, void *lock_baton, apr_pool_t *pool)
 Lock each path in path_revs, which is a hash whose keys are the paths to be locked, and whose values are the corresponding base revisions for each path.
svn_error_tsvn_ra_unlock (svn_ra_session_t *session, apr_hash_t *path_tokens, svn_boolean_t break_lock, svn_ra_lock_callback_t lock_func, void *lock_baton, apr_pool_t *pool)
 Remove the repository lock for each path in path_tokens.
svn_error_tsvn_ra_get_lock (svn_ra_session_t *session, svn_lock_t **lock, const char *path, apr_pool_t *pool)
 If path is locked, set *lock to an svn_lock_t which represents the lock, allocated in pool.
svn_error_tsvn_ra_get_locks (svn_ra_session_t *session, apr_hash_t **locks, const char *path, apr_pool_t *pool)
 Set *locks to a hashtable which represents all locks on or below path.
svn_error_tsvn_ra_replay_range (svn_ra_session_t *session, svn_revnum_t start_revision, svn_revnum_t end_revision, svn_revnum_t low_water_mark, svn_boolean_t send_deltas, svn_ra_replay_revstart_callback_t revstart_func, svn_ra_replay_revfinish_callback_t revfinish_func, void *replay_baton, apr_pool_t *pool)
 Replay the changes from a range of revisions between start_revision and end_revision.
svn_error_tsvn_ra_replay (svn_ra_session_t *session, svn_revnum_t revision, svn_revnum_t low_water_mark, svn_boolean_t send_deltas, const svn_delta_editor_t *editor, void *edit_baton, apr_pool_t *pool)
 Replay the changes from revision through editor and edit_baton.
svn_error_tsvn_ra_has_capability (svn_ra_session_t *session, svn_boolean_t *has, const char *capability, apr_pool_t *pool)
 Set *has to TRUE if the server represented by session has capability (one of the capabilities beginning with "SVN_RA_CAPABILITY_"), else set *has to FALSE.
svn_error_tsvn_ra_print_modules (svn_stringbuf_t *output, apr_pool_t *pool)
 Append a textual list of all available RA modules to the stringbuf output.
SVN_DEPRECATED svn_error_tsvn_ra_print_ra_libraries (svn_stringbuf_t **descriptions, void *ra_baton, apr_pool_t *pool)
 Similar to svn_ra_print_modules().
SVN_DEPRECATED svn_error_tsvn_ra_dav_init (int abi_version, apr_pool_t *pool, apr_hash_t *hash)
 Initialize libsvn_ra_neon.
SVN_DEPRECATED svn_error_tsvn_ra_local_init (int abi_version, apr_pool_t *pool, apr_hash_t *hash)
 Initialize libsvn_ra_local.
SVN_DEPRECATED svn_error_tsvn_ra_svn_init (int abi_version, apr_pool_t *pool, apr_hash_t *hash)
 Initialize libsvn_ra_svn.
SVN_DEPRECATED svn_error_tsvn_ra_serf_init (int abi_version, apr_pool_t *pool, apr_hash_t *hash)
 Initialize libsvn_ra_serf.
SVN_DEPRECATED svn_error_tsvn_ra_init_ra_libs (void **ra_baton, apr_pool_t *pool)
 Initialize the compatibility wrapper, using pool for any allocations.
SVN_DEPRECATED svn_error_tsvn_ra_get_ra_library (svn_ra_plugin_t **library, void *ra_baton, const char *url, apr_pool_t *pool)
 Return an RA vtable-library which can handle URL.


Detailed Description

Repository Access.

Definition in file svn_ra.h.


Typedef Documentation

typedef struct svn_ra_callbacks2_t svn_ra_callbacks2_t
 

A collection of callbacks implemented by libsvn_client which allows an RA layer to "pull" information from the client application, or possibly store information.

libsvn_client passes this vtable to svn_ra_open3().

Each routine takes a callback_baton originally provided with the vtable.

Clients must use svn_ra_create_callbacks() to allocate and initialize this structure.

Since:
New in 1.3.

typedef struct svn_ra_callbacks_t svn_ra_callbacks_t
 

Similar to svn_ra_callbacks2_t, except that the progress notification function and baton is missing.

Deprecated:
Provided for backward compatibility with the 1.2 API.

typedef svn_error_t*(* svn_ra_file_rev_handler_t)(void *baton, const char *path, svn_revnum_t rev, apr_hash_t *rev_props, svn_txdelta_window_handler_t *delta_handler, void **delta_baton, apr_array_header_t *prop_diffs, apr_pool_t *pool)
 

A callback function type for use in get_file_revs.

baton is provided by the caller, path is the pathname of the file in revision rev and rev_props are the revision properties. If delta_handler and delta_baton are non-NULL, they may be set to a handler/baton which will be called with the delta between the previous revision and this one after the return of this callback. They may be left as NULL/NULL. prop_diffs is an array of svn_prop_t elements indicating the property delta for this and the previous revision. pool may be used for temporary allocations, but you can't rely on objects allocated to live outside of this particular call and the immediately following calls to *delta_handler, if any.

Since:
New in 1.1.

Definition at line 150 of file svn_ra.h.

typedef svn_error_t*(* svn_ra_get_client_string_func_t)(void *baton, const char **name, apr_pool_t *pool)
 

A function type which allows the RA layer to ask about any customizations to the client name string.

This is primarily used by HTTP-based RA layers wishing to extend the string reported to Apache/mod_dav_svn via the User-agent HTTP header.

Definition at line 128 of file svn_ra.h.

typedef svn_error_t*(* svn_ra_get_wc_prop_func_t)(void *baton, const char *relpath, const char *name, const svn_string_t **value, apr_pool_t *pool)
 

This is a function type which allows the RA layer to fetch working copy (WC) properties.

The baton is provided along with the function pointer and should be passed back in. This will be the callback_baton or the close_baton as appropriate.

path is relative to the "root" of the session, defined by the repos_URL passed to svn_ra_open3() vtable call.

name is the name of the property to fetch. If the property is present, then it is returned in value. Otherwise, *value is set to NULL.

Definition at line 67 of file svn_ra.h.

typedef svn_error_t*(* svn_ra_init_func_t)(int abi_version, apr_pool_t *pool, apr_hash_t *hash)
 

All "ra_FOO" implementations *must* export a function named svn_ra_FOO_init() of type svn_ra_init_func_t.

When called by libsvn_client, this routine adds an entry (or entries) to the hash table for any URL schemes it handles. The hash value must be of type (svn_ra_plugin_t *). pool is a pool for allocating configuration / one-time data.

This type is defined to use the "C Calling Conventions" to ensure that abi_version is the first parameter. The RA plugin must check that value before accessing the other parameters.

### need to force this to be __cdecl on Windows... how??

Deprecated:
Provided for backward compatibility with the 1.1 API.

Definition at line 2083 of file svn_ra.h.

typedef svn_error_t*(* svn_ra_invalidate_wc_props_func_t)(void *baton, const char *path, const char *name, apr_pool_t *pool)
 

This is a function type which allows the RA layer to invalidate (i.e., remove) wcprops recursively.

See the documentation for svn_ra_get_wc_prop_func_t for baton, path, and name.

Unlike svn_ra_push_wc_prop_func_t, this has immediate effect. If it returns success, the wcprops have been removed.

Definition at line 112 of file svn_ra.h.

typedef svn_error_t*(* svn_ra_lock_callback_t)(void *baton, const char *path, svn_boolean_t do_lock, const svn_lock_t *lock, svn_error_t *ra_err, apr_pool_t *pool)
 

Callback function type for locking and unlocking actions.

Since:
New in 1.2.
do_lock is TRUE when locking path, and FALSE otherwise.

lock is a lock for path or NULL if do_lock is FALSE or ra_err is non-NULL.

ra_err is NULL unless the ra layer encounters a locking related error which it passes back for notification purposes. The caller is responsible for clearing ra_err after the callback is run.

baton is a closure object; it should be provided by the implementation, and passed by the caller. pool may be used for temporary allocation.

Definition at line 178 of file svn_ra.h.

typedef struct svn_ra_plugin_t svn_ra_plugin_t
 

Using this callback struct is similar to calling the newer public interface that is based on svn_ra_session_t.

Deprecated:
Provided for backward compatibility with the 1.1 API.

typedef void(* svn_ra_progress_notify_func_t)(apr_off_t progress, apr_off_t total, void *baton, apr_pool_t *pool)
 

Callback function type for progress notification.

progress is the number of bytes already transferred, total is the total number of bytes to transfer or -1 if it's not known, baton is the callback baton.

Since:
New in 1.3.

Definition at line 194 of file svn_ra.h.

typedef svn_error_t*(* svn_ra_push_wc_prop_func_t)(void *baton, const char *path, const char *name, const svn_string_t *value, apr_pool_t *pool)
 

This is a function type which allows the RA layer to store new working copy properties as part of a commit.

See the comments for svn_ra_get_wc_prop_func_t for baton, path, and name. The value is the value that will be stored for the property; a NULL value means the property will be deleted.

Note that this might not actually store the new property before returning, but instead schedule it to be changed as part of post-commit processing (in which case a successful commit means the properties got written). Thus, during the commit, it is possible to invoke this function to set a new value for a wc prop, then read the wc prop back from the working copy and get the *old* value. Callers beware.

Definition at line 99 of file svn_ra.h.

typedef svn_error_t*(* svn_ra_replay_revfinish_callback_t)(svn_revnum_t revision, void *replay_baton, const svn_delta_editor_t *editor, void *edit_baton, apr_hash_t *rev_props, apr_pool_t *pool)
 

Callback function type for replay_range actions.

This callback function should close the editor.

revision is the target revision number of the received replay report.

editor and edit_baton should provided by the callback implementation.

replay_baton is the baton as originally passed to replay_range.

revprops contains key/value pairs for each revision properties for this revision.

Since:
New in 1.5.

Definition at line 241 of file svn_ra.h.

typedef svn_error_t*(* svn_ra_replay_revstart_callback_t)(svn_revnum_t revision, void *replay_baton, const svn_delta_editor_t **editor, void **edit_baton, apr_hash_t *rev_props, apr_pool_t *pool)
 

Callback function type for replay_range actions.

This callback function should provide replay_range with an editor which will be driven with the received replay reports from the master repository.

revision is the target revision number of the received replay report.

editor and edit_baton should provided by the callback implementation.

replay_baton is the baton as originally passed to replay_range.

revprops contains key/value pairs for each revision properties for this revision.

Since:
New in 1.5.

Definition at line 217 of file svn_ra.h.

typedef struct svn_ra_reporter2_t svn_ra_reporter2_t
 

Similar to svn_ra_reporter3_t, but without support for depths.

Deprecated:
Provided for backward compatibility with the 1.4 API.

typedef struct svn_ra_reporter3_t svn_ra_reporter3_t
 

The update Reporter.

A vtable structure which allows a working copy to describe a subset (or possibly all) of its working-copy to an RA layer, for the purposes of an update, switch, status, or diff operation.

Paths for report calls are relative to the target (not the anchor) of the operation. Report calls must be made in depth-first order: parents before children, all children of a parent before any siblings of the parent. The first report call must be a set_path with a path argument of "" and a valid revision. (If the target of the operation is locally deleted or missing, use the anchor's revision.) If the target of the operation is deleted or switched relative to the anchor, follow up the initial set_path call with a link_path or delete_path call with a path argument of "" to indicate that. In no other case may there be two report descriptions for the same path. If the target of the operation is a locally added file or directory (which previously did not exist), it may be reported as having revision 0 or as having the parent directory's revision.

Since:
New in 1.5.

typedef struct svn_ra_reporter_t svn_ra_reporter_t
 

Similar to svn_ra_reporter2_t, but without support for lock tokens.

Deprecated:
Provided for backward compatibility with the 1.1 API.

typedef struct svn_ra_session_t svn_ra_session_t
 

A repository access session.

This object is used to perform requests to a repository, identified by an URL.

Since:
New in 1.2.

Definition at line 570 of file svn_ra.h.

typedef svn_error_t*(* svn_ra_set_wc_prop_func_t)(void *baton, const char *path, const char *name, const svn_string_t *value, apr_pool_t *pool)
 

This is a function type which allows the RA layer to store new working copy properties during update-like operations.

See the comments for svn_ra_get_wc_prop_func_t for baton, path, and name. The value is the value that will be stored for the property; a NULL value means the property will be deleted.

Definition at line 79 of file svn_ra.h.


Function Documentation

svn_error_t* svn_ra_change_rev_prop svn_ra_session_t session,
svn_revnum_t  rev,
const char *  name,
const svn_string_t value,
apr_pool_t *  pool
 

Set the property name to value on revision rev in the repository of session.

If value is NULL, delete the named revision property.

Please note that properties attached to revisions are unversioned.

Use pool for memory allocation.

Since:
New in 1.2.

svn_error_t* svn_ra_check_path svn_ra_session_t session,
const char *  path,
svn_revnum_t  revision,
svn_node_kind_t kind,
apr_pool_t *  pool
 

Set *kind to the node kind associated with path at revision.

If path does not exist under revision, set *kind to svn_node_none. path is relative to the session's parent URL.

Use pool for memory allocation.

Since:
New in 1.2.

svn_error_t* svn_ra_create_callbacks svn_ra_callbacks2_t **  callbacks,
apr_pool_t *  pool
 

Initialize a callback structure.

Set *callbacks to a ra callbacks object, allocated in pool.

Clients must use this function to allocate and initialize svn_ra_callbacks2_t structures.

Since:
New in 1.3.

SVN_DEPRECATED svn_error_t* svn_ra_dav_init int  abi_version,
apr_pool_t *  pool,
apr_hash_t *  hash
 

Initialize libsvn_ra_neon.

Deprecated:
Provided for backward compatibility with the 1.1 API.

SVN_DEPRECATED 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
 

Similar to svn_ra_do_diff2(), but with text_deltas set to TRUE.

Deprecated:
Provided for backward compatibility with the 1.3 API.

SVN_DEPRECATED 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_diff3(), but taking svn_ra_reporter2_t instead of svn_ra_reporter3_t, and therefore only able to report svn_depth_infinity for depths.

Perform the diff according to recurse: if TRUE, then depth is svn_depth_infinity, else it is svn_depth_files.

Deprecated:
Provided for compatibility with the 1.4 API.

svn_error_t* svn_ra_do_diff3 svn_ra_session_t session,
const svn_ra_reporter3_t **  reporter,
void **  report_baton,
svn_revnum_t  revision,
const char *  diff_target,
svn_depth_t  depth,
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
 

Ask the RA layer to 'diff' a working copy against versus_url; it's another form of svn_ra_do_update2().

Note:
This function cannot be used to diff a single file, only a working copy directory. See the svn_ra_do_switch2() function for more details.
The client initially provides a diff_editor/diff_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 reporter/report_baton. The client then describes its working copy by making calls into the reporter.

When finished, the client calls reporter->finish_report(). The RA layer then does a complete drive of diff_editor, ending with close_edit(), to transmit the diff.

diff_target is an optional single path component will restrict the scope of the diff to an entry in the directory represented by the 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 versus_url as it exists in revision revision, or as it is in head if revision is SVN_INVALID_REVNUM.

Use 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 TRUE, unrelated items will be diffed as if they were related.

Diff only as deeply as depth indicates.

The caller may not perform any RA operations using session before finishing the report, and may not perform any RA operations using session from within the editing operations of diff_editor.

text_deltas instructs the driver of the diff_editor to enable the generation of text deltas. If text_deltas is FALSE the window handler returned by apply_textdelta will be called once with a NULL svn_txdelta_window_t pointer.

Use pool for memory allocation.

Note:
The reporter provided by this function does NOT supply copy- from information to the diff editor callbacks.

In order to prevent pre-1.5 servers from doing more work than needed, and sending too much data back, a pre-1.5 'recurse' directive may be sent to the server, based on depth.

Since:
New in 1.5.

SVN_DEPRECATED 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
 

Similar to svn_ra_do_status2(), but taking svn_ra_reporter2_t instead of svn_ra_reporter3_t, and therefore only able to report svn_depth_infinity for depths.

The status operation itself is performed according to recurse: if TRUE, then depth is svn_depth_infinity, else it is svn_depth_immediates.

Deprecated:
Provided for compatibility with the 1.4 API.

svn_error_t* svn_ra_do_status2 svn_ra_session_t session,
const svn_ra_reporter3_t **  reporter,
void **  report_baton,
const char *  status_target,
svn_revnum_t  revision,
svn_depth_t  depth,
const svn_delta_editor_t status_editor,
void *  status_baton,
apr_pool_t *  pool
 

Ask the RA layer to describe the status of a working copy with respect to revision of the repository (or HEAD, if revision is invalid).

The client initially provides a status_editor/status_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 reporter/report_baton. The client then describes its working copy by making calls into the reporter.

When finished, the client calls reporter->finish_report(). The RA layer then does a complete drive of status_editor, ending with close_edit(), to report, essentially, what would be modified in the working copy were the client to call do_update(). 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 session's URL, or empty if the entire directory is meant to be examined.

Get status only as deeply as depth indicates.

The caller may not perform any RA operations using session before finishing the report, and may not perform any RA operations using session from within the editing operations of status_editor.

Use pool for memory allocation.

Note:
The reporter provided by this function does NOT supply copy- from information to the diff editor callbacks.

In order to prevent pre-1.5 servers from doing more work than needed, and sending too much data back, a pre-1.5 'recurse' directive may be sent to the server, based on depth.

Since:
New in 1.5.

SVN_DEPRECATED 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
 

Similar to svn_ra_do_switch2(), but taking svn_ra_reporter2_t instead of svn_ra_reporter3_t, and therefore only able to report svn_depth_infinity for depths.

The switch itself is performed according to recurse: if TRUE, then use svn_depth_infinity for depth, else use svn_depth_files.

Deprecated:
Provided for compatibility with the 1.4 API.

svn_error_t* svn_ra_do_switch2 svn_ra_session_t session,
const svn_ra_reporter3_t **  reporter,
void **  report_baton,
svn_revnum_t  revision_to_switch_to,
const char *  switch_target,
svn_depth_t  depth,
const char *  switch_url,
const svn_delta_editor_t switch_editor,
void *  switch_baton,
apr_pool_t *  pool
 

Ask the RA layer to 'switch' a working copy to a new switch_url; it's another form of svn_ra_do_update().

The client initially provides a switch_editor/switch_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 reporter/report_baton. The client then describes its working copy by making calls into the reporter.

When finished, the client calls reporter->finish_report(). The RA layer then does a complete drive of switch_editor, ending with close_edit(), to switch the working copy.

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 session's URL, or empty if the entire directory is meant to be switched.

Switch the target only as deeply as depth indicates.

The working copy will be switched to revision_to_switch_to, or the "latest" revision if this arg is invalid.

The caller may not perform any RA operations using session before finishing the report, and may not perform any RA operations using session from within the editing operations of switch_editor.

Use pool for memory allocation.

Note:
The reporter provided by this function does NOT supply copy- from information to the diff editor callbacks.

In order to prevent pre-1.5 servers from doing more work than needed, and sending too much data back, a pre-1.5 'recurse' directive may be sent to the server, based on depth.

Since:
New in 1.5.

SVN_DEPRECATED 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
 

Similar to svn_ra_do_update2(), but taking svn_ra_reporter2_t instead of svn_ra_reporter3_t; if recurse is true, pass svn_depth_infinity for depth, else pass svn_depth_files; and with send_copyfrom_args always false.

Deprecated:
Provided for compatibility with the 1.4 API.

svn_error_t* svn_ra_do_update2 svn_ra_session_t session,
const svn_ra_reporter3_t **  reporter,
void **  report_baton,
svn_revnum_t  revision_to_update_to,
const char *  update_target,
svn_depth_t  depth,
svn_boolean_t  send_copyfrom_args,
const svn_delta_editor_t update_editor,
void *  update_baton,
apr_pool_t *  pool
 

Ask the RA layer to update a working copy.

The client initially provides an update_editor/update_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 reporter/report_baton. The client then describes its working copy by making calls into the reporter.

When finished, the client calls reporter->finish_report(). The RA layer then does a complete drive of update_editor, ending with update_editor->close_edit(), to update the working copy.

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 session's URL). If update_target is the empty string, the entire directory is updated.

Update the target only as deepl