Documentation
¶
Index ¶
- func EventTime(event model.MarketEvent) time.Time
- type BarAggregator
- type Catalog
- type ClientHealth
- type Config
- type Engine
- func (e *Engine) AddBarAggregation(barType model.BarType) error
- func (e *Engine) AddClient(client venue.DataClient) error
- func (e *Engine) Events() <-chan model.MarketEvent
- func (e *Engine) Health() Health
- func (e *Engine) Request(ctx context.Context, request model.DataRequest) (model.DataResponse, error)
- func (e *Engine) Start(ctx context.Context) error
- func (e *Engine) Stop(ctx context.Context) error
- func (e *Engine) Subscribe(ctx context.Context, sub model.SubscribeMarketData) error
- func (e *Engine) Unsubscribe(ctx context.Context, sub model.SubscribeMarketData) error
- type Health
- type MemoryCatalog
- type ReplayCatalog
- type RetryPolicy
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type BarAggregator ¶
type BarAggregator struct {
// contains filtered or unexported fields
}
func NewBarAggregator ¶
func NewBarAggregator(barType model.BarType) (*BarAggregator, error)
func (*BarAggregator) Update ¶
func (a *BarAggregator) Update(event model.MarketEvent) (model.Bar, bool, error)
type Catalog ¶
type Catalog interface {
Write(context.Context, ...model.MarketEvent) error
Query(context.Context, model.DataRequest) (model.DataResponse, error)
}
type ClientHealth ¶
type Engine ¶
type Engine struct {
// contains filtered or unexported fields
}
func (*Engine) Events ¶
func (e *Engine) Events() <-chan model.MarketEvent
func (*Engine) Request ¶
func (e *Engine) Request(ctx context.Context, request model.DataRequest) (model.DataResponse, error)
func (*Engine) Unsubscribe ¶
type MemoryCatalog ¶
type MemoryCatalog struct {
// contains filtered or unexported fields
}
func NewMemoryCatalog ¶
func NewMemoryCatalog(events ...model.MarketEvent) *MemoryCatalog
func (*MemoryCatalog) Events ¶
func (c *MemoryCatalog) Events(context.Context) ([]model.MarketEvent, error)
func (*MemoryCatalog) Query ¶
func (c *MemoryCatalog) Query(_ context.Context, request model.DataRequest) (model.DataResponse, error)
func (*MemoryCatalog) Write ¶
func (c *MemoryCatalog) Write(_ context.Context, events ...model.MarketEvent) error
type ReplayCatalog ¶
type RetryPolicy ¶
Click to show internal directories.
Click to hide internal directories.