GME  13
svn_mergeinfo.h
Go to the documentation of this file.
00001 
00028 #ifndef SVN_MERGEINFO_H
00029 #define SVN_MERGEINFO_H
00030 
00031 #include <apr_pools.h>
00032 #include <apr_tables.h>  /* for apr_array_header_t */
00033 #include <apr_hash.h>
00034 
00035 #include "svn_types.h"
00036 #include "svn_string.h"  /* for svn_string_t */
00037 
00038 
00039 #ifdef __cplusplus
00040 extern "C" {
00041 #endif /* __cplusplus */
00042 
00105 /* Suffix for SVN_PROP_MERGEINFO revision ranges indicating a given
00106    range is non-inheritable. */
00107 #define SVN_MERGEINFO_NONINHERITABLE_STR "*"
00108 
00142 typedef apr_array_header_t svn_rangelist_t;
00143 typedef apr_hash_t *svn_mergeinfo_t;
00144 typedef apr_hash_t *svn_mergeinfo_catalog_t;
00145 
00165 svn_error_t *
00166 svn_mergeinfo_parse(svn_mergeinfo_t *mergeinfo, const char *input,
00167                     apr_pool_t *pool);
00168 
00192 svn_error_t *
00193 svn_mergeinfo_diff2(svn_mergeinfo_t *deleted, svn_mergeinfo_t *added,
00194                     svn_mergeinfo_t mergefrom, svn_mergeinfo_t mergeto,
00195                     svn_boolean_t consider_inheritance,
00196                     apr_pool_t *result_pool,
00197                     apr_pool_t *scratch_pool);
00198 
00204 SVN_DEPRECATED
00205 svn_error_t *
00206 svn_mergeinfo_diff(svn_mergeinfo_t *deleted, svn_mergeinfo_t *added,
00207                    svn_mergeinfo_t mergefrom, svn_mergeinfo_t mergeto,
00208                    svn_boolean_t consider_inheritance,
00209                    apr_pool_t *pool);
00210 
00228 svn_error_t *
00229 svn_mergeinfo_merge2(svn_mergeinfo_t mergeinfo,
00230                      svn_mergeinfo_t changes,
00231                      apr_pool_t *result_pool,
00232                      apr_pool_t *scratch_pool);
00233 
00238 SVN_DEPRECATED
00239 svn_error_t *
00240 svn_mergeinfo_merge(svn_mergeinfo_t mergeinfo,
00241                     svn_mergeinfo_t changes,
00242                     apr_pool_t *pool);
00243 
00253 svn_error_t *
00254 svn_mergeinfo_catalog_merge(svn_mergeinfo_catalog_t mergeinfo_catalog,
00255                             svn_mergeinfo_catalog_t changes_catalog,
00256                             apr_pool_t *result_pool,
00257                             apr_pool_t *scratch_pool);
00258 
00263 SVN_DEPRECATED
00264 svn_error_t *
00265 svn_mergeinfo_remove(svn_mergeinfo_t *mergeinfo, svn_mergeinfo_t eraser,
00266                      svn_mergeinfo_t whiteboard, apr_pool_t *pool);
00267 
00279 svn_error_t *
00280 svn_mergeinfo_remove2(svn_mergeinfo_t *mergeinfo,
00281                       svn_mergeinfo_t eraser,
00282                       svn_mergeinfo_t whiteboard,
00283                       svn_boolean_t consider_inheritance,
00284                       apr_pool_t *result_pool,
00285                       apr_pool_t *scratch_pool);
00286 
00298 svn_error_t *
00299 svn_rangelist_diff(svn_rangelist_t **deleted, svn_rangelist_t **added,
00300                    const svn_rangelist_t *from, const svn_rangelist_t *to,
00301                    svn_boolean_t consider_inheritance,
00302                    apr_pool_t *pool);
00303 
00325 svn_error_t *
00326 svn_rangelist_merge2(svn_rangelist_t *rangelist,
00327                      const svn_rangelist_t *changes,
00328                      apr_pool_t *result_pool,
00329                      apr_pool_t *scratch_pool);
00330 
00343 SVN_DEPRECATED
00344 svn_error_t *
00345 svn_rangelist_merge(svn_rangelist_t **rangelist,
00346                     const svn_rangelist_t *changes,
00347                     apr_pool_t *pool);
00348 
00362 svn_error_t *
00363 svn_rangelist_remove(svn_rangelist_t **output, const svn_rangelist_t *eraser,
00364                      const svn_rangelist_t *whiteboard,
00365                      svn_boolean_t consider_inheritance,
00366                      apr_pool_t *pool);
00367 
00379 svn_error_t *
00380 svn_mergeinfo_intersect2(svn_mergeinfo_t *mergeinfo,
00381                          svn_mergeinfo_t mergeinfo1,
00382                          svn_mergeinfo_t mergeinfo2,
00383                          svn_boolean_t consider_inheritance,
00384                          apr_pool_t *result_pool,
00385                          apr_pool_t *scratch_pool);
00386 
00391 SVN_DEPRECATED
00392 svn_error_t *
00393 svn_mergeinfo_intersect(svn_mergeinfo_t *mergeinfo,
00394                         svn_mergeinfo_t mergeinfo1,
00395                         svn_mergeinfo_t mergeinfo2,
00396                         apr_pool_t *pool);
00397 
00416 svn_error_t *
00417 svn_rangelist_intersect(svn_rangelist_t **rangelist,
00418                         const svn_rangelist_t *rangelist1,
00419                         const svn_rangelist_t *rangelist2,
00420                         svn_boolean_t consider_inheritance,
00421                         apr_pool_t *pool);
00422 
00433 svn_error_t *
00434 svn_rangelist_reverse(svn_rangelist_t *rangelist, apr_pool_t *pool);
00435 
00442 svn_error_t *
00443 svn_rangelist_to_string(svn_string_t **output,
00444                         const svn_rangelist_t *rangelist,
00445                         apr_pool_t *pool);
00446 
00458 svn_error_t *
00459 svn_rangelist_inheritable2(svn_rangelist_t **inheritable_rangelist,
00460                            const svn_rangelist_t *rangelist,
00461                            svn_revnum_t start,
00462                            svn_revnum_t end,
00463                            svn_boolean_t inheritable,
00464                            apr_pool_t *result_pool,
00465                            apr_pool_t *scratch_pool);
00466 
00472 SVN_DEPRECATED
00473 svn_error_t *
00474 svn_rangelist_inheritable(svn_rangelist_t **inheritable_rangelist,
00475                           const svn_rangelist_t *rangelist,
00476                           svn_revnum_t start,
00477                           svn_revnum_t end,
00478                           apr_pool_t *pool);
00479 
00494 svn_error_t *
00495 svn_mergeinfo_inheritable2(svn_mergeinfo_t *inheritable_mergeinfo,
00496                            svn_mergeinfo_t mergeinfo,
00497                            const char *path,
00498                            svn_revnum_t start,
00499                            svn_revnum_t end,
00500                            svn_boolean_t inheritable,
00501                            apr_pool_t *result_pool,
00502                            apr_pool_t *scratch_pool);
00503 
00509 SVN_DEPRECATED
00510 svn_error_t *
00511 svn_mergeinfo_inheritable(svn_mergeinfo_t *inheritable_mergeinfo,
00512                           svn_mergeinfo_t mergeinfo,
00513                           const char *path,
00514                           svn_revnum_t start,
00515                           svn_revnum_t end,
00516                           apr_pool_t *pool);
00517 
00527 svn_error_t *
00528 svn_mergeinfo_to_string(svn_string_t **output,
00529                         svn_mergeinfo_t mergeinput,
00530                         apr_pool_t *pool);
00531 
00540 svn_error_t *
00541 svn_mergeinfo_sort(svn_mergeinfo_t mergeinfo, apr_pool_t *pool);
00542 
00547 svn_mergeinfo_catalog_t
00548 svn_mergeinfo_catalog_dup(svn_mergeinfo_catalog_t mergeinfo_catalog,
00549                           apr_pool_t *pool);
00550 
00555 svn_mergeinfo_t
00556 svn_mergeinfo_dup(svn_mergeinfo_t mergeinfo, apr_pool_t *pool);
00557 
00562 svn_rangelist_t *
00563 svn_rangelist_dup(const svn_rangelist_t *rangelist, apr_pool_t *pool);
00564 
00565 
00571 typedef enum svn_mergeinfo_inheritance_t
00572 {
00574   svn_mergeinfo_explicit,
00575 
00579   svn_mergeinfo_inherited,
00580 
00584   svn_mergeinfo_nearest_ancestor
00585 } svn_mergeinfo_inheritance_t;
00586 
00594 const char *
00595 svn_inheritance_to_word(svn_mergeinfo_inheritance_t inherit);
00596 
00597 
00604 svn_mergeinfo_inheritance_t
00605 svn_inheritance_from_word(const char *word);
00606 
00607 
00608 #ifdef __cplusplus
00609 }
00610 #endif /* __cplusplus */
00611 
00612 #endif /* SVN_MERGEINFO_H */