public final class InPlaceLeftRotator<E> extends Object implements Rotator<E,MutableBinaryTreeNode<E>>
Rotator
for MutableBinaryTreeNodeImpl
in the left direction. Rotation is performed
in place by modifying the existing tree.Constructor and Description |
---|
InPlaceLeftRotator() |
Modifier and Type | Method and Description |
---|---|
Class<?> |
forClass() |
RotationDirection |
forDirection() |
void |
rotate(ParentReference<MutableBinaryTreeNode<E>> reference,
MutableBinaryTreeNode<E> currentRoot)
Apply the rotation.
|
public void rotate(ParentReference<MutableBinaryTreeNode<E>> reference, MutableBinaryTreeNode<E> currentRoot)
Rotator
rotate
in interface Rotator<E,MutableBinaryTreeNode<E>>
reference
- The reference to the rootcurrentRoot
- The root of the rotationpublic RotationDirection forDirection()
forDirection
in interface Rotator<E,MutableBinaryTreeNode<E>>
public Class<?> forClass()
forClass
in interface SPIComponent
Copyright © 2014–2016. All rights reserved.