volume_watch

package
v0.1.5 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 30, 2023 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Msg

type Msg struct {
	tiki.Orders
	Period time.Duration
}

func (Msg) String

func (msg Msg) String() string

type VolumeCheck

type VolumeCheck struct {
	Period time.Duration
	Volume float64
}

func (*VolumeCheck) MarshalJSON

func (cfg *VolumeCheck) MarshalJSON() ([]byte, error)

func (*VolumeCheck) UnmarshalJSON

func (cfg *VolumeCheck) UnmarshalJSON(data []byte) error

type VolumeWatchConfig

type VolumeWatchConfig struct {
	common.BaseConfig
	VolumeChecks []*VolumeCheck
}

func DefaultConfig

func DefaultConfig() VolumeWatchConfig

func (VolumeWatchConfig) IsValid

func (cfg VolumeWatchConfig) IsValid() (bool, error)

type VolumeWatchProcessor

type VolumeWatchProcessor struct {
	*processorCommon.BaseProcessor
	*tiki.TikiClient
	// contains filtered or unexported fields
}

func NewVolumeWatchProcessor

func NewVolumeWatchProcessor(cfg VolumeWatchConfig,
	tikiClient *tiki.TikiClient,
	db *store.Store,
	log logger.Logger,
) (*VolumeWatchProcessor, error)

func (*VolumeWatchProcessor) Queue

func (p *VolumeWatchProcessor) Queue(msg interface{})

func (*VolumeWatchProcessor) Start

func (p *VolumeWatchProcessor) Start(ctx context.Context)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL