CloneSet215


Previous CloneSetNext CloneSetBack to Main Report
Clone
Mass
Clones in
CloneSet
Parameter
Count
Clone
Similarity
Syntax Category
[Sequence Length]
19230.955ExpressionStatement
Clone AbstractionParameter Bindings
Clone Instance
(Click to see clone)
Line CountSource Line
Source File
119532
Closure/closure/goog/structs/avltree.js
219560
Closure/closure/goog/structs/avltree.js
Clone Instance
1
Line Count
19
Source Line
532
Source File
Closure/closure/goog/structs/avltree.js

/**
 * Performs a left tree rotation on the specified node.
 *
 * @param {goog.structs.AvlTree.Node} node Pivot node to rotate from.
 * @private
 */
goog.structs.AvlTree.prototype.leftRotate_=  function (node){
  // Re-assign parent-child references for the parent of the node being removed
  if (node.isLeftChild( )){
    node.parent.left=  node.right;
    node.right.parent=  node.parent;
                          }
  else   if (node.isRightChild( )){
    node.parent.right=  node.right;
    node.right.parent=  node.parent;
                                  }
         else
         {
    this.root_=  node.right;
    this.root_.parent=  null;
         }
  // Re-assign parent-child references for the child of the node being removed
  var temp=  node.right;
  node.right=  node.right.left;
  if (node.right!=  null) node.right.parent=  node;
  temp.left=  node;
  node.parent=  temp;
                                                            } ;


Clone Instance
2
Line Count
19
Source Line
560
Source File
Closure/closure/goog/structs/avltree.js

/**
 * Performs a right tree rotation on the specified node.
 *
 * @param {goog.structs.AvlTree.Node} node Pivot node to rotate from.
 * @private
 */
goog.structs.AvlTree.prototype.rightRotate_=  function (node){
  // Re-assign parent-child references for the parent of the node being removed
  if (node.isLeftChild( )){
    node.parent.left=  node.left;
    node.left.parent=  node.parent;
                          }
  else   if (node.isRightChild( ))
                                 {
    node.parent.right=  node.left;
    node.left.parent=  node.parent;
                                 }
         else
         {
    this.root_=  node.left;
    this.root_.parent=  null;
         }
  // Re-assign parent-child references for the child of the node being removed
  var temp=  node.left;
  node.left=  node.left.right;
  if (node.left!=  null) node.left.parent=  node;
  temp.right=  node;
  node.parent=  temp;
                                                             } ;


Clone AbstractionParameter Count: 3Parameter Bindings

/**
 * Performs a right tree rotation on the specified node.
 *
 * @param {goog.structs.AvlTree.Node} node Pivot node to rotate from.
 * @private
 */
/**
 * Performs a left tree rotation on the specified node.
 *
 * @param {goog.structs.AvlTree.Node} node Pivot node to rotate from.
 * @private
 */
goog.structs.AvlTree.prototype. [[#variable57499b40]]= function (node)
                                                       {
                                                         // Re-assign parent-child references for the parent of the node being removed
                                                         if (node.isLeftChild( ))
                                                           { node.parent.left=node. [[#variable57498020]];
                                                             node. [[#variable57498020]].parent=node.parent;
                                                           }
                                                         else
                                                           if (node.isRightChild( ))
                                                             { node.parent.right=node. [[#variable57498020]];
                                                               node. [[#variable57498020]].parent=node.parent;
                                                             }
                                                           else
                                                             { this.root_=node. [[#variable57498020]];
                                                               this.root_.parent=null;
                                                             }
                                                         // Re-assign parent-child references for the child of the node being removed
                                                         var temp=node. [[#variable57498020]];
                                                         node. [[#variable57498020]]=node. [[#variable57498020]]. [[#variable57499b00]];
                                                         if (node. [[#variable57498020]]!=null)
                                                           node. [[#variable57498020]].parent=node;
                                                         temp. [[#variable57499b00]]=node;
                                                         node.parent=temp;
                                                       } ;
 

CloneAbstraction
Parameter Bindings
Parameter
Index
Clone
Instance
Parameter
Name
Value
11[[#57499b40]]
rightRotate_ 
12[[#57499b40]]
leftRotate_ 
21[[#57498020]]
left 
22[[#57498020]]
right 
31[[#57499b00]]
right 
32[[#57499b00]]
left