jackrabbit-oak-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ju...@apache.org
Subject svn commit: r1298833 - in /jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/model: ChildNodeEntry.java NodeState.java PropertyState.java
Date Fri, 09 Mar 2012 14:05:47 GMT
Author: jukka
Date: Fri Mar  9 14:05:46 2012
New Revision: 1298833

URL: http://svn.apache.org/viewvc?rev=1298833&view=rev
Log:
OAK-3: Internal tree model

More specific documentation of the equality contract

Modified:
    jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/model/ChildNodeEntry.java
    jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/model/NodeState.java
    jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/model/PropertyState.java

Modified: jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/model/ChildNodeEntry.java
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/model/ChildNodeEntry.java?rev=1298833&r1=1298832&r2=1298833&view=diff
==============================================================================
--- jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/model/ChildNodeEntry.java
(original)
+++ jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/model/ChildNodeEntry.java
Fri Mar  9 14:05:46 2012
@@ -18,6 +18,15 @@ package org.apache.jackrabbit.oak.model;
 
 /**
  * TODO: document
+ *
+ * <h2>Equality and hash codes</h2>
+ * <p>
+ * Two child node entries are considered equal if and only if their names
+ * and referenced node states match. The {@link Object#equals(Object)}
+ * method needs to be implemented so that it complies with this definition.
+ * And while child node entries are not meant for use as hash keys, the
+ * {@link Object#hashCode()} method should still be implemented according
+ * to this equality contract.
  */
 public interface ChildNodeEntry {
 

Modified: jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/model/NodeState.java
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/model/NodeState.java?rev=1298833&r1=1298832&r2=1298833&view=diff
==============================================================================
--- jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/model/NodeState.java
(original)
+++ jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/model/NodeState.java
Fri Mar  9 14:05:46 2012
@@ -80,12 +80,12 @@ package org.apache.jackrabbit.oak.model;
  *
  * <h2>Equality and hash codes</h2>
  * <p>
- * Two node states are considered equal if their properties and child nodes
- * match, regardless of ordering. The {@link Object#equals(Object)} method
- * needs to be implemented so that it complies with this definition. And
- * while node states are not meant for use as hash keys, the
- * {@link Object#hashCode()} method should still be implemented according
- * to the equality contract.
+ * Two node states are considered equal if and only if their properties and
+ * child nodes match, regardless of ordering. The
+ * {@link Object#equals(Object)} method needs to be implemented so that it
+ * complies with this definition. And while node states are not meant for
+ * use as hash keys, the {@link Object#hashCode()} method should still be
+ * implemented according to this equality contract.
  */
 public interface NodeState {
 

Modified: jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/model/PropertyState.java
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/model/PropertyState.java?rev=1298833&r1=1298832&r2=1298833&view=diff
==============================================================================
--- jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/model/PropertyState.java
(original)
+++ jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/model/PropertyState.java
Fri Mar  9 14:05:46 2012
@@ -19,6 +19,15 @@ package org.apache.jackrabbit.oak.model;
 /**
  * Immutable property state. A property consists of a name and
  * a JSON-encoded value.
+ *
+ * <h2>Equality and hash codes</h2>
+ * <p>
+ * Two property states are considered equal if and only if their names and
+ * encoded values match. The {@link Object#equals(Object)} method needs to
+ * be implemented so that it complies with this definition. And while
+ * property states are not meant for use as hash keys, the
+ * {@link Object#hashCode()} method should still be implemented according
+ * to this equality contract.
  */
 public interface PropertyState {
 



Mime
View raw message