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


C# IDatabaseUnitOfWork类代码示例

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


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

示例1: CreateMediaRepository

 public virtual IMediaRepository CreateMediaRepository(IDatabaseUnitOfWork uow)
 {
     return new MediaRepository(
         uow,
         RuntimeCacheProvider.Current,
         CreateMediaTypeRepository(uow)) { EnsureUniqueNaming = Umbraco.Core.Configuration.UmbracoSettings.EnsureUniqueNaming };
 }
开发者ID:phaniarveti,项目名称:Experiments,代码行数:7,代码来源:RepositoryFactory.cs

示例2: CreateContentTypeRepository

 public virtual IContentTypeRepository CreateContentTypeRepository(IDatabaseUnitOfWork uow)
 {
     return new ContentTypeRepository(
         uow,
         InMemoryCacheProvider.Current,
         new TemplateRepository(uow, NullCacheProvider.Current));
 }
开发者ID:phaniarveti,项目名称:Experiments,代码行数:7,代码来源:RepositoryFactory.cs

示例3: CreateDictionaryRepository

 public virtual IDictionaryRepository CreateDictionaryRepository(IDatabaseUnitOfWork uow)
 {
     return new DictionaryRepository(
         uow,
         InMemoryCacheProvider.Current,
         CreateLanguageRepository(uow));
 }
开发者ID:phaniarveti,项目名称:Experiments,代码行数:7,代码来源:RepositoryFactory.cs

示例4: CreateUserRepository

		internal virtual IUserRepository CreateUserRepository(IDatabaseUnitOfWork uow)
        {
            return new UserRepository(
                uow,
                NullCacheProvider.Current,
                CreateUserTypeRepository(uow));
        }
开发者ID:phaniarveti,项目名称:Experiments,代码行数:7,代码来源:RepositoryFactory.cs

示例5: CreateMediaRepository

 public virtual IMediaRepository CreateMediaRepository(IDatabaseUnitOfWork uow)
 {
     return new MediaRepository(
         uow,
         RuntimeCacheProvider.Current,
         CreateMediaTypeRepository(uow));
 }
开发者ID:phaniarveti,项目名称:Experiments,代码行数:7,代码来源:RepositoryFactory.cs

示例6: CreateRepository

 private MemberRepository CreateRepository(IDatabaseUnitOfWork unitOfWork, out MemberTypeRepository memberTypeRepository)
 {
     memberTypeRepository = new MemberTypeRepository(unitOfWork, NullCacheProvider.Current);
     var tagRepo = new TagsRepository(unitOfWork, NullCacheProvider.Current);
     var repository = new MemberRepository(unitOfWork, NullCacheProvider.Current, memberTypeRepository, tagRepo);
     return repository;
 }
开发者ID:phaniarveti,项目名称:Experiments,代码行数:7,代码来源:MemberRepositoryTest.cs

示例7: CreateRepository

 private ContentRepository CreateRepository(IDatabaseUnitOfWork unitOfWork, out ContentTypeRepository contentTypeRepository)
 {
     var templateRepository = new TemplateRepository(unitOfWork, NullCacheProvider.Current);
     contentTypeRepository = new ContentTypeRepository(unitOfWork, NullCacheProvider.Current, templateRepository);
     var repository = new ContentRepository(unitOfWork, NullCacheProvider.Current, contentTypeRepository, templateRepository);
     return repository;
 }
开发者ID:saciervo,项目名称:Umbraco-CMS,代码行数:7,代码来源:ContentTypeRepositoryTest.cs

示例8: CreateRelationRepository

 public virtual IRelationRepository CreateRelationRepository(IDatabaseUnitOfWork uow)
 {
     return new RelationRepository(
         uow,
         NullCacheProvider.Current,
         CreateRelationTypeRepository(uow));
 }
开发者ID:phaniarveti,项目名称:Experiments,代码行数:7,代码来源:RepositoryFactory.cs

示例9: CreateContentRepository

 public virtual IContentRepository CreateContentRepository(IDatabaseUnitOfWork uow)
 {
     return new ContentRepository(
         uow,
         RuntimeCacheProvider.Current,
         CreateContentTypeRepository(uow),
         CreateTemplateRepository(uow));
 }
开发者ID:phaniarveti,项目名称:Experiments,代码行数:8,代码来源:RepositoryFactory.cs

示例10: CreateContentRepository

 public virtual IContentRepository CreateContentRepository(IDatabaseUnitOfWork uow)
 {
     return new ContentRepository(
         uow,
         _disableAllCache ? (IRepositoryCacheProvider)NullCacheProvider.Current : RuntimeCacheProvider.Current,
         CreateContentTypeRepository(uow),
         CreateTemplateRepository(uow)) { EnsureUniqueNaming = Umbraco.Core.Configuration.UmbracoSettings.EnsureUniqueNaming };
 }
开发者ID:saciervo,项目名称:Umbraco-CMS,代码行数:8,代码来源:RepositoryFactory.cs

示例11: CreateMediaRepository

 public virtual IMediaRepository CreateMediaRepository(IDatabaseUnitOfWork uow)
 {
     return new MediaRepository(
         uow,
         _disableAllCache ? (IRepositoryCacheProvider)NullCacheProvider.Current : RuntimeCacheProvider.Current,
         CreateMediaTypeRepository(uow),
         CreateTagsRepository(uow)) { EnsureUniqueNaming = _settings.Content.EnsureUniqueNaming };
 }
开发者ID:phaniarveti,项目名称:Experiments,代码行数:8,代码来源:RepositoryFactory.cs

示例12: CreateProductVariantRepository

 /// <summary>
 /// Returns an instance of the <see cref="IProductVariantRepository"/>
 /// </summary>
 /// <param name="uow">
 /// The database unit of work
 /// </param>
 /// <returns>
 /// The <see cref="IProductVariantRepository"/>.
 /// </returns>
 internal virtual IProductVariantRepository CreateProductVariantRepository(IDatabaseUnitOfWork uow)
 {
     return new ProductVariantRepository(uow, _disableAllCache ? _nullCacheProvider : _runtimeCacheProvider);
 }
开发者ID:robgha01,项目名称:Merchello,代码行数:13,代码来源:RepositoryFactory.cs

示例13: CreateShipCountryRepository

 /// <summary>
 /// Returns an instance of the <see cref="IShipCountryRepository"/>
 /// </summary>
 /// <param name="uow">
 /// The database unit of work
 /// </param>
 /// <param name="storeSettingService">
 /// The store Setting Service.
 /// </param>
 /// <returns>
 /// The <see cref="IShipCountryRepository"/>.
 /// </returns>
 internal virtual IShipCountryRepository CreateShipCountryRepository(IDatabaseUnitOfWork uow, IStoreSettingService storeSettingService)
 {
     return new ShipCountryRepository(uow, _disableAllCache ? _nullCacheProvider : _runtimeCacheProvider, storeSettingService);
 }
开发者ID:robgha01,项目名称:Merchello,代码行数:16,代码来源:RepositoryFactory.cs

示例14: CreateNotificationMessageRepository

 /// <summary>
 /// Returns and instance of the <see cref="INotificationMessageRepository"/>
 /// </summary>
 /// <param name="uow">
 /// The database unit of work
 /// </param>
 /// <returns>
 /// The <see cref="INotificationMessageRepository"/>.
 /// </returns>
 internal virtual INotificationMessageRepository CreateNotificationMessageRepository(IDatabaseUnitOfWork uow)
 {
     return new NotificationMessageRepository(uow, _disableAllCache ? _nullCacheProvider : _runtimeCacheProvider);
 }
开发者ID:robgha01,项目名称:Merchello,代码行数:13,代码来源:RepositoryFactory.cs

示例15: CreateOfferRedeemedRepository

 /// <summary>
 /// The create redeemed repository.
 /// </summary>
 /// <param name="uow">
 /// The database unit of work.
 /// </param>
 /// <returns>
 /// The <see cref="IOfferRedeemedRepository"/>.
 /// </returns>
 internal virtual IOfferRedeemedRepository CreateOfferRedeemedRepository(IDatabaseUnitOfWork uow)
 {
     return new OfferRedeemedRepository(uow, _disableAllCache ? _nullCacheProvider : _runtimeCacheProvider);
 }
开发者ID:robgha01,项目名称:Merchello,代码行数:13,代码来源:RepositoryFactory.cs


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