jdsl.core.ref
Class RBTLocator
java.lang.Object
|
+--jdsl.core.ref.RBTLocator
- public class RBTLocator
- extends java.lang.Object
- implements Locator, RBColorConstants
This is a locator used by our implementation of Red-Black Tree.
- Author:
- Ming En Cho
| Methods inherited from class java.lang.Object |
equals,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
RBTLocator
public RBTLocator(java.lang.Object element,
java.lang.Object key,
Container container,
Position position)
position
public Position position()
throws InvalidLocatorException
setPosition
public void setPosition(Position position)
element
public java.lang.Object element()
throws InvalidLocatorException
- Specified by:
- element in interface Locator
setElement
public void setElement(java.lang.Object element)
key
public java.lang.Object key()
throws InvalidLocatorException
- Specified by:
- key in interface Locator
setKey
public void setKey(java.lang.Object key)
isContained
public boolean isContained()
throws InvalidLocatorException
- Specified by:
- isContained in interface Locator
container
public Container container()
throws InvalidLocatorException
- Specified by:
- container in interface Locator
setContainer
public void setContainer(Container container)
isValid
public boolean isValid()
color
public int color()
setColor
public void setColor(int color)