children.put(s, t = new Child(new TreeString(node, s)));
/** * Inserts a new node between this node and its parent, and returns that * node. Newly inserted 'middle' node will have this node as its sole * child. */ private Child split(final String prefix) { String suffix = node.getLabel().substring(prefix.length()); Child middle = new Child(node.split(prefix)); middle.makeWritable(); middle.children.put(suffix, this); return middle; }
/** * Inserts a new node between this node and its parent, and returns that * node. Newly inserted 'middle' node will have this node as its sole * child. */ private Child split(final String prefix) { String suffix = node.getLabel().substring(prefix.length()); Child middle = new Child(node.split(prefix)); middle.makeWritable(); middle.children.put(suffix, this); return middle; }
children.put(s, t = new Child(new TreeString(node, s)));