public PSQLConfigureBuilder(Func <IServiceProvider, PrimaryKey, DefaultConfigParameter, StorageOptions> generator, bool singleton = true) : base((provider, id, parameter) => { var result = generator(provider, id, parameter); result.Connection = provider.GetService <IOptions <PSQLConnections> >().Value.ConnectionDict[result.ConnectionKey]; result.CreateConnectionFunc = connection => PSQLFactory.CreateConnection(connection); result.BuildRepository = new PSQLBuildService(result); return(result); }, singleton) { }
public DbConnection CreateConnection() { return(PSQLFactory.CreateConnection(connection)); }
public override DbConnection CreateConnection() { return(PSQLFactory.CreateConnection(Connection)); }