mirror of
https://github.com/nspcc-dev/neo-go.git
synced 2025-05-04 09:02:28 +00:00
parent
66471de9d2
commit
e0c7a3b77c
5 changed files with 38 additions and 2 deletions
|
@ -155,6 +155,15 @@ func (c *Client) GetBlockHeader(hash util.Uint256) (*block.Header, error) {
|
|||
return h, nil
|
||||
}
|
||||
|
||||
// GetBlockHeaderCount returns the number of headers in the main chain.
|
||||
func (c *Client) GetBlockHeaderCount() (uint32, error) {
|
||||
var resp uint32
|
||||
if err := c.performRequest("getblockheadercount", request.NewRawParams(), &resp); err != nil {
|
||||
return resp, err
|
||||
}
|
||||
return resp, nil
|
||||
}
|
||||
|
||||
// GetBlockHeaderVerbose returns the corresponding block header information from Json format string
|
||||
// according to the specified script hash.
|
||||
func (c *Client) GetBlockHeaderVerbose(hash util.Uint256) (*result.Header, error) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue