mirror of
https://github.com/nspcc-dev/neo-go.git
synced 2025-05-04 09:02:28 +00:00
parent
dbfdfd8e9b
commit
770c8d774c
7 changed files with 74 additions and 0 deletions
|
@ -9,6 +9,7 @@ import (
|
|||
"github.com/nspcc-dev/neo-go/pkg/core/block"
|
||||
"github.com/nspcc-dev/neo-go/pkg/core/state"
|
||||
"github.com/nspcc-dev/neo-go/pkg/core/transaction"
|
||||
"github.com/nspcc-dev/neo-go/pkg/crypto/keys"
|
||||
"github.com/nspcc-dev/neo-go/pkg/io"
|
||||
"github.com/nspcc-dev/neo-go/pkg/rpc/request"
|
||||
"github.com/nspcc-dev/neo-go/pkg/rpc/response/result"
|
||||
|
@ -179,6 +180,18 @@ func (c *Client) GetConnectionCount() (int, error) {
|
|||
return resp, nil
|
||||
}
|
||||
|
||||
// GetCommittee returns the current public keys of NEO nodes in committee.
|
||||
func (c *Client) GetCommittee() (keys.PublicKeys, error) {
|
||||
var (
|
||||
params = request.NewRawParams()
|
||||
resp = new(keys.PublicKeys)
|
||||
)
|
||||
if err := c.performRequest("getcommittee", params, resp); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return *resp, nil
|
||||
}
|
||||
|
||||
// GetContractState queries contract information, according to the contract script hash.
|
||||
func (c *Client) GetContractState(hash util.Uint160) (*state.Contract, error) {
|
||||
var (
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue