Subversion
Typedefs | Enumerations | Functions
Taking the diff of two hash tables.
Hash table serialization support

Taking the "diff" of two hash tables. More...

Typedefs

typedef svn_error_t *(* svn_hash_diff_func_t )(const void *key, apr_ssize_t klen, enum svn_hash_diff_key_status status, void *baton)
 Function type for expressing a key's status between two hash tables.

Enumerations

enum  svn_hash_diff_key_status {
  svn_hash_diff_key_both,
  svn_hash_diff_key_a,
  svn_hash_diff_key_b
}
 Hash key status indicator for svn_hash_diff_func_t. More...

Functions

svn_error_tsvn_hash_diff (apr_hash_t *hash_a, apr_hash_t *hash_b, svn_hash_diff_func_t diff_func, void *diff_func_baton, apr_pool_t *pool)
 Take the diff of two hashtables.

Detailed Description

Taking the "diff" of two hash tables.


Typedef Documentation

typedef svn_error_t*(* svn_hash_diff_func_t)(const void *key, apr_ssize_t klen, enum svn_hash_diff_key_status status, void *baton)

Function type for expressing a key's status between two hash tables.

Definition at line 179 of file svn_hash.h.


Enumeration Type Documentation

Hash key status indicator for svn_hash_diff_func_t.

Definition at line 164 of file svn_hash.h.


Function Documentation

svn_error_t* svn_hash_diff ( apr_hash_t *  hash_a,
apr_hash_t *  hash_b,
svn_hash_diff_func_t  diff_func,
void *  diff_func_baton,
apr_pool_t *  pool 
)

Take the diff of two hashtables.

For each key in the union of hash_a's and hash_b's keys, invoke diff_func exactly once, passing the key, the key's length, an enum svn_hash_diff_key_status indicating which table(s) the key appears in, and diff_func_baton.

Process all keys of hash_a first, then all remaining keys of hash_b.

If diff_func returns error, return that error immediately, without applying diff_func to anything else.

hash_a or hash_b or both may be NULL; treat a null table as though empty.

Use pool for temporary allocation.

 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Defines