MCPcopy Create free account
hub / github.com/ElementsProject/lightning / json_add_node_bias

Function json_add_node_bias

plugins/askrene/layer.c:1264–1279  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1262}
1263
1264void json_add_node_bias(struct json_stream *js,
1265 const char *fieldname,
1266 const struct node_bias *b,
1267 const struct layer *layer)
1268{
1269 json_object_start(js, fieldname);
1270 if (layer)
1271 json_add_string(js, "layer", layer->name);
1272 json_add_node_id(js, "node", &b->node);
1273 if (b->description)
1274 json_add_string(js, "description", b->description);
1275 json_add_s64(js, "in_bias", b->in_bias);
1276 json_add_s64(js, "out_bias", b->out_bias);
1277 json_add_u64(js, "timestamp", b->timestamp);
1278 json_object_end(js);
1279}
1280
1281static void json_add_layer(struct json_stream *js,
1282 const char *fieldname,

Callers 2

json_add_layerFunction · 0.85
json_askrene_bias_nodeFunction · 0.85

Calls 6

json_object_startFunction · 0.85
json_add_node_idFunction · 0.85
json_add_s64Function · 0.85
json_add_u64Function · 0.85
json_object_endFunction · 0.85
json_add_stringFunction · 0.50

Tested by

no test coverage detected