当前位置: 首页>>代码示例>>C#>>正文


C# Testing.BenchmarksContainer类代码示例

本文整理汇总了C#中CavemanTools.Testing.BenchmarksContainer的典型用法代码示例。如果您正苦于以下问题:C# BenchmarksContainer类的具体用法?C# BenchmarksContainer怎么用?C# BenchmarksContainer使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


BenchmarksContainer类属于CavemanTools.Testing命名空间,在下文中一共展示了BenchmarksContainer类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: FetchSingleEntity

 public override void FetchSingleEntity(BenchmarksContainer bc)
 {
     bc.Add(d=>
                {
                    _cnx.Query<sfPosts>("select * from sfPosts where [email protected]", new {id = 5},commandType:CommandType.Text).FirstOrDefault();
                },Name);
 }
开发者ID:gmav,项目名称:SqlFu,代码行数:7,代码来源:InsightDbTests.cs

示例2: QueryTop10Dynamic

 public override void QueryTop10Dynamic(BenchmarksContainer bc)
 {
     bc.Add(id =>
     {
         _db.sfPosts.FindAll(_db.sfPosts.Id>5).ToArray();
     }, "SimpleData");
 }
开发者ID:eugman,项目名称:SqlFu,代码行数:7,代码来源:SimpleDataTests.cs

示例3: MultiPocoMapping

 public override void MultiPocoMapping(BenchmarksContainer bc)
 {
     bc.Add(id =>
     {
         throw new NotSupportedException();
     }, "SimpleData");
 }
开发者ID:eugman,项目名称:SqlFu,代码行数:7,代码来源:SimpleDataTests.cs

示例4: MultiPocoMapping

 public override void MultiPocoMapping(BenchmarksContainer bc)
 {
     bc.Add(d =>
     {
         _cnx.QuerySql<PostViewModel, IdName>("select *, Id, title as Name from sfposts p where [email protected] order by p.id", new { id = 5 });
     }, Name);
 }
开发者ID:eugman,项目名称:SqlFu,代码行数:7,代码来源:InsightDbTests.cs

示例5: FetchSingleDynamicEntity

 public override void FetchSingleDynamicEntity(BenchmarksContainer bc)
 {
     bc.Add(id =>
     {
         _db.sfPosts.Get(5);
     }, "SimpleData dynamic");
 }
开发者ID:eugman,项目名称:SqlFu,代码行数:7,代码来源:SimpleDataTests.cs

示例6: QueryTop10

 public override void QueryTop10(BenchmarksContainer bc)
 {
     bc.Add(d =>
     {
         _cnx.Query<sfPosts>("select top 10 * from sfPOsts where id>@id", new { id = 5 });                
     }, Name);
 }
开发者ID:eugman,项目名称:SqlFu,代码行数:7,代码来源:ServiceStackTests.cs

示例7: QueryTop10Dynamic

 public override void QueryTop10Dynamic(BenchmarksContainer bc)
 {
     bc.Add(d =>
     {
         _cnx.QuerySql("select top 10 * from sfPosts where id>@id", new { id = 5 }).ToArray();
     }, Name);
 }
开发者ID:eugman,项目名称:SqlFu,代码行数:7,代码来源:InsightDbTests.cs

示例8: FetchSingleDynamicEntity

 public override void FetchSingleDynamicEntity(BenchmarksContainer bc)
 {
     bc.Add(i =>
                {
                    _db.Single(5);
                }, "Massive");
 }
开发者ID:eugman,项目名称:SqlFu,代码行数:7,代码来源:MssiveTests.cs

示例9: QueryTop10

 public override void QueryTop10(BenchmarksContainer bc)
 {
     bc.Add(i =>
                {
                    throw new NotSupportedException("not explicit type support");
                }, "Massive");
 }
开发者ID:eugman,项目名称:SqlFu,代码行数:7,代码来源:MssiveTests.cs

示例10: MultiPocoMapping

 public override void MultiPocoMapping(BenchmarksContainer bc)
 {
     bc.Add(id =>
     {
         _db.Query<PostViewModel,IdName>("select p.*,p.Id ,p.title as Name from sfposts p where [email protected] order by p.id", 5).FirstOrDefault();                
     }, "PetaPoco");
 }
开发者ID:eugman,项目名称:SqlFu,代码行数:7,代码来源:PetaPocoTests.cs

示例11: MultiPocoMapping

 public override void MultiPocoMapping(BenchmarksContainer bc)
 {
     bc.Add(id =>
     {
         _db.IgnoreIfAutoMapFails.Sql("select *,id as Author_Id,title as Author_Name from sfposts where [email protected] order by id", 5).Query<PostViewModel>();
     }, Name);
 }
开发者ID:gmav,项目名称:SqlFu,代码行数:7,代码来源:FluentDataTests.cs

示例12: QueryTop10Dynamic

 public override void QueryTop10Dynamic(BenchmarksContainer bc)
 {
     bc.Add(id =>
                {
                    _db.Query<dynamic>("select top 10 * from sfPosts where id>@0", 5).ToArray();
                }, "PetaPoco dynamic");
 }
开发者ID:eugman,项目名称:SqlFu,代码行数:7,代码来源:PetaPocoTests.cs

示例13: FetchSingleEntity

 public override void FetchSingleEntity(BenchmarksContainer bc)
 {
    bc.Add(id=>
               {
                   _db.Single<sfPosts>("select * from sfPosts where [email protected]", 5);
               },"PetaPoco entity");
 }
开发者ID:eugman,项目名称:SqlFu,代码行数:7,代码来源:PetaPocoTests.cs

示例14: QueryTop10

 public override void QueryTop10(BenchmarksContainer bc)
 {
     bc.Add(d =>
     {
         _cnx.Query<sfPosts>("select top 10 * from sfPosts where id>@id", new { id = 5 }, commandType: CommandType.Text).ToArray();
     }, Name);
 }
开发者ID:gmav,项目名称:SqlFu,代码行数:7,代码来源:InsightDbTests.cs

示例15: MultiPocoMapping

 public override void MultiPocoMapping(BenchmarksContainer bc)
 {
     bc.Add(id =>
     {
         _db.QuerySingle<PostViewModel>("select *,id as Author_Id,title as Author_Name from sfposts where [email protected] order by id",5);
     }, "SqlFu");
 }
开发者ID:eugman,项目名称:SqlFu,代码行数:7,代码来源:SqlFuTests.cs


注:本文中的CavemanTools.Testing.BenchmarksContainer类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。