MCPcopy Create free account
hub / github.com/BTCGPU/BTCGPU / Serialize

Method Serialize

src/compressor.h:52–61  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

50
51 template<typename Stream>
52 void Serialize(Stream &s) const {
53 std::vector<unsigned char> compr;
54 if (CompressScript(script, compr)) {
55 s << MakeSpan(compr);
56 return;
57 }
58 unsigned int nSize = script.size() + nSpecialScripts;
59 s << VARINT(nSize);
60 s << MakeSpan(script);
61 }
62
63 template<typename Stream>
64 void Unserialize(Stream &s) {

Callers

nothing calls this directly

Calls 3

CompressScriptFunction · 0.85
MakeSpanFunction · 0.85
sizeMethod · 0.45

Tested by

no test coverage detected