You are viewing a plain text version of this content. The canonical link for it is here.
Posted to oak-commits@jackrabbit.apache.org by md...@apache.org on 2012/10/12 16:32:35 UTC
svn commit: r1397582 - /jackrabbit/oak/trunk/doc/nodestate.md
Author: mduerig
Date: Fri Oct 12 14:32:35 2012
New Revision: 1397582
URL: http://svn.apache.org/viewvc?rev=1397582&view=rev
Log:
reflect method rename
Modified:
jackrabbit/oak/trunk/doc/nodestate.md
Modified: jackrabbit/oak/trunk/doc/nodestate.md
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/doc/nodestate.md?rev=1397582&r1=1397581&r2=1397582&view=diff
==============================================================================
--- jackrabbit/oak/trunk/doc/nodestate.md (original)
+++ jackrabbit/oak/trunk/doc/nodestate.md Fri Oct 12 14:32:35 2012
@@ -84,7 +84,7 @@ interface contains the following key met
* The `setProperty` and `removeProperty` methods for modifying properties
* The `removeNode` method for removing a subtree
* The `setNode` method for adding or replacing a subtree
- * The `getChildBuilder` method for creating or modifying a subtree with
+ * The `child` method for creating or modifying a subtree with
a connected child builder
* The `getNodeState` method for getting a frozen snapshot of the modified
content tree
@@ -110,7 +110,7 @@ re-connect each modified node state alon
modified content in `/foo/bar`. This is because each `NodeBuilder` instance
created by the `getBuilder` method is independent and can only be used to
affect other builders in the manner shown above. In contrast the
-`getChildBuilder` method returns a builder instance that is "connected" to
+`child` method returns a builder instance that is "connected" to
the parent builder in a way that any changes recorded in the child builder
will automatically show up also in the node states created by the parent
builder. With connected builders the above code can be simplified to:
@@ -118,13 +118,13 @@ builder. With connected builders the abo
NodeState root = â¦;
NodeBuilder rootBuilder = root.getBuilder();
rootBuilder
- .getChildBuilder("foo")
- .getChildBuilder("bar")
+ .child("foo")
+ .child("bar")
.setProperty("test", â¦);
root = rootBuilder.getNodeState();
Typically the only case where the `setNode` method is preferable over
-`getChildBuilder` is when moving or copying subtrees from one location
+`child` is when moving or copying subtrees from one location
to another. For example, the following code copies the `/orig` subtree
to `/copy`: