rpc: implement getnep5balances RPC
This commit is contained in:
parent
6d270c4550
commit
2757882d26
7 changed files with 93 additions and 3 deletions
|
@ -93,6 +93,16 @@ func (c *Client) GetClaimable(address string) (*result.ClaimableInfo, error) {
|
|||
return resp, nil
|
||||
}
|
||||
|
||||
// GetNEP5Balances is a wrapper for getnep5balances RPC.
|
||||
func (c *Client) GetNEP5Balances(address util.Uint160) (*result.NEP5Balances, error) {
|
||||
params := request.NewRawParams(address.StringLE())
|
||||
resp := new(result.NEP5Balances)
|
||||
if err := c.performRequest("getnep5balances", params, resp); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return resp, nil
|
||||
}
|
||||
|
||||
// GetRawTransaction returns a transaction by hash.
|
||||
func (c *Client) GetRawTransaction(hash util.Uint256) (*transaction.Transaction, error) {
|
||||
var (
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue