Previous CloneSet | Next CloneSet | Back to Main Report |
Clone Mass | Clones in CloneSet | Parameter Count | Clone Similarity | Syntax Category [Sequence Length] |
---|---|---|---|---|
6 | 4 | 3 | 0.971 | class_member_declaration |
Clone Abstraction | Parameter Bindings |
Clone Instance (Click to see clone) | Line Count | Source Line | Source File |
---|---|---|---|
1 | 6 | 412 | src/Iesi.Collections/Generic/Set.cs |
2 | 6 | 425 | src/Iesi.Collections/Generic/Set.cs |
3 | 6 | 69 | src/Iesi.Collections/Set.cs |
4 | 6 | 175 | src/Iesi.Collections/Set.cs |
| ||||
/// <summary> /// Performs Union when called trhough non-generic ISet interface /// </summary> /// <param name="a"></param> /// <returns></returns> protected virtual ISet NonGenericUnion(ISet a) { ISet resultSet = (ISet) this.Clone(); if (a != null) resultSet.AddAll(a); return resultSet; } |
| ||||
/// <summary> /// Performs Minus when called trhough non-generic ISet interface /// </summary> /// <param name="a"></param> /// <returns></returns> protected virtual ISet NonGenericMinus(ISet a) { ISet resultSet = (ISet) this.Clone(); if (a != null) resultSet.RemoveAll(a); return resultSet; } |
| ||||
/// <summary> /// Performs a "union" of the two sets, where all the elements /// in both sets are present. That is, the element is included if it is in either <c>a</c> or <c>b</c>. /// Neither this set nor the input set are modified during the operation. The return value /// is a clone of this set with the extra elements added in. /// </summary> /// <param name="a">A collection of elements.</param> /// <returns>A new <see cref="ISet" /> instance containing the union of this instance with the specified collection. /// Neither of the input objects is modified by the union.</returns> public virtual ISet Union(ISet a) { ISet resultSet = (ISet) this.Clone(); if (a != null) resultSet.AddAll(a); return resultSet; } |
| ||||
/// <summary> /// Performs a "minus" of set <c>b</c> from set <c>a</c>. This returns a set of all /// the elements in set <c>a</c>, removing the elements that are also in set <c>b</c>. /// The original sets are not modified during this operation. The result set is a <c>Clone()</c> /// of this <c>Set</c> containing the elements from the operation. /// </summary> /// <param name="a">A set of elements.</param> /// <returns>A set containing the elements from this set with the elements in <c>a</c> removed.</returns> public virtual ISet Minus(ISet a) { ISet resultSet = (ISet) this.Clone(); if (a != null) resultSet.RemoveAll(a); return resultSet; } |
| |||
[[#variable501d4120]]virtual ISet [[#variable501d40c0]](ISet a) { ISet resultSet = (ISet)this.Clone(); if (a != null) resultSet. [[#variable501d4040]](a); return resultSet; } |
CloneAbstraction |
Parameter Index | Clone Instance | Parameter Name | Value |
---|---|---|---|
1 | 1 | [[#501d4120]] | /// <summary> /// Performs Union when called trhough non-generic ISet interface /// </summary> /// <param name="a"></param> /// <returns></returns> protected |
1 | 2 | [[#501d4120]] | /// <summary> /// Performs Minus when called trhough non-generic ISet interface /// </summary> /// <param name="a"></param> /// <returns></returns> protected |
1 | 3 | [[#501d4120]] | /// <summary> /// Performs a "union" of the two sets, where all the elements /// in both sets are present. That is, the element is included if it is in either <c>a</c> or <c>b</c>. /// Neither this set nor the input set are modified during the operation. The return value /// is a clone of this set with the extra elements added in. /// </summary> /// <param name="a">A collection of elements.</param> /// <returns>A new <see cref="ISet" /> instance containing the union of this instance with the specified collection. /// Neither of the input objects is modified by the union.</returns> public |
1 | 4 | [[#501d4120]] | /// <summary> /// Performs a "minus" of set <c>b</c> from set <c>a</c>. This returns a set of all /// the elements in set <c>a</c>, removing the elements that are also in set <c>b</c>. /// The original sets are not modified during this operation. The result set is a <c>Clone()</c> /// of this <c>Set</c> containing the elements from the operation. /// </summary> /// <param name="a">A set of elements.</param> /// <returns>A set containing the elements from this set with the elements in <c>a</c> removed.</returns> public |
2 | 1 | [[#501d40c0]] | NonGenericUnion |
2 | 2 | [[#501d40c0]] | NonGenericMinus |
2 | 3 | [[#501d40c0]] | Union |
2 | 4 | [[#501d40c0]] | Minus |
3 | 1 | [[#501d4040]] | AddAll |
3 | 2 | [[#501d4040]] | RemoveAll |
3 | 3 | [[#501d4040]] | AddAll |
3 | 4 | [[#501d4040]] | RemoveAll |