Previous CloneSet | Next CloneSet | Back to Main Report |
Clone Mass | Clones in CloneSet | Parameter Count | Clone Similarity | Syntax Category [Sequence Length] |
---|---|---|---|---|
40 | 2 | 1 | 0.996 | class_member_declarations[6] |
Clone Abstraction | Parameter Bindings |
Clone Instance (Click to see clone) | Line Count | Source Line | Source File |
---|---|---|---|
1 | 40 | 24 | src/NHibernate.DomainModel/NHSpecific/NullInt32UserType.cs |
2 | 40 | 22 | src/NHibernate.Test/TypeParameters/DefaultValueIntegerType.cs |
| ||||
#region IUserType Members public new bool Equals(object x, object y) { if (x == y) return true; int lhs = (x == null) ? 0: (int) x; int rhs = (y == null) ? 0: (int) y; return _int32Type.IsEqual(lhs, rhs); } public int GetHashCode(object x) { return (x == null) ? 0: x.GetHashCode(); } public SqlType[] SqlTypes { get { return new SqlType[] { _int32Type.SqlType } ; } } public object DeepCopy(object value) { return value; } public void NullSafeSet(IDbCommand cmd, object value, int index) { if (value.Equals(0)) { ((IDbDataParameter) cmd.Parameters[index]).Value = DBNull.Value; } else { _int32Type.Set(cmd, value, index); } } public System.Type ReturnedType { get { return typeof(Int32); } } |
| ||||
#region IUserType Members public new bool Equals(object x, object y) { if (x == y) return true; int lhs = (x == null) ? 0: (int) x; int rhs = (y == null) ? 0: (int) y; return _int32Type.IsEqual(lhs, rhs); } public int GetHashCode(object x) { return (x == null) ? 0: x.GetHashCode(); } public SqlType[] SqlTypes { get { return new SqlType[] { _int32Type.SqlType } ; } } public object DeepCopy(object value) { return value; } public void NullSafeSet(IDbCommand cmd, object value, int index) { if (value.Equals(defaultValue)) { ((IDbDataParameter) cmd.Parameters[index]).Value = DBNull.Value; } else { _int32Type.Set(cmd, value, index); } } public System.Type ReturnedType { get { return typeof(Int32); } } |
| |||
#region IUserType Members public new bool Equals(object x, object y) { if (x == y) return true; int lhs = (x == null) ? 0: (int)x; int rhs = (y == null) ? 0: (int)y; return _int32Type.IsEqual(lhs, rhs); } public int GetHashCode(object x) { return (x == null) ? 0: x.GetHashCode(); } public SqlType[] SqlTypes { get { return new SqlType[] { _int32Type.SqlType } ; } } public object DeepCopy(object value) { return value; } public void NullSafeSet(IDbCommand cmd, object value, int index) { if (value.Equals( [[#variable6ffbca20]])) { ((IDbDataParameter)cmd.Parameters[index]).Value = DBNull.Value; } else { _int32Type.Set(cmd, value, index); } } public System.Type ReturnedType { get { return typeof(Int32); } } |
CloneAbstraction |
Parameter Index | Clone Instance | Parameter Name | Value |
---|---|---|---|
1 | 1 | [[#6ffbca20]] | defaultValue |
1 | 2 | [[#6ffbca20]] | 0 |