public GetCelestialByIdQueryHandler(ISqlDataRepository dataRepo, IMapper mapper) { _dataRepo = dataRepo; _mapper = mapper; }
public DeleteCelestialObjectCommandHandler(ISqlDataRepository dataRepo) { _dataRepo = dataRepo; }
public AzureSearchProvider(ISearchConfiguration configuration, ISqlDataRepository sqlDataRepository) { _configuration = configuration; _sqlDataRepository = sqlDataRepository; }
public SearchCelestialQueryHandler(ISqlDataRepository dataRepo, IMapper mapper) { _dataRepo = dataRepo; _mapper = mapper; }
public DataController(ISqlDataRepository repos) { _repos = repos; }
/// <summary> /// Initializes a new instance of the <see cref="SqlContentRepository" /> class. /// </summary> /// <param name="dataRepo">The data repo.</param> /// <param name="connectionStringName">Name of the connection string.</param> /// <param name="tableName">Name of the table.</param> /// <param name="cachePath">The cache path.</param> /// <exception cref="System.ArgumentException">Connection does not exist.</exception> public SqlContentRepository(ISqlDataRepository dataRepo, string connectionStringName, string tableName, string cachePath) { this.Initialize(dataRepo, connectionStringName, tableName, cachePath); }
/// <summary> /// Initializes the specified data repo. /// </summary> /// <param name="dataRepo">The data repo.</param> /// <param name="connectionStringName">Name of the connection string.</param> /// <param name="tableName">Name of the table.</param> /// <param name="cachePath">The cache path.</param> /// <exception cref="System.ArgumentException">Connection does not exist: + connectionStringName</exception> private void Initialize(ISqlDataRepository dataRepo, string connectionStringName, string tableName, string cachePath) { var cstring = ConfigurationManager.ConnectionStrings[connectionStringName]; if (cstring == null) { throw new ArgumentException("Connection does not exist: " + connectionStringName); } this.ConnectionStringName = connectionStringName; this.TableName = illegalTableNameReplace.Replace(tableName ?? "CmsContent", string.Empty); this.CachePath = cachePath; this.DataRepository = dataRepo; if (!schemaExists) { schemaExists = true; this.EnsureSchema(); } }