node

package
v0.42.16 Latest Latest
Warning

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

Go to latest
Published: Jul 27, 2022 License: MIT Imports: 11 Imported by: 0

Documentation

Overview

Package node contains functionality for interacting with Vega data nodes.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DataNode added in v0.41.0

type DataNode struct {
	// contains filtered or unexported fields
}

DataNode stores state for a Vega Data node.

func NewDataNode added in v0.41.0

func NewDataNode(hosts []string, callTimeout time.Duration) *DataNode

NewDataNode returns a new node.

func (*DataNode) AssetByID added in v0.41.0

func (n *DataNode) AssetByID(req *dataapipb.AssetByIDRequest) (response *dataapipb.AssetByIDResponse, err error)

AssetByID returns the specified asset.

func (*DataNode) DialConnection added in v0.42.0

func (n *DataNode) DialConnection(ctx context.Context) chan struct{}

func (*DataNode) LastBlockData added in v0.41.0

func (n *DataNode) LastBlockData() (*vegaapipb.LastBlockHeightResponse, error)

LastBlockData gets the latest blockchain data, height, hash and pow parameters.

func (*DataNode) MarketDataByID added in v0.41.0

func (n *DataNode) MarketDataByID(req *dataapipb.MarketDataByIDRequest) (response *dataapipb.MarketDataByIDResponse, err error)

MarketDataByID returns market data for the specified market.

func (*DataNode) Markets added in v0.41.0

func (n *DataNode) Markets(req *dataapipb.MarketsRequest) (response *dataapipb.MarketsResponse, err error)

Markets returns all markets.

func (*DataNode) ObserveEventBus added in v0.41.0

func (n *DataNode) ObserveEventBus(ctx context.Context) (client vegaapipb.CoreService_ObserveEventBusClient, err error)

ObserveEventBus opens a stream.

func (*DataNode) PartyAccounts added in v0.41.0

func (n *DataNode) PartyAccounts(req *dataapipb.PartyAccountsRequest) (response *dataapipb.PartyAccountsResponse, err error)

PartyAccounts returns accounts for the given party.

func (*DataNode) PositionsByParty added in v0.41.0

func (n *DataNode) PositionsByParty(req *dataapipb.PositionsByPartyRequest) (response *dataapipb.PositionsByPartyResponse, err error)

PositionsByParty returns positions for the given party.

func (*DataNode) PositionsSubscribe added in v0.41.0

PositionsSubscribe opens a stream.

func (*DataNode) SubmitTransaction added in v0.41.0

func (n *DataNode) SubmitTransaction(req *vegaapipb.SubmitTransactionRequest) (response *vegaapipb.SubmitTransactionResponse, err error)

SubmitTransaction submits a signed v2 transaction.

func (*DataNode) Target added in v0.42.0

func (n *DataNode) Target() string

func (*DataNode) WaitForStateChange added in v0.42.0

func (n *DataNode) WaitForStateChange(ctx context.Context, state connectivity.State) bool

Jump to

Keyboard shortcuts

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