powergate: github.com/textileio/powergate/index/ask/runner Index | Files

package runner

import "github.com/textileio/powergate/index/ask/runner"


Package Files


type Runner Uses

type Runner struct {
    // contains filtered or unexported fields

Runner contains cached information about markets.

func New Uses

func New(ds datastore.TxnDatastore, clientBuilder lotus.ClientBuilder) (*Runner, error)

New returns a new ask index runner. It load a persisted ask index, and immediately starts building a new fresh one.

func (*Runner) Close Uses

func (ai *Runner) Close() error

Close closes the AskIndex.

func (*Runner) Get Uses

func (ai *Runner) Get() ask.Index

Get returns a copy of the current index data.

func (*Runner) Listen Uses

func (ai *Runner) Listen() <-chan struct{}

Listen returns a new channel signaler that notifies when the index gets updated.

func (*Runner) Query Uses

func (ai *Runner) Query(q ask.Query) ([]ask.StorageAsk, error)

Query executes a query to retrieve active Asks.

func (*Runner) Unregister Uses

func (ai *Runner) Unregister(c chan struct{})

Unregister unregisters a channel signaler from the signaler hub.

Package runner imports 17 packages (graph) and is imported by 9 packages. Updated 2020-09-21. Refresh now. Tools for package owners.