client

package
v0.0.0-...-aa76b34 Latest Latest
Warning

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

Go to latest
Published: Jan 3, 2024 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client interface {
	Handshake(ctx context.Context, v *proto.Version) (*proto.Version, error)
	NewTransaction(ctx context.Context, t *proto.Transaction) (*proto.Transaction, error)
	NewBlock(ctx context.Context, b *proto.Block) (*proto.Block, error)
	GetBlocks(ctx context.Context, v *proto.Version) (*proto.Blocks, error)
}

type GRPCClient

type GRPCClient struct {
	Endpoint string
	// contains filtered or unexported fields
}

func NewGRPCClient

func NewGRPCClient(endpoint string) (*GRPCClient, error)

func (*GRPCClient) GetBlocks

func (c *GRPCClient) GetBlocks(ctx context.Context, v *proto.Version) (*proto.Blocks, error)

func (*GRPCClient) Handshake

func (c *GRPCClient) Handshake(ctx context.Context, v *proto.Version) (*proto.Version, error)

func (*GRPCClient) NewBlock

func (c *GRPCClient) NewBlock(ctx context.Context, b *proto.Block) (*proto.Block, error)

func (*GRPCClient) NewTransaction

func (c *GRPCClient) NewTransaction(ctx context.Context, t *proto.Transaction) (*proto.Transaction, error)

Jump to

Keyboard shortcuts

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