Exemplo n.º 1
0
 public TenantService(
     ITenantRepository tenantRepository,
     ITenantFactory tenantFactory)
 {
     this.tenantRepository = tenantRepository;
     this.tenantFactory    = tenantFactory;
 }
Exemplo n.º 2
0
 public ComponentService(ILogger <ComponentService> logger, ITenantRepository tenantRepository, IStorageHubService storageHubService, ITenantFactory tenantFactory)
 {
     _logger            = logger;
     _tenantRepository  = tenantRepository;
     _storageHubService = storageHubService;
     _tenantFactory     = tenantFactory;
 }
Exemplo n.º 3
0
 public TenantsController(IConfiguration configuration,
                          IWebHostEnvironment hostingEnvironment,
                          ITenantFactory tenantFactory)
     : base(configuration, hostingEnvironment)
 {
     _tenantFactory = tenantFactory;
 }
Exemplo n.º 4
0
 public RepositoryBase(TDbContext db, IJsonConfig jsonConfig, ITenantFactory tenantFactory)
 {
     _jsonConfig    = jsonConfig;
     _tenantFactory = tenantFactory;
     Db             = db;
     This           = db.Set <TEntity>();
     SetPredicate();
 }
Exemplo n.º 5
0
        public TenantMemoryRepository(ILogger <TenantMemoryRepository> logger, List <TenantConfiguration> tenantConfigurations, ITenantFactory tenantFactory)
        {
            this.logger        = logger;
            this.tenantFactory = tenantFactory;

            _tenants = new ConcurrentDictionary <string, Tenant>();

            AddTenantsFromConfiguration(tenantConfigurations);
        }
        public ContextUtilities(
            ITenantFactory tenantFactory
            )
        {
            //Contract.Requires<ArgumentNullException>(tenantFactory == null);
            if (tenantFactory == null)
                throw new ArgumentNullException("tenantFactory");

            this.tenantFactory = tenantFactory;
        }
Exemplo n.º 7
0
        public MongoFactory(ITenantFactory tenantFactory, string clientId)
        {
            _tenantFactory = tenantFactory;

            var tenantProfile = AsyncHelper.RunSync(() => _tenantFactory.GetTenantByTenantIdAsync(clientId));

            var mongoClient = new MongoContext(tenantProfile.GetMongoDBConnectionString(), tenantProfile.MongoDbDatabase);

            Database = mongoClient.Database;
        }
Exemplo n.º 8
0
        public ContextUtilities(
            ITenantFactory tenantFactory
            )
        {
            //Contract.Requires<ArgumentNullException>(tenantFactory == null);
            if (tenantFactory == null)
            {
                throw new ArgumentNullException("tenantFactory");
            }

            this.tenantFactory = tenantFactory;
        }
Exemplo n.º 9
0
 public ConsumerHub(ILogger <ConsumerHub> logger,
                    IConsumerHubRepository consumerHubRepository,
                    ITenantRepository tenantRepository,
                    ITenantFactory tenantFactory,
                    IConsumerFactory consumerFactory,
                    IStorageHubService storageHubService)
 {
     this.logger = logger;
     this.consumerHubRepository = consumerHubRepository;
     this.tenantRepository      = tenantRepository;
     this.tenantFactory         = tenantFactory;
     this.consumerFactory       = consumerFactory;
     this.storageHubService     = storageHubService;
 }
Exemplo n.º 10
0
 public ProducerHub(ILogger <ProducerHub> logger,
                    IProducerHubRepository producerHubRepository,
                    ITenantRepository tenantRepository,
                    ITenantFactory tenantFactory,
                    IProducerFactory producerFactory,
                    IStorageHubService storageHubService,
                    IConsumerHubService consumerHubService)
 {
     this.logger = logger;
     this.producerHubRepository = producerHubRepository;
     this.tenantRepository      = tenantRepository;
     this.tenantFactory         = tenantFactory;
     this.producerFactory       = producerFactory;
     this.storageHubService     = storageHubService;
     this.consumerHubService    = consumerHubService;
 }
Exemplo n.º 11
0
 public DataContext(IHttpContextAccessor httpContextAccessor)
 {
     _httpContextAccessor = httpContextAccessor;
     TenantFactory        = new TenantFactory(_httpContextAccessor.HttpContext);
 }
Exemplo n.º 12
0
 public DataContext(ITenantFactory tenantFactory)
 {
     _tenantFactory = tenantFactory;
     AuditList      = new List <DtoEntityAudit>();
 }
Exemplo n.º 13
0
 public ProductService(ILogger <ProductService> logger, ITenantRepository tenantRepository, ITenantFactory tenantFactory)
 {
     _logger           = logger;
     _tenantRepository = tenantRepository;
     _tenantFactory    = tenantFactory;
 }
Exemplo n.º 14
0
 public AccountsController(IConfiguration configuration, IWebHostEnvironment hostingEnvironment,
                           OAuthClient oAuthClient, ITenantFactory tenantFactory) : base(configuration, hostingEnvironment)
 {
     _oAuthClient   = oAuthClient;
     _tenantFactory = tenantFactory;
 }
Exemplo n.º 15
0
 public DfTestContext(ITenantFactory tenantFactory, IJsonConfig jsonConfig) : base(tenantFactory)
 {
     _jsonConfig = jsonConfig;
 }
Exemplo n.º 16
0
 public TopicService(ILogger <TopicService> logger, ITenantRepository tenantRepository, ITenantFactory tenantFactory)
 {
     _logger           = logger;
     _tenantRepository = tenantRepository;
     _tenantFactory    = tenantFactory;
 }