Documentation ¶
Index ¶
- Constants
- func CreateConstraint(ctx context.Context, db *pgxpool.Pool)
- type BacktestPostgres
- func (db *BacktestPostgres) Create(ctx context.Context, strategy string, backtest *storage.Backtest) error
- func (db *BacktestPostgres) Delete(ctx context.Context, id string) error
- func (db *BacktestPostgres) Get(ctx context.Context, id string) (*storage.Backtest, error)
- func (db *BacktestPostgres) List(ctx context.Context, strategy string) ([]*storage.Backtest, error)
- func (db *BacktestPostgres) ListByStage(ctx context.Context, stages ...string) ([]*storage.Backtest, error)
- func (db *BacktestPostgres) Update(ctx context.Context, backtest *storage.Backtest) error
- type PeriodPostgres
- type StrategyPostgres
- func (db *StrategyPostgres) Create(ctx context.Context, strategy *storage.Strategy) error
- func (db *StrategyPostgres) Delete(ctx context.Context, name string) error
- func (db *StrategyPostgres) Get(ctx context.Context, name string) (*storage.Strategy, error)
- func (db *StrategyPostgres) List(ctx context.Context) ([]*storage.Strategy, error)
- func (db *StrategyPostgres) Update(ctx context.Context, strategy *storage.Strategy) error
Constants ¶
View Source
const ExecutionTable = `` /* 325-byte string literal not displayed */
View Source
const PeriodTable = `` /* 822-byte string literal not displayed */
View Source
const StrategyTable = `CREATE TABLE IF NOT EXISTS strategy (
name text PRIMARY KEY,
backtest text,
worker text);`
Variables ¶
This section is empty.
Functions ¶
Types ¶
type BacktestPostgres ¶
func (*BacktestPostgres) Delete ¶
func (db *BacktestPostgres) Delete(ctx context.Context, id string) error
func (*BacktestPostgres) ListByStage ¶
type PeriodPostgres ¶
Click to show internal directories.
Click to hide internal directories.