subversion-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From julianf...@apache.org
Subject svn commit: r1676469 - in /subversion/branches/move-tracking-2/subversion: include/private/svn_branch.h libsvn_delta/branch.c libsvn_delta/compat3e.c svnmover/svnmover.c
Date Tue, 28 Apr 2015 10:46:31 GMT
Author: julianfoad
Date: Tue Apr 28 10:46:30 2015
New Revision: 1676469

URL: http://svn.apache.org/r1676469
Log:
On the 'move-tracking-2' branch: Rename 'svn_branch_map_{get,update,...}' to
'svn_branch_{get,update,...}_element'.

* subversion/include/private/svn_branch.h,
  subversion/libsvn_delta/branch.c
  (svn_branch_get_element): Was 'svn_branch_map_get'.
  (svn_branch_delete_element): Was 'svn_branch_map_delete'.
  (svn_branch_update_element): Was 'svn_branch_map_update'.
  (svn_branch_update_subbranch_root_element): Was
    'svn_branch_map_update_as_subbranch_root'.
  Track the renames.

* subversion/libsvn_delta/compat3e.c
  Track the renames.

* subversion/svnmover/svnmover.c
  Track the renames.

Modified:
    subversion/branches/move-tracking-2/subversion/include/private/svn_branch.h
    subversion/branches/move-tracking-2/subversion/libsvn_delta/branch.c
    subversion/branches/move-tracking-2/subversion/libsvn_delta/compat3e.c
    subversion/branches/move-tracking-2/subversion/svnmover/svnmover.c

Modified: subversion/branches/move-tracking-2/subversion/include/private/svn_branch.h
URL: http://svn.apache.org/viewvc/subversion/branches/move-tracking-2/subversion/include/private/svn_branch.h?rev=1676469&r1=1676468&r2=1676469&view=diff
==============================================================================
--- subversion/branches/move-tracking-2/subversion/include/private/svn_branch.h (original)
+++ subversion/branches/move-tracking-2/subversion/include/private/svn_branch.h Tue Apr 28
10:46:30 2015
@@ -396,13 +396,13 @@ svn_branch_get_subtree(const svn_branch_
  * element's node-content may be null meaning it is a subbranch-root.
  */
 svn_branch_el_rev_content_t *
-svn_branch_map_get(const svn_branch_state_t *branch,
+svn_branch_get_element(const svn_branch_state_t *branch,
                    int eid);
 
 /* In BRANCH, delete element EID.
  */
 void
-svn_branch_map_delete(svn_branch_state_t *branch,
+svn_branch_delete_element(svn_branch_state_t *branch,
                       int eid);
 
 /* Set or change the EID:element mapping for EID in BRANCH.
@@ -410,7 +410,7 @@ svn_branch_map_delete(svn_branch_state_t
  * Duplicate NEW_NAME and NEW_CONTENT into the branch mapping's pool.
  */
 void
-svn_branch_map_update(svn_branch_state_t *branch,
+svn_branch_update_element(svn_branch_state_t *branch,
                       int eid,
                       svn_branch_eid_t new_parent_eid,
                       const char *new_name,
@@ -423,7 +423,7 @@ svn_branch_map_update(svn_branch_state_t
  * Duplicate NEW_NAME into the branch mapping's pool.
  */
 void
-svn_branch_map_update_as_subbranch_root(svn_branch_state_t *branch,
+svn_branch_update_subbranch_root_element(svn_branch_state_t *branch,
                                         int eid,
                                         svn_branch_eid_t new_parent_eid,
                                         const char *new_name);

Modified: subversion/branches/move-tracking-2/subversion/libsvn_delta/branch.c
URL: http://svn.apache.org/viewvc/subversion/branches/move-tracking-2/subversion/libsvn_delta/branch.c?rev=1676469&r1=1676468&r2=1676469&view=diff
==============================================================================
--- subversion/branches/move-tracking-2/subversion/libsvn_delta/branch.c (original)
+++ subversion/branches/move-tracking-2/subversion/libsvn_delta/branch.c Tue Apr 28 10:46:30
2015
@@ -282,8 +282,8 @@ branch_validate_element(const svn_branch
 }
 
 svn_branch_el_rev_content_t *
-svn_branch_map_get(const svn_branch_state_t *branch,
-                   int eid)
+svn_branch_get_element(const svn_branch_state_t *branch,
+                       int eid)
 {
   svn_branch_el_rev_content_t *element;
 
@@ -319,8 +319,8 @@ branch_map_set(svn_branch_state_t *branc
 }
 
 void
-svn_branch_map_delete(svn_branch_state_t *branch,
-                      int eid)
+svn_branch_delete_element(svn_branch_state_t *branch,
+                          int eid)
 {
   SVN_ERR_ASSERT_NO_RETURN(EID_IS_ALLOCATED(branch, eid));
 
@@ -328,11 +328,11 @@ svn_branch_map_delete(svn_branch_state_t
 }
 
 void
-svn_branch_map_update(svn_branch_state_t *branch,
-                      int eid,
-                      svn_branch_eid_t new_parent_eid,
-                      const char *new_name,
-                      const svn_element_content_t *new_content)
+svn_branch_update_element(svn_branch_state_t *branch,
+                          int eid,
+                          svn_branch_eid_t new_parent_eid,
+                          const char *new_name,
+                          const svn_element_content_t *new_content)
 {
   apr_pool_t *map_pool = apr_hash_pool_get(branch->e_map);
   svn_branch_el_rev_content_t *element
@@ -349,10 +349,10 @@ svn_branch_map_update(svn_branch_state_t
 }
 
 void
-svn_branch_map_update_as_subbranch_root(svn_branch_state_t *branch,
-                                        int eid,
-                                        svn_branch_eid_t new_parent_eid,
-                                        const char *new_name)
+svn_branch_update_subbranch_root_element(svn_branch_state_t *branch,
+                                         int eid,
+                                         svn_branch_eid_t new_parent_eid,
+                                         const char *new_name)
 {
   apr_pool_t *map_pool = apr_hash_pool_get(branch->e_map);
   svn_branch_el_rev_content_t *element
@@ -479,7 +479,7 @@ svn_branch_purge_r(svn_branch_state_t *b
     {
       svn_branch_state_t *b = bi->val;
 
-      if (svn_branch_map_get(branch, b->outer_eid))
+      if (svn_branch_get_element(branch, b->outer_eid))
         {
           svn_branch_purge_r(b, bi->iterpool);
         }
@@ -542,7 +542,7 @@ svn_branch_get_path_by_eid(const svn_bra
 
   for (; ! IS_BRANCH_ROOT_EID(branch, eid); eid = element->parent_eid)
     {
-      element = svn_branch_map_get(branch, eid);
+      element = svn_branch_get_element(branch, eid);
       if (! element)
         return NULL;
       path = svn_relpath_join(element->name, path, result_pool);
@@ -640,11 +640,12 @@ svn_branch_map_add_subtree(svn_branch_st
   /* Create the new subtree root element */
   new_root_content = svn_int_hash_get(new_subtree.e_map, new_subtree.root_eid);
   if (new_root_content->content)
-    svn_branch_map_update(to_branch, to_eid,
-                          new_parent_eid, new_name, new_root_content->content);
+    svn_branch_update_element(to_branch, to_eid,
+                              new_parent_eid, new_name,
+                              new_root_content->content);
   else
-    svn_branch_map_update_as_subbranch_root(to_branch, to_eid,
-                                            new_parent_eid, new_name);
+    svn_branch_update_subbranch_root_element(to_branch, to_eid,
+                                             new_parent_eid, new_name);
 
   /* Process its immediate children */
   for (hi = apr_hash_first(scratch_pool, new_subtree.e_map);
@@ -684,11 +685,12 @@ svn_branch_instantiate_subtree(svn_branc
   /* Instantiate the root element of NEW_SUBTREE */
   new_root_content = svn_int_hash_get(new_subtree.e_map, new_subtree.root_eid);
   if (new_root_content->content)
-    svn_branch_map_update(to_branch, new_subtree.root_eid,
-                          new_parent_eid, new_name, new_root_content->content);
+    svn_branch_update_element(to_branch, new_subtree.root_eid,
+                              new_parent_eid, new_name,
+                              new_root_content->content);
   else
-    svn_branch_map_update_as_subbranch_root(to_branch, new_subtree.root_eid,
-                                            new_parent_eid, new_name);
+    svn_branch_update_subbranch_root_element(to_branch, new_subtree.root_eid,
+                                             new_parent_eid, new_name);
 
   /* Instantiate all the children of NEW_SUBTREE */
   for (hi = apr_hash_first(scratch_pool, new_subtree.e_map);
@@ -1011,12 +1013,12 @@ svn_branch_state_parse(svn_branch_state_
               peg.relpath = rrpath;
               content = svn_element_content_create_ref(peg, scratch_pool);
 
-              svn_branch_map_update(
+              svn_branch_update_element(
                 branch_state, eid, element->parent_eid, element->name, content);
             }
           else
             {
-              svn_branch_map_update_as_subbranch_root(
+              svn_branch_update_subbranch_root_element(
                 branch_state, eid, element->parent_eid, element->name);
             }
         }
@@ -1126,7 +1128,7 @@ svn_branch_state_serialize(svn_stream_t
   svn_branch_map_purge_orphans(branch, scratch_pool);
   for (eid = rev_root->first_eid; eid < rev_root->next_eid; eid++)
     {
-      svn_branch_el_rev_content_t *element = svn_branch_map_get(branch, eid);
+      svn_branch_el_rev_content_t *element = svn_branch_get_element(branch, eid);
       int parent_eid;
       const char *name;
 
@@ -1345,8 +1347,8 @@ svn_branch_branch(svn_branch_state_t **n
   /* assign new eid to root element (outer branch) */
   to_outer_eid
     = svn_branch_allocate_new_eid(to_outer_branch->rev_root);
-  svn_branch_map_update_as_subbranch_root(to_outer_branch, to_outer_eid,
-                                          to_outer_parent_eid, new_name);
+  svn_branch_update_subbranch_root_element(to_outer_branch, to_outer_eid,
+                                           to_outer_parent_eid, new_name);
 
   SVN_ERR(svn_branch_branch_subtree_r2(new_branch_p,
                                        *from_subtree,

Modified: subversion/branches/move-tracking-2/subversion/libsvn_delta/compat3e.c
URL: http://svn.apache.org/viewvc/subversion/branches/move-tracking-2/subversion/libsvn_delta/compat3e.c?rev=1676469&r1=1676468&r2=1676469&view=diff
==============================================================================
--- subversion/branches/move-tracking-2/subversion/libsvn_delta/compat3e.c (original)
+++ subversion/branches/move-tracking-2/subversion/libsvn_delta/compat3e.c Tue Apr 28 10:46:30
2015
@@ -838,7 +838,7 @@ svn_editor3_el_rev_get(svn_branch_el_rev
                       apr_pool_t *scratch_pool)
 {
   ev3_from_delta_baton_t *eb = svn_editor3__get_baton(editor);
-  svn_branch_el_rev_content_t *element = svn_branch_map_get(branch, eid);
+  svn_branch_el_rev_content_t *element = svn_branch_get_element(branch, eid);
 
   /* Node content is null iff node is a subbranch root, but we shouldn't
      be querying a subbranch root. */
@@ -911,15 +911,15 @@ editor3_add(void *baton,
                eid, new_parent_eid,
                new_name, svn_node_kind_to_word(new_content->kind)));
 
-      svn_branch_map_update(branch, eid, new_parent_eid, new_name, new_content);
+      svn_branch_update_element(branch, eid, new_parent_eid, new_name, new_content);
     }
   else
     {
       SVN_DBG(("add subbranch-root (e%d): parent e%d, name '%s'",
                eid, new_parent_eid, new_name));
 
-      svn_branch_map_update_as_subbranch_root(branch, eid,
-                                              new_parent_eid, new_name);
+      svn_branch_update_subbranch_root_element(branch, eid,
+                                               new_parent_eid, new_name);
     }
 
   *eid_p = eid;
@@ -942,15 +942,16 @@ editor3_instantiate(void *baton,
                eid, new_parent_eid, new_name,
                svn_node_kind_to_word(new_content->kind)));
 
-      svn_branch_map_update(branch, eid, new_parent_eid, new_name, new_content);
+      svn_branch_update_element(branch, eid, new_parent_eid, new_name,
+                                new_content);
     }
   else
     {
       SVN_DBG(("instantiate subbranch-root(e%d): parent e%d, name '%s'",
                eid, new_parent_eid, new_name));
 
-      svn_branch_map_update_as_subbranch_root(branch, eid,
-                                              new_parent_eid, new_name);
+      svn_branch_update_subbranch_root_element(branch, eid,
+                                               new_parent_eid, new_name);
     }
   return SVN_NO_ERROR;
 }
@@ -1006,7 +1007,7 @@ editor3_delete(void *baton,
   SVN_DBG(("delete(b%s e%d)",
            svn_branch_get_id(branch, scratch_pool), eid));
 
-  svn_branch_map_delete(branch, eid /* ### , since_rev? */);
+  svn_branch_delete_element(branch, eid /* ### , since_rev? */);
 
   return SVN_NO_ERROR;
 }
@@ -1031,14 +1032,14 @@ editor3_alter(void *baton,
   /* New content shall be the same as the before if NEW_CONTENT is null. */
   if (! new_content)
     {
-      new_content = svn_branch_map_get(branch, eid)->content;
+      new_content = svn_branch_get_element(branch, eid)->content;
     }
 
   if (new_content)
-    svn_branch_map_update(
+    svn_branch_update_element(
       branch, eid, new_parent_eid, new_name, new_content);
   else
-    svn_branch_map_update_as_subbranch_root(
+    svn_branch_update_subbranch_root_element(
       branch, eid, new_parent_eid, new_name);
 
   return SVN_NO_ERROR;
@@ -1253,12 +1254,13 @@ drive_changes_r(const char *rrpath,
                  || (pred_loc->relpath && SVN_IS_VALID_REVNUM(pred_loc->rev)));
   /* A non-null FINAL address means an element exists there. */
   SVN_ERR_ASSERT(!final_el_rev
-                 || svn_branch_map_get(final_el_rev->branch, final_el_rev->eid));
+                 || svn_branch_get_element(final_el_rev->branch,
+                                           final_el_rev->eid));
 
   if (final_el_rev)
     {
-      final_content
-        = svn_branch_map_get(final_el_rev->branch, final_el_rev->eid)->content;
+      final_content = svn_branch_get_element(final_el_rev->branch,
+                                             final_el_rev->eid)->content;
 
       /* Decide whether the state at this path should be a copy (incl. a
          copy-child) */

Modified: subversion/branches/move-tracking-2/subversion/svnmover/svnmover.c
URL: http://svn.apache.org/viewvc/subversion/branches/move-tracking-2/subversion/svnmover/svnmover.c?rev=1676469&r1=1676468&r2=1676469&view=diff
==============================================================================
--- subversion/branches/move-tracking-2/subversion/svnmover/svnmover.c (original)
+++ subversion/branches/move-tracking-2/subversion/svnmover/svnmover.c Tue Apr 28 10:46:30
2015
@@ -410,7 +410,7 @@ list_branch_elements_by_eid(svn_branch_s
 
   for (eid = branch->rev_root->first_eid; eid < branch->rev_root->next_eid;
eid++)
     {
-      svn_branch_el_rev_content_t *element = svn_branch_map_get(branch, eid);
+      svn_branch_el_rev_content_t *element = svn_branch_get_element(branch, eid);
 
       if (element && element->parent_eid == -1)
         {
@@ -1499,8 +1499,8 @@ mk_branch(svn_branch_state_t **new_branc
   new_branch = svn_branch_add_new_branch(
                  outer_branch, new_outer_eid, new_root_eid,
                  iterpool);
-  svn_branch_map_update(new_branch, new_root_eid,
-                        -1, "", content);
+  svn_branch_update_element(new_branch, new_root_eid,
+                            -1, "", content);
   *new_branch_p = new_branch;
   return SVN_NO_ERROR;
 }



Mime
View raw message