Class LLRBValueNode<K,V> (3.25.1)

public abstract class LLRBValueNode<K,V> implements LLRBNode<K,V>

Inheritance

java.lang.Object > LLRBValueNode<K,V>

Implements

LLRBNode<K,V>

Type Parameters

Name Description
K
V

Methods

copy(K key, V value, LLRBNode.Color color, LLRBNode<K,V> left, LLRBNode<K,V> right)

public LLRBValueNode<K,V> copy(K key, V value, LLRBNode.Color color, LLRBNode<K,V> left, LLRBNode<K,V> right)
Parameters
Name Description
key K
value V
color LLRBNode.Color
left LLRBNode<K,V>
right LLRBNode<K,V>
Returns
Type Description
LLRBValueNode<K,V>

copy(K key, V value, LLRBNode<K,V> left, LLRBNode<K,V> right)

protected abstract LLRBValueNode<K,V> copy(K key, V value, LLRBNode<K,V> left, LLRBNode<K,V> right)
Parameters
Name Description
key K
value V
left LLRBNode<K,V>
right LLRBNode<K,V>
Returns
Type Description
LLRBValueNode<K,V>

getColor()

protected abstract LLRBNode.Color getColor()
Returns
Type Description
LLRBNode.Color

getKey()

public K getKey()
Returns
Type Description
K

getLeft()

public LLRBNode<K,V> getLeft()
Returns
Type Description
LLRBNode<K,V>

getMax()

public LLRBNode<K,V> getMax()
Returns
Type Description
LLRBNode<K,V>

getMin()

public LLRBNode<K,V> getMin()
Returns
Type Description
LLRBNode<K,V>

getRight()

public LLRBNode<K,V> getRight()
Returns
Type Description
LLRBNode<K,V>

getValue()

public V getValue()
Returns
Type Description
V

inOrderTraversal(LLRBNode.NodeVisitor<K,V> visitor)

public void inOrderTraversal(LLRBNode.NodeVisitor<K,V> visitor)
Parameter
Name Description
visitor NodeVisitor<K,V>

insert(K key, V value, Comparator<K> comparator)

public LLRBNode<K,V> insert(K key, V value, Comparator<K> comparator)
Parameters
Name Description
key K
value V
comparator Comparator<K>
Returns
Type Description
LLRBNode<K,V>

isEmpty()

public boolean isEmpty()
Returns
Type Description
boolean

remove(K key, Comparator<K> comparator)

public LLRBNode<K,V> remove(K key, Comparator<K> comparator)
Parameters
Name Description
key K
comparator Comparator<K>
Returns
Type Description
LLRBNode<K,V>

shortCircuitingInOrderTraversal(LLRBNode.ShortCircuitingNodeVisitor<K,V> visitor)

public boolean shortCircuitingInOrderTraversal(LLRBNode.ShortCircuitingNodeVisitor<K,V> visitor)
Parameter
Name Description
visitor ShortCircuitingNodeVisitor<K,V>
Returns
Type Description
boolean

shortCircuitingReverseOrderTraversal(LLRBNode.ShortCircuitingNodeVisitor<K,V> visitor)

public boolean shortCircuitingReverseOrderTraversal(LLRBNode.ShortCircuitingNodeVisitor<K,V> visitor)
Parameter
Name Description
visitor ShortCircuitingNodeVisitor<K,V>
Returns
Type Description
boolean