Previous CloneSet | Next CloneSet | Back to Main Report |
Clone Mass | Clones in CloneSet | Parameter Count | Clone Similarity | Syntax Category [Sequence Length] |
---|---|---|---|---|
20 | 2 | 0 | 1.000 | statement_list[8] |
Clone Abstraction | Parameter Bindings |
Clone Instance (Click to see clone) | Line Count | Source Line | Source File |
---|---|---|---|
1 | 20 | 420 | src/NHibernate.Test/Criteria/CriteriaQueryTest.cs |
2 | 20 | 440 | src/NHibernate.Test/Criteria/CriteriaQueryTest.cs |
| ||||
Assert.AreEqual(2, ((object[])list[1]).Length); t.Commit(); s.Close(); s = OpenSession(); t = s.BeginTransaction(); s.CreateCriteria( typeof(Enrolment)). CreateAlias("Student", "s"). CreateAlias("Course", "c"). Add(Expression.IsNotEmpty("s.Enrolments")). SetProjection(Projections.ProjectionList(). Add(Projections.Property("s.Name")). Add(Projections.Property("c.Description"))). SetCacheable(true). List(); Assert.AreEqual(2, list.Count); Assert.AreEqual(2, ((object[])list[0]).Length); |
| ||||
Assert.AreEqual(2, ((object[])list[1]).Length); t.Commit(); s.Close(); s = OpenSession(); t = s.BeginTransaction(); s.CreateCriteria( typeof(Enrolment)). CreateAlias("Student", "s"). CreateAlias("Course", "c"). Add(Expression.IsNotEmpty("s.Enrolments")). SetProjection(Projections.ProjectionList(). Add(Projections.Property("s.Name")). Add(Projections.Property("c.Description"))). SetCacheable(true). List(); Assert.AreEqual(2, list.Count); Assert.AreEqual(2, ((object[])list[0]).Length); |
| |||
Assert.AreEqual(2, ((object[])list[1]).Length); t.Commit(); s.Close(); s = OpenSession(); t = s.BeginTransaction(); s.CreateCriteria( typeof(Enrolment)).CreateAlias("Student", "s").CreateAlias("Course", "c").Add(Expression.IsNotEmpty("s.Enrolments")).SetProjection(Projections.ProjectionList().Add(Projections.Property("s.Name")).Add(Projections.Property("c.Description"))).SetCacheable(true).List(); Assert.AreEqual(2, list.Count); Assert.AreEqual(2, ((object[])list[0]).Length); |
CloneAbstraction |
Parameter Index | Clone Instance | Parameter Name | Value |
---|---|---|---|
None |