org.sonar.duplications.index
Class CloneGroup

java.lang.Object
  extended by org.sonar.duplications.index.CloneGroup

public class CloneGroup
extends Object

Groups a set of related CloneParts.


Constructor Summary
CloneGroup(int cloneLength, ClonePart origin, List<ClonePart> parts)
           
 
Method Summary
 boolean equals(Object object)
          Two groups are equal, if they have same length, same origins and contain same parts in same order.
 List<ClonePart> getCloneParts()
           
 int getCloneUnitLength()
           
 ClonePart getOriginPart()
           
 int hashCode()
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

CloneGroup

public CloneGroup(int cloneLength,
                  ClonePart origin,
                  List<ClonePart> parts)
Method Detail

getOriginPart

public ClonePart getOriginPart()

getCloneUnitLength

public int getCloneUnitLength()
Returns:
clone length in units (not in lines)

getCloneParts

public List<ClonePart> getCloneParts()

toString

public String toString()
Overrides:
toString in class Object

equals

public boolean equals(Object object)
Two groups are equal, if they have same length, same origins and contain same parts in same order.

Overrides:
equals in class Object

hashCode

public int hashCode()
Overrides:
hashCode in class Object


Copyright © 2009-2012 SonarSource. All Rights Reserved.