MCPcopy Create free account
hub / github.com/apache/thrift / deserializeJSON

Function deserializeJSON

lib/nodejs/test/deep-constructor.test.js:57–65  ·  view source on GitHub ↗
(serialized, type)

Source from the content-addressed store, hash-verified

55}
56
57function deserializeJSON(serialized, type) {
58 const transport = new thrift.TFramedTransport(serialized);
59 const protocol = new thrift.TJSONProtocol(transport);
60 protocol.readMessageBegin();
61 const data = new type();
62 data[Symbol.for("read")](protocol);
63 protocol.readMessageEnd();
64 return data;
65}
66
67function createThriftObj() {
68 return new ttypes.Complex({

Callers

nothing calls this directly

Calls 3

readMessageBeginMethod · 0.95
readMessageEndMethod · 0.95
forMethod · 0.80

Tested by

no test coverage detected