CloneSet820


Previous CloneSetNext CloneSetBack to Main Report
Clone
Mass
Clones in
CloneSet
Parameter
Count
Clone
Similarity
Syntax Category
[Sequence Length]
18240.962statement_sequence_member
Clone AbstractionParameter Bindings
Clone Instance
(Click to see clone)
Line CountSource Line
Source File
118761
plugins/org.eclipse.jdt.core/compiler/org/eclipse/jdt/internal/compiler/codegen/ConstantPool.java
218800
plugins/org.eclipse.jdt.core/compiler/org/eclipse/jdt/internal/compiler/codegen/ConstantPool.java
Clone Instance
1
Line Count
18
Source Line
761
Source File
plugins/org.eclipse.jdt.core/compiler/org/eclipse/jdt/internal/compiler/codegen/ConstantPool.java

        if (key1Value == null) {
                CachedIndexEntry cachedIndexEntry = new CachedIndexEntry(key2, value);
                index = -value;
                this.nameAndTypeCacheForFieldsAndMethods.put(key1, cachedIndexEntry);
        }
        else   if (key1Value instanceof CachedIndexEntry) {
                // adding a second entry
                CachedIndexEntry entry = (CachedIndexEntry) key1Value;
                if (CharOperation.equals(key2, entry.signature)) {
                        index = entry.index;
                }
                else   {
                        CharArrayCache charArrayCache = new CharArrayCache();
                        charArrayCache.putIfAbsent(entry.signature, entry.index);
                        index = charArrayCache.putIfAbsent(key2, value);
                        this.nameAndTypeCacheForFieldsAndMethods.put(key1, charArrayCache);
                }
               }
               else {
                CharArrayCache charArrayCache = (CharArrayCache) key1Value;
                index = charArrayCache.putIfAbsent(key2, value);
               }


Clone Instance
2
Line Count
18
Source Line
800
Source File
plugins/org.eclipse.jdt.core/compiler/org/eclipse/jdt/internal/compiler/codegen/ConstantPool.java

                if (key2Value == null) {
                        CachedIndexEntry cachedIndexEntry = new CachedIndexEntry(key3, value);
                        index = -value;
                        key1Value.put(key2, cachedIndexEntry);
                }
                else   if (key2Value instanceof CachedIndexEntry) {
                        // adding a second entry
                        CachedIndexEntry entry = (CachedIndexEntry) key2Value;
                        if (CharOperation.equals(key3, entry.signature)) {
                                index = entry.index;
                        }
                        else   {
                                CharArrayCache charArrayCache = new CharArrayCache();
                                charArrayCache.putIfAbsent(entry.signature, entry.index);
                                index = charArrayCache.putIfAbsent(key3, value);
                                key1Value.put(key2, charArrayCache);
                        }
                       }
                       else {
                        CharArrayCache charArrayCache = (CharArrayCache) key2Value;
                        index = charArrayCache.putIfAbsent(key3, value);
                       }


Clone AbstractionParameter Count: 4Parameter Bindings

if ( [[#variablebccfc300]]== null) {
  CachedIndexEntry cachedIndexEntry = new CachedIndexEntry( [[#variablebccfc200]], value);
  index = -value;
   [[#variablebccfc1c0]].put( [[#variablebccfc2a0]], cachedIndexEntry);
}
else
  if ( [[#variablebccfc300]]instanceof CachedIndexEntry) {
    // adding a second entry
    CachedIndexEntry entry = (CachedIndexEntry)  [[#variablebccfc300]];
    if (CharOperation.equals( [[#variablebccfc200]], entry.signature)) {
      index = entry.index;
    }
    else {
      CharArrayCache charArrayCache = new CharArrayCache();
      charArrayCache.putIfAbsent(entry.signature, entry.index);
      index = charArrayCache.putIfAbsent( [[#variablebccfc200]], value);
       [[#variablebccfc1c0]].put( [[#variablebccfc2a0]], charArrayCache);
    }
  }
  else {
    CharArrayCache charArrayCache = (CharArrayCache)  [[#variablebccfc300]];
    index = charArrayCache.putIfAbsent( [[#variablebccfc200]], value);
  }
 

CloneAbstraction
Parameter Bindings
Parameter
Index
Clone
Instance
Parameter
Name
Value
11[[#bccfc300]]
key2Value 
12[[#bccfc300]]
key1Value 
21[[#bccfc200]]
key3 
22[[#bccfc200]]
key2 
31[[#bccfc1c0]]
key1Value 
32[[#bccfc1c0]]
this.nameAndTypeCacheForFieldsAndMethods 
41[[#bccfc2a0]]
key2 
42[[#bccfc2a0]]
key1