code: static boolean containsIn(CloneGroup first, CloneGroup second) {
      if (first.getCloneUnitLength() > second.getCloneUnitLength()) {
        return false;
      }
      List<ClonePart> firstParts = first.getCloneParts();
      List<ClonePart> secondParts = second.getCloneParts();
      return SortedListsUtils.contains(secondParts, firstParts, new ContainsInComparator(second.getCloneUnitLength(), first.getCloneUnitLength()))
        && SortedListsUtils.contains(firstParts, secondParts, ContainsInComparator.RESOURCE_ID_COMPARATOR);
    }
docs: Checks that second clone contains first one.
  <p>
  Clone A is contained in another clone B, if every part pA from A has part pB in B,
  which satisfy the conditions:
  <pre>
  (pA.resourceId == pB.resourceId) and (pB.unitStart <= pA.unitStart) and (pA.unitEnd <= pB.unitEnd)
  </pre>
  And all resourcesId from B exactly the same as all resourceId from A, which means that also every part pB from B has part pA in A,
  which satisfy the condition:
  <pre>
  pB.resourceId == pA.resourceId
  </pre>
  So this relation is:
  <ul>
  <li>reflexive - A in A</li>
  <li>transitive - (A in B) and (B in C) => (A in C)</li>
  <li>antisymmetric - (A in B) and (B in A) <=> (A = B)</li>
  </ul>
  </p>
  <p>
  <strong>Important: this method relies on fact that all parts were already sorted by resourceId and unitStart by using
  {@link BlocksGroup.BlockComparator}, which uses {@link org.sonar.duplications.utils.FastStringComparator} for comparison by resourceId.</strong>
  </p>
  <p>
  Running time - O(|A|+|B|).
  </p>