subversion-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Apache subversion Wiki <>
Subject [Subversion Wiki] Update of "MoveDev/Ev2MovesDesign" by JulianFoad
Date Wed, 04 Sep 2013 16:09:18 GMT
Dear Wiki user,

You have subscribed to a wiki page or wiki category on "Subversion Wiki" for change notification.

The "MoveDev/Ev2MovesDesign" page has been changed by JulianFoad:

next part of new page

  More comprehensively, in tabular form, the sequences of operations allowed on a path are:
  ||Exists? ||Op sequences || || || ||
  ||no/yes ||add-* ||[create children] || || ||
- ||no/yes ||copy(dst) || alter-* [optional] ||[edit children] || ||
+ ||no/yes ||copy(dst) ||alter-* [optional] ||[edit children] || ||
  ||no/yes ||move-here ||alter-* [optional] ||[edit children] || ||
  ||yes ||alter-* || || || ||
  ||yes ||delete || || || ||
  ||yes ||move-away || || || ||
  ||yes ||move-away ||add-* ||[create children] || ||
  ||yes ||move-away ||copy(dst) ||alter-* [optional] ||[edit children] ||
- ||yes ||move-away ||move-here ||alter-* [optional] || [edit children] ||
+ ||yes ||move-away ||move-here ||alter-* [optional] ||[edit children] ||
  Perhaps the Once Rule should not apply per path as it was stated, but rather per node. 
If a directory is altered and then moved away, we should be able to create a replacement directory,
being a different node at the same path, and then alter that.
+ === The Once Rule, Per Node ===
+  * The Once Rule applies per node, rather than per path.  The   definition of a “node”
is such that “move” moves an existing    node (with any children) to a new path and does
not create a new        node, while “add” creates a new node and “copy” creates a
      new node (with any children), each new node being different from all    other nodes
that are or were in the tree even if it replaces an         existing node at the same path.
+  * One of the following actions can be applied, just Once,      directly to each node:
+   * create (only if it does not exist in the initial tree)
+   * remove (only if it exists in the initial tree or is brought                 in as a
child of a copy)
+   * modify (only if it exists in the initial tree or is brought                 in as a
child of a copy)
+  * A node may be created by one of:
+   * add_*()
+   * copy(), optionally followed by alter_*()
+    * Its children (recursively) come with it, and are then                      subject
to the Once Rule as “child of a copy” nodes.
+  * A node (with any children) may be removed by one of:
+   * delete()
+   * add_*() replacing this node
+   * copy() replacing this node
+   * move_here() replacing this node
+ When removing a directory, each child (recursively) is considered to be removed at this
time as well, and, as such, must not have been touched by any other operation.  However, a
previous child node may have been moved away [or deleted?] before this deletion.
+ [? The driver should not delete a node and then delete an ancestor: instead, it should just
delete the ancestor.]
+  * A node may be modified by either or both of the following, in        either order:
+   * move_away() followed by move_here()
+    * If the node is a directory, its children (recusively) move                        
with it.
+    * Only if it exists in the initial tree: not allowed for a                   child of
a copy.
+    * No operation may touch this node or any children                   (recursively) between
move-away and move-here.
+   * alter_*()
+  * alter_directory() is required before “editing” any   children
+   * ### Not sure exactly what we mean here.
+   * ### The rules would be simpler without this requirement.
+  * The source of a copy operation may be a node in the initial  tree being edited.  Such
a node (and its children, if a directory)      may be copied many times, in addition to being
subject to the Once      Rule as existing nodes.
+ In tabular form, the sequences of operations that would be allowed on a node in this scheme
+ ||Exists? ||Op sequences || || || || ||
+ ||no ||add-* ||[create children] || || || ||
+ ||no ||copy(dst) ||alter-* [optional] ||[edit children] || || ||
+ ||yes ||alter-* ||[edit children] || || || ||
+ ||yes ||[move-away children] ||delete || || || ||
+ ||yes ||[move-away children] ||replaced by add-* || || || ||
+ ||yes ||[move-away children] ||replaced by copy() || || || ||
+ ||yes ||[move-away children] ||replaced by move-here() || || || ||
+ ||yes ||move-away ||move-here ||alter-* [optional] ||[edit children] || ||
+ ||yes ||alter-* ||[edit children] ||move-away ||move-here ||[edit children] ||

View raw message