Revision: 10705
http://foray.svn.sourceforge.net/foray/?rev=10705&view=rev
Author: victormote
Date: 2009-03-17 17:13:34 +0000 (Tue, 17 Mar 2009)
Log Message:
-----------
Store the value using the standard (downstream) logic.
Modified Paths:
--------------
trunk/foray/foray-common/src/java/org/foray/common/TernaryTreeMap.java
Modified: trunk/foray/foray-common/src/java/org/foray/common/TernaryTreeMap.java
===================================================================
--- trunk/foray/foray-common/src/java/org/foray/common/TernaryTreeMap.java 2009-03-17 17:06:30 UTC (rev 10704)
+++ trunk/foray/foray-common/src/java/org/foray/common/TernaryTreeMap.java 2009-03-17 17:13:34 UTC (rev 10705)
@@ -258,11 +258,9 @@
}
if (this.keyChar[currentNodeIndex] == Character.MAX_VALUE) {
- uncompressNode(value, currentNodeIndex, len);
- if (len == 0) {
- return currentNodeIndex;
- }
+ uncompressNode(currentNodeIndex, len);
}
+
if (len == 0) {
/* Make the current node the zero-termination node and store the value in it. */
this.keyChar[currentNodeIndex] = 0;
@@ -317,11 +315,10 @@
/**
* Uncompresses a node by creating a new one, moving all but the first character from it into the new node, and
* keeping the existing node pointing to the first character in the previously-compressed node.
- * @param value Junk.
* @param currentNodeIndex Junk.
* @param len Junk.
*/
- private void uncompressNode(final char value, final char currentNodeIndex, final int len) {
+ private void uncompressNode(final char currentNodeIndex, final int len) {
/* This node is compressed. */
/* Create a new node. */
final char newNodeIndex = this.freenode++;
@@ -353,7 +350,6 @@
this.keyChar[newNodeIndex] = Character.MAX_VALUE;
this.hi[currentNodeIndex] = newNodeIndex;
this.keyChar[currentNodeIndex] = 0;
- this.eq[currentNodeIndex] = value;
this.length++;
}
}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|