public static ASFBuilder AddSQLiteCache(this ASFBuilder builder, string dbConnectionString) { var options = builder.Services.GetDefaultConfiguration(); options.DbConnectionString = dbConnectionString; builder.Services.AddAnticorrsives(options); builder.AddRepositoriesCache(options); return(builder); }
public static ASFBuilder AddSQLiteCache(this ASFBuilder builder, Action <ASFOptions> startupAction) { ASFOptions options = new ASFOptions(); startupAction?.Invoke(options); builder.Services.AddAnticorrsives(options); builder.AddRepositoriesCache(options); return(builder); }
public static ASFBuilder AddDbContextCache(this ASFBuilder builder, Action <DbContextOptionsBuilder> configureDbContext) { builder.Services.AddDbContext <RepositoryContext>(configureDbContext); builder.AddRepositoriesCache(); return(builder); }