MCPcopy Create free account
hub / github.com/DNAProject/DNA / parseNotify

Function parseNotify

vm/crossvm_codec/notify_codec.go:69–77  ·  view source on GitHub ↗

input byte array should be the following format evt\0(4byte) + type(1byte) + usize( bytearray or list) (4 bytes) + data...

(input []byte)

Source from the content-addressed store, hash-verified

67// input byte array should be the following format
68// evt\0(4byte) + type(1byte) + usize( bytearray or list) (4 bytes) + data...
69func parseNotify(input []byte) (interface{}, error) {
70 if bytes.HasPrefix(input, []byte("evt\x00")) == false {
71 return nil, ERROR_PARAM_FORMAT
72 }
73
74 source := common.NewZeroCopySource(input[4:])
75
76 return DecodeValue(source)
77}

Callers 2

DeserializeNotifyFunction · 0.85
TestDe1Function · 0.85

Calls 2

NewZeroCopySourceFunction · 0.92
DecodeValueFunction · 0.85

Tested by 1

TestDe1Function · 0.68