Previous CloneSet | Next CloneSet | Back to Main Report |
Clone Mass | Clones in CloneSet | Parameter Count | Clone Similarity | Syntax Category [Sequence Length] |
---|---|---|---|---|
3 | 2 | 3 | 0.956 | class_member_declaration |
Clone Abstraction | Parameter Bindings |
Clone Instance (Click to see clone) | Line Count | Source Line | Source File |
---|---|---|---|
1 | 3 | 48 | src/NHibernate.DomainModel/NHSpecific/NullableTypesType.cs |
2 | 3 | 32 | src/NHibernate/IdentityEqualityComparer.cs |
| ||||
public override bool IsEqual(object x, object y) { return Equals(x, y); } |
| ||||
/// <summary> /// Performs a null safe comparison using "==" instead of Object.Equals() /// </summary> /// <param name="x">First object to compare.</param> /// <param name="y">Second object to compare.</param> /// <returns> /// true if x is the same instance as y or if both are null references; otherwise, false. ///</returns> /// <remarks> /// This is Lazy collection safe since it uses <see cref="Object.ReferenceEquals"/>, /// unlike <c>Object.Equals()</c> which currently causes NHibernate to load up the collection. /// This behaivior of Collections is likely to change because Java's collections override Equals() and /// .net's collections don't. So in .net there is no need to override Equals() and /// GetHashCode() on the NHibernate Collection implementations. /// </remarks> public new bool Equals(object x, object y) { return ReferenceEquals(x, y); } |
| |||
/// <summary> /// Performs a null safe comparison using "==" instead of Object.Equals() /// </summary> /// <param name="x">First object to compare.</param> /// <param name="y">Second object to compare.</param> /// <returns> /// true if x is the same instance as y or if both are null references; otherwise, false. ///</returns> /// <remarks> /// This is Lazy collection safe since it uses <see cref="Object.ReferenceEquals"/>, /// unlike <c>Object.Equals()</c> which currently causes NHibernate to load up the collection. /// This behaivior of Collections is likely to change because Java's collections override Equals() and /// .net's collections don't. So in .net there is no need to override Equals() and /// GetHashCode() on the NHibernate Collection implementations. /// </remarks> public [[#variable70ae6ae0]]bool [[#variable70ae6a40]](object x, object y) { return [[#variable70ae69e0]](x, y); } |
CloneAbstraction |
Parameter Index | Clone Instance | Parameter Name | Value |
---|---|---|---|
1 | 1 | [[#70ae6ae0]] | new |
1 | 2 | [[#70ae6ae0]] | override |
2 | 1 | [[#70ae6a40]] | Equals |
2 | 2 | [[#70ae6a40]] | IsEqual |
3 | 1 | [[#70ae69e0]] | ReferenceEquals |
3 | 2 | [[#70ae69e0]] | Equals |