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

Function DecodeChunk

ethstorage/data_shard.go:299–301  ·  view source on GitHub ↗

DecodeChunk decodes bs and returns a new decoded bytes

(chunkSize uint64, bs []byte, encodeType uint64, encodeKey common.Hash)

Source from the content-addressed store, hash-verified

297
298// DecodeChunk decodes bs and returns a new decoded bytes
299func DecodeChunk(chunkSize uint64, bs []byte, encodeType uint64, encodeKey common.Hash) []byte {
300 return decodeChunk(chunkSize, bs, encodeType, encodeKey)
301}
302
303func decodeChunk(chunkSize uint64, bs []byte, encodeType uint64, encodeKey common.Hash) []byte {
304 if len(bs) > int(chunkSize) {

Callers 1

DecodeBlobMethod · 0.85

Calls 1

decodeChunkFunction · 0.85

Tested by

no test coverage detected