public SqlRepository(IRepositoryContext repositoryContext) : base(repositoryContext) { if (repositoryContext is ISqlRepositoryContext) { this.sqlRepositoryContext = (ISqlRepositoryContext)repositoryContext; } else { throw new ArgumentException("The specified Repository context is not the instance of ISqlRepositoryContext."); } }
private ICacheManager cacheManager = null; //CacheFactory.GetCacheManager(); public SqlRepository(IRepositoryContext repositoryContext) : base(repositoryContext) { if (repositoryContext is ISqlRepositoryContext) { this.sqlRepositoryContext = (ISqlRepositoryContext)repositoryContext; } else { throw new ArgumentException("The provided repository context type is invalid. SqlRepository requires an instance of SqlRepositoryContext to be initialized."); } }