Documentation ¶
Index ¶
- Variables
- type CfxCache
- type EthCache
- func (cache *EthCache) GetBlockNumber(client *node.Web3goClient) (*hexutil.Big, error)
- func (cache *EthCache) GetChainId(client *web3go.Client) (*hexutil.Uint64, error)
- func (cache *EthCache) GetClientVersion(client *web3go.Client) (string, error)
- func (cache *EthCache) GetGasPrice(client *web3go.Client) (*hexutil.Big, error)
- func (cache *EthCache) GetNetVersion(client *web3go.Client) (string, error)
- type StatusCache
Constants ¶
This section is empty.
Variables ¶
View Source
var CfxDefault = NewCfx()
View Source
var EthDefault = NewEth()
Functions ¶
This section is empty.
Types ¶
type CfxCache ¶
type CfxCache struct { *StatusCache // contains filtered or unexported fields }
CfxCache memory cache for some core space RPC methods
func (*CfxCache) GetClientVersion ¶
func (cache *CfxCache) GetClientVersion(cfx sdk.ClientOperator) (string, error)
func (*CfxCache) GetGasPrice ¶
type EthCache ¶
type EthCache struct {
// contains filtered or unexported fields
}
EthCache memory cache for some evm space RPC methods
func (*EthCache) GetBlockNumber ¶
func (*EthCache) GetChainId ¶
func (*EthCache) GetClientVersion ¶
func (*EthCache) GetGasPrice ¶
type StatusCache ¶
type StatusCache struct {
// contains filtered or unexported fields
}
StatusCache memory cache for core space status related RPC method suites.
func NewStatusCache ¶
func NewStatusCache() *StatusCache
func (*StatusCache) GetBestBlockHash ¶
func (c *StatusCache) GetBestBlockHash(cfx sdk.ClientOperator) (types.Hash, error)
func (*StatusCache) GetEpochNumber ¶
func (c *StatusCache) GetEpochNumber(cfx sdk.ClientOperator, epoch *types.Epoch) (*hexutil.Big, error)
func (*StatusCache) GetStatus ¶
func (c *StatusCache) GetStatus(cfx sdk.ClientOperator) (types.Status, error)
Click to show internal directories.
Click to hide internal directories.