MCPcopy Create free account
hub / github.com/ethstorage/es-node / NewESAPI

Function NewESAPI

ethstorage/node/es_api.go:33–40  ·  view source on GitHub ↗
(config *RPCConfig, sm *ethstorage.StorageManager, dl *downloader.Downloader, lg log.Logger)

Source from the content-addressed store, hash-verified

31)
32
33func NewESAPI(config *RPCConfig, sm *ethstorage.StorageManager, dl *downloader.Downloader, lg log.Logger) *esAPI {
34 return &esAPI{
35 rpcCfg: config,
36 sm: sm,
37 dl: dl,
38 lg: lg,
39 }
40}
41
42func (api *esAPI) GetBlob(kvIndex uint64, blobHash common.Hash, decodeType DecodeType, off, size uint64) (hexutil.Bytes, error) {
43 blob := api.dl.Cache.GetKeyValueByIndex(kvIndex, blobHash)

Callers 1

newRPCServerFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected