grpc

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: May 13, 2021 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsNotFound

func IsNotFound(err error) bool

IsNotFound returns not found status.

Types

type Client

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

Client wraps GRPC client connection.

func NewClient

func NewClient(grpcURL string, cfg config.CoinMarketCapConfig) (*Client, error)

NewClient creates GRPC client.

func (*Client) GetAllBalances

func (c *Client) GetAllBalances(ctx context.Context, address string) (sdk.Coins, error)

GetAllBalances returns all account balances.

func (*Client) GetAllPools

func (c *Client) GetAllPools(ctx context.Context) (liqtypes.Pools, error)

GetAllPools returns all existing pools.

func (*Client) GetBaseAccountInfo

func (c *Client) GetBaseAccountInfo(ctx context.Context, address string) (authtypes.BaseAccount, error)

GetBaseAccountInfo returns base account information.

func (*Client) GetLiquidityQueryClient

func (c *Client) GetLiquidityQueryClient() liqtypes.QueryClient

GetLiquidityQueryClient returns a object of queryClient

func (*Client) GetPool

func (c *Client) GetPool(ctx context.Context, poolId uint64) (liqtypes.Pool, error)

GetPool returns pool information.

func (*Client) GetPoolReserves

func (c *Client) GetPoolReserves(ctx context.Context, reservePoolDenoms []string) (sdk.Dec, sdk.Dec, error)

GetPoolReserves returns pool reserves of the pool.

func (*Client) GetTxClient

func (c *Client) GetTxClient() sdktx.ServiceClient

GetTxClient returns an object of service client.

Jump to

Keyboard shortcuts

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