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

Method Serialization

smartcontract/service/native/auth/param.go:141–151  ·  view source on GitHub ↗
(sink *common.ZeroCopySink)

Source from the content-addressed store, hash-verified

139}
140
141func (this *DIDsToRoleParam) Serialization(sink *common.ZeroCopySink) {
142 serializeAddress(sink, this.ContractAddr)
143 sink.WriteVarBytes(this.AdminOntID)
144 sink.WriteVarBytes(this.Role)
145
146 utils.EncodeVarUint(sink, uint64(len(this.Persons)))
147 for _, p := range this.Persons {
148 sink.WriteVarBytes(p)
149 }
150 utils.EncodeVarUint(sink, this.KeyNo)
151}
152
153func (this *DIDsToRoleParam) Deserialization(source *common.ZeroCopySource) error {
154 var err error

Callers 1

Calls 3

EncodeVarUintFunction · 0.92
serializeAddressFunction · 0.85
WriteVarBytesMethod · 0.80

Tested by 1