Documentation ¶
Index ¶
- type GrpcClient
- func (g *GrpcClient) GetAccount(address string) (*core.Account, error)
- func (g *GrpcClient) GetBlockByID(id string) (*core.Block, error)
- func (g *GrpcClient) GetBlockByNum(num int64) (*api.BlockExtention, error)
- func (g *GrpcClient) GetBlockInfoByNum(num int64) (*api.TransactionInfoList, error)
- func (g *GrpcClient) GetNowBlock() (*api.BlockExtention, error)
- func (g *GrpcClient) GetTransactionInfoByID(id string) (*core.TransactionInfo, error)
- func (g *GrpcClient) ParseContractNumericProperty(data string) (*big.Int, error)
- func (g *GrpcClient) Sign(tx *core.Transaction, OutAddressPrivateKey string) (*api.Return, error)
- func (g *GrpcClient) Stop()
- func (g *GrpcClient) Transfer(from, toAddress string, amount int64) (*api.TransactionExtention, error)
- func (g *GrpcClient) TriggerConstantContract(from, contractAddress, method, parameter string) (*api.TransactionExtention, error)
- func (g *GrpcClient) TriggerContract(from, contractAddress, method, parameter string, feeLimit int64) (*api.TransactionExtention, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type GrpcClient ¶
type GrpcClient struct { Client api.WalletClient Ctx context.Context Conn *grpc.ClientConn }
func NewGrpcClient ¶
func NewGrpcClient(address, apikey string, opts ...grpc.DialOption) (*GrpcClient, error)
func (*GrpcClient) GetAccount ¶ added in v0.1.1
func (g *GrpcClient) GetAccount(address string) (*core.Account, error)
func (*GrpcClient) GetBlockByID ¶
func (g *GrpcClient) GetBlockByID(id string) (*core.Block, error)
func (*GrpcClient) GetBlockByNum ¶
func (g *GrpcClient) GetBlockByNum(num int64) (*api.BlockExtention, error)
func (*GrpcClient) GetBlockInfoByNum ¶
func (g *GrpcClient) GetBlockInfoByNum(num int64) (*api.TransactionInfoList, error)
func (*GrpcClient) GetNowBlock ¶
func (g *GrpcClient) GetNowBlock() (*api.BlockExtention, error)
func (*GrpcClient) GetTransactionInfoByID ¶ added in v0.1.1
func (g *GrpcClient) GetTransactionInfoByID(id string) (*core.TransactionInfo, error)
func (*GrpcClient) ParseContractNumericProperty ¶
func (g *GrpcClient) ParseContractNumericProperty(data string) (*big.Int, error)
func (*GrpcClient) Sign ¶
func (g *GrpcClient) Sign(tx *core.Transaction, OutAddressPrivateKey string) (*api.Return, error)
func (*GrpcClient) Stop ¶
func (g *GrpcClient) Stop()
func (*GrpcClient) Transfer ¶
func (g *GrpcClient) Transfer(from, toAddress string, amount int64) (*api.TransactionExtention, error)
func (*GrpcClient) TriggerConstantContract ¶
func (g *GrpcClient) TriggerConstantContract(from, contractAddress, method, parameter string) (*api.TransactionExtention, error)
func (*GrpcClient) TriggerContract ¶
func (g *GrpcClient) TriggerContract(from, contractAddress, method, parameter string, feeLimit int64) (*api.TransactionExtention, error)
Click to show internal directories.
Click to hide internal directories.