• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

C# IDbContext类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

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



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

示例1: EmailService

 public EmailService(IDbContext context, Logger logger, ApplicationService applicationService, EmailLogService emailLogService)
 {
     _ctx = context;
     _logger = logger;
     _applicationService = applicationService;
     _emailLogService = emailLogService;
 }
开发者ID:SomeHero,项目名称:SocialPayments,代码行数:7,代码来源:EmailService.cs


示例2: FulltextService

 /// <summary>
 /// Ctor
 /// </summary>
 /// <param name="dataProvider">Data provider</param>
 /// <param name="dbContext">Database Context</param>
 /// <param name="commonSettings">Common settings</param>
 public FulltextService(IDataProvider dataProvider, IDbContext dbContext,
     CommonSettings commonSettings)
 {
     this._dataProvider = dataProvider;
     this._dbContext = dbContext;
     this._commonSettings = commonSettings;
 }
开发者ID:nopmcs,项目名称:mycreativestudio,代码行数:13,代码来源:FulltextService.cs


示例3: ScoresController

 public ScoresController(IDbContext context, ICompiler compiler, IRunner runner, Participant participant = null)
 {
     _context = context;
     _compiler = compiler;
     _runner = runner;
     _participant = participant ?? GetCurrentParticipant();
 }
开发者ID:prademak,项目名称:JavaProgrammingContest,代码行数:7,代码来源:ScoresController.cs


示例4: UserPanelController

 public UserPanelController(IDbContext dbContext, ITechnicalStaffService technicalStaffService, IParticipationService participationService, ITechnicalStaffRoleService technicalStaffRoleService)
 {
     _dbContext = dbContext;
     _technicalStaffService = technicalStaffService;
     _participationService = participationService;
     _technicalStaffRoleService = technicalStaffRoleService;
 }
开发者ID:raminmjj,项目名称:SportsSystem,代码行数:7,代码来源:UserPanelController.cs


示例5: GoogleFeedService

        public GoogleFeedService(
			IRepository<GoogleProductRecord> gpRepository,
			IProductService productService,
			IManufacturerService manufacturerService,
			FroogleSettings settings,
			IMeasureService measureService,
			MeasureSettings measureSettings,
			IDbContext dbContext,
			AdminAreaSettings adminAreaSettings,
			ICurrencyService currencyService,
			ICommonServices services,
			IComponentContext ctx)
        {
            _gpRepository = gpRepository;
            _productService = productService;
            _manufacturerService = manufacturerService;
            Settings = settings;
            _measureService = measureService;
            _measureSettings = measureSettings;
            _dbContext = dbContext;
            _adminAreaSettings = adminAreaSettings;
            _currencyService = currencyService;
            _services = services;

            _helper = new FeedPluginHelper(ctx, "SmartStore.GoogleMerchantCenter", "SmartStore.GoogleMerchantCenter", () =>
            {
                return Settings as PromotionFeedSettings;
            });
        }
开发者ID:mandocaesar,项目名称:Mesinku,代码行数:29,代码来源:GoogleFeedService.cs


示例6: MeetingDtb

 public MeetingDtb(IDbContext context, UserBus userBus, MeetingBus meetingBus, AttachmentBus attachmentBus)
     : base(context)
 {
     _userBus = userBus;
     _meetingBus = meetingBus;
     _attachmentBus = attachmentBus;
 }
开发者ID:phamquang1201,项目名称:VPQH,代码行数:7,代码来源:MeetingDtb.cs


示例7: SearchCategorySelectionRepository

        public SearchCategorySelectionRepository(IDbContext context)
        {
            if (context == null)
            throw new ArgumentNullException("connectionString");

              this.CurrentContext = context;
        }
开发者ID:mkeeton,项目名称:Projects,代码行数:7,代码来源:SearchCategorySelectionRepository.cs


示例8: CustomerService

 public CustomerService(IDbContext context, IRepository<Customer> customerRepository, IRepository<CustomerRole> customerRoleRepository, IRepository<ContactU> contactUsRepository)
 {
     this._context = context;
     this._customerRepository = customerRepository;
      this._customerRoleRepository=customerRoleRepository;
      this._contactUsRepository = contactUsRepository;
 }
开发者ID:careerengine,项目名称:EGSW-Project,代码行数:7,代码来源:CustomerService.cs


示例9: DbContextScope

		public DbContextScope(IDbContext ctx = null, 
			bool? autoDetectChanges = null, 
			bool? proxyCreation = null, 
			bool? validateOnSave = null, 
			bool? forceNoTracking = null,
			bool? hooksEnabled = null)
        {
			_ctx = ctx ?? EngineContext.Current.Resolve<IDbContext>();
			_autoDetectChangesEnabled = _ctx.AutoDetectChangesEnabled;
			_proxyCreationEnabled = _ctx.ProxyCreationEnabled;
			_validateOnSaveEnabled = _ctx.ValidateOnSaveEnabled;
			_forceNoTracking = _ctx.ForceNoTracking;
			_hooksEnabled = _ctx.HooksEnabled;
            
            if (autoDetectChanges.HasValue)
				_ctx.AutoDetectChangesEnabled = autoDetectChanges.Value;

            if (proxyCreation.HasValue)
				_ctx.ProxyCreationEnabled = proxyCreation.Value;

            if (validateOnSave.HasValue)
				_ctx.ValidateOnSaveEnabled = validateOnSave.Value;

			if (forceNoTracking.HasValue)
				_ctx.ForceNoTracking = forceNoTracking.Value;

			if (hooksEnabled.HasValue)
				_ctx.HooksEnabled = hooksEnabled.Value;
        }
开发者ID:boatengfrankenstein,项目名称:SmartStoreNET,代码行数:29,代码来源:DbContextScope.cs


示例10: UnitOfWork

        public UnitOfWork(IDbContext context)
        {
            if (context == null)
            throw new ArgumentNullException("connectionString");

              this._dbContext = context;
        }
开发者ID:mkeeton,项目名称:Projects,代码行数:7,代码来源:UnitOfWork.cs


示例11: AUSaleService

        public AUSaleService(
            IRepository<AULotRecord> lotRepo,
            IConsignorService consignorService,
            IAuthenticationService authenticationService,
            IRepository<AUConsignmentLotRecord> consignmentlotRepo,
            IRepository<AUCountryLotRecord> countrylotRepo,
            IRepository<AUStateProvinceLotRecord> stateprovincelotRepo,
            IRepository<AULotLotRecord> lotlotRepo,
            IRepository<AUSaleRecord> saleRepo,
            IProductService productService,
            IDataProvider dataProvider,
            IDbContext dbContext,
            ICategoryService categoryService

            )
        {
            this._lotRepo = lotRepo;
            this._consignorService = consignorService;
            this._authenticationService = authenticationService;
            this._consignmentlotRepo = consignmentlotRepo;
            this._countrylotRepo = countrylotRepo;
            this._stateprovincelotRepo = stateprovincelotRepo;
            this._lotlotRepo = lotlotRepo;
            this._saleRepo = saleRepo;
            this._productService = productService;
            this._dataProvider = dataProvider;
            this._dbContext = dbContext;
            this._categoryService = categoryService;
        }
开发者ID:HumanSystems,项目名称:nopcommerce-dev,代码行数:29,代码来源:AUSaleService.cs


示例12: BaseController

        public BaseController(IDbContext context) {
            if (context == null) {
                throw new ArgumentNullException("dbContext");
            }

            this.context = context;
        }
开发者ID:nicolascaorsi,项目名称:.NET-Boilerplate,代码行数:7,代码来源:BaseController.cs


示例13: PlatformDb

        public PlatformDb(IDbContext context)
        {
            #region Preconditions

            if (context == null)
                throw new ArgumentNullException(nameof(context));

            #endregion

            this.context = context;
            
            Apps              = new Dataset<App>(context);
            AppInstances      = new Dataset<AppInstance>(context);
            AppReleases       = new Dataset<AppRelease>(context);
            AppEvents         = new Dataset<AppEvent>(context);
            AppErrors         = new Dataset<AppError>(context);

            // Frontends
            Frontends         = new Dataset<Frontend>(context);
            FrontendBranches  = new Dataset<FrontendBranch>(context);
            FrontendReleases  = new Dataset<FrontendRelease>(context);

            // Networks
            Networks          = new Dataset<Network>(context);
            NetworkInterfaces = new Dataset<NetworkInterfaceInfo>(context);

            Hosts             = new Dataset<Host>(context);
            Volumes           = new Dataset<VolumeInfo>(context);
            Images            = new Dataset<Image>(context);
        }
开发者ID:carbon,项目名称:Platform,代码行数:30,代码来源:PlatformDb.cs


示例14: AccountController

 public AccountController(IDbContext dbContext, IRepresentativeUserService representativeUserService, IFormsAuthenticationService formsAuthentication, IUserService userService)
 {
     _dbContext = dbContext;
     _representativeUserService = representativeUserService;
     _formsAuthentication = formsAuthentication;
     _userService = userService;
 }
开发者ID:raminmjj,项目名称:SportsSystem,代码行数:7,代码来源:AccountController.cs


示例15: RunController

 public RunController(IDbContext context, ICompiler compiler, IRunner runner, Participant participant = null)
 {
     _context = context;
     _compiler = compiler;
     _runner = runner;
     _participant = participant == null ? GetCurrentParticipant() : participant;
 }
开发者ID:prademak,项目名称:JavaProgrammingContest,代码行数:7,代码来源:RunController.cs


示例16: CakeRepository

        public CakeRepository(IDbContext context)
        {
            if (context == null)
            throw new ArgumentNullException("connectionString");

              this.CurrentContext = context;
        }
开发者ID:mkeeton,项目名称:Projects,代码行数:7,代码来源:CakeRepository.cs


示例17: DefaultLogger

 public DefaultLogger(IRepository<Log> logRepository, IWebHelper webHelper, IDbContext dbContext, IWorkContext workContext)
 {
     this._logRepository = logRepository;
     this._webHelper = webHelper;
     this._dbContext = dbContext;
     this._workContext = workContext;
 }
开发者ID:mandocaesar,项目名称:Mesinku,代码行数:7,代码来源:DefaultLogger.cs


示例18: DefaultLogger

 /// <summary>
 /// Ctor
 /// </summary>
 /// <param name="logRepository">Log repository</param>
 /// <param name="webHelper">Web helper</param>>
 /// <param name="dbContext">DB context</param>>
 /// <param name="dataProvider">WeData provider</param>
 /// <param name="commonSettings">Common settings</param>
 public DefaultLogger(IRepository<Log> logRepository, IWebHelper webHelper, IDbContext dbContext, IDataProvider dataProvider)
 {
     this._logRepository = logRepository;
     this._webHelper = webHelper;
     this._dbContext = dbContext;
     this._dataProvider = dataProvider;
 }
开发者ID:omidghorbani,项目名称:SmartStoreNET,代码行数:15,代码来源:DefaultLogger.cs


示例19: MsgRecordService

 public MsgRecordService(IRepository<MsgRecord> _msgRecordRepository, IRepository<ContactGroupSub> _contactGroupSubRepository
     , IDbContext _context)
 {
     msgRecordRepository = _msgRecordRepository;
     context = _context;
     contactGroupSubRepository = _contactGroupSubRepository;
 }
开发者ID:xuailhd,项目名称:ImmediatelyChat_UDP,代码行数:7,代码来源:MsgRecordService.cs


示例20: SportService

 public SportService(IDbContext dbContext)
 {
     _dbContext = dbContext;
     _sports = dbContext.Set<Sport>();
     _sportCategories = dbContext.Set<SportCategory>();
     _sportDetails = dbContext.Set<SportDetail>();
 }
开发者ID:raminmjj,项目名称:SportsSystem,代码行数:7,代码来源:SportService.cs



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


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C# IDbContextFactory类代码示例发布时间:2022-05-24
下一篇:
C# IDbConnectionFactory类代码示例发布时间:2022-05-24
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap