CloneSet207


Previous CloneSetNext CloneSetBack to Main Report
Clone
Mass
Clones in
CloneSet
Parameter
Count
Clone
Similarity
Syntax Category
[Sequence Length]
34210.998class_member_declarations[5]
Clone AbstractionParameter Bindings
Clone Instance
(Click to see clone)
Line CountSource Line
Source File
13411
src/NHibernate.Test/BulkManipulation/BaseFixture.cs
23411
src/NHibernate.Test/HQL/Ast/BaseFixture.cs
Clone Instance
1
Line Count
34
Source Line
11
Source File
src/NHibernate.Test/BulkManipulation/BaseFixture.cs

                private readonly IDictionary<string, IFilter> emptyfilters = new CollectionHelper.EmptyMapClass<string, IFilter> ();

                protected override bool AppliesTo(Engine.ISessionFactoryImplementor factory)
                {
                        return !(factory.Settings.QueryTranslatorFactory is ClassicQueryTranslatorFactory);
                }

                #region Overrides of TestCase

                protected override IList Mappings
                {
                        get { return new string[0];
                            }
                }

                #endregion
                protected override void Configure(Cfg.Configuration configuration)
                {
                        var assembly = GetType().Assembly;
                        string mappingNamespace = GetType().Namespace;
                        foreach ( var resource in assembly.GetManifestResourceNames())
                        {
                                if (resource.StartsWith(mappingNamespace) && resource.EndsWith(".hbm.xml"))
                                {
                                        configuration.AddResource(resource, assembly);
                                }
                        }
                }

                public string GetSql(string query)
                {
                        var qt = new QueryTranslatorImpl(null, query, emptyfilters, sessions);
                        qt.Compile(null, false);
                        return qt.SQLString;
                }



Clone Instance
2
Line Count
34
Source Line
11
Source File
src/NHibernate.Test/HQL/Ast/BaseFixture.cs

                private readonly IDictionary<string, IFilter> emptyfilters = new CollectionHelper.EmptyMapClass<string, IFilter> ();

                protected override bool AppliesTo(Engine.ISessionFactoryImplementor factory)
                {
                        return !(sessions.Settings.QueryTranslatorFactory is ClassicQueryTranslatorFactory);
                }

                #region Overrides of TestCase

                protected override IList Mappings
                {
                        get { return new string[0];
                            }
                }

                #endregion
                protected override void Configure(Cfg.Configuration configuration)
                {
                        var assembly = GetType().Assembly;
                        string mappingNamespace = GetType().Namespace;
                        foreach ( var resource in assembly.GetManifestResourceNames())
                        {
                                if (resource.StartsWith(mappingNamespace) && resource.EndsWith(".hbm.xml"))
                                {
                                        configuration.AddResource(resource, assembly);
                                }
                        }
                }

                public string GetSql(string query)
                {
                        var qt = new QueryTranslatorImpl(null, query, emptyfilters, sessions);
                        qt.Compile(null, false);
                        return qt.SQLString;
                }



Clone AbstractionParameter Count: 1Parameter Bindings

private readonly IDictionary<string, IFilter> emptyfilters = new CollectionHelper.EmptyMapClass<string, IFilter> ();

protected override bool AppliesTo(Engine.ISessionFactoryImplementor factory)
{
   return !( [[#variable5e8da5e0]].Settings.QueryTranslatorFactory is ClassicQueryTranslatorFactory);
}

#region Overrides of TestCase
protected override IList Mappings
{
   get
   {
      return new string[0];
   }
}

#endregion
protected override void Configure(Cfg.Configuration configuration)
{
   var assembly = GetType().Assembly;
   string mappingNamespace = GetType().Namespace;
   foreach ( var resource in assembly.GetManifestResourceNames())
   {
      if (resource.StartsWith(mappingNamespace) && resource.EndsWith(".hbm.xml"))
      {
         configuration.AddResource(resource, assembly);
      }
   }
}

public string GetSql(string query)
{
   var qt = new QueryTranslatorImpl(null, query, emptyfilters, sessions);
   qt.Compile(null, false);
   return qt.SQLString;
}

 

CloneAbstraction
Parameter Bindings
Parameter
Index
Clone
Instance
Parameter
Name
Value
11[[#5e8da5e0]]
factory 
12[[#5e8da5e0]]
sessions