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

Function json_add_node_bias

plugins/askrene/layer.c:1235–1250  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1233}
1234
1235void json_add_node_bias(struct json_stream *js,
1236 const char *fieldname,
1237 const struct node_bias *b,
1238 const struct layer *layer)
1239{
1240 json_object_start(js, fieldname);
1241 if (layer)
1242 json_add_string(js, "layer", layer->name);
1243 json_add_node_id(js, "node", &b->node);
1244 if (b->description)
1245 json_add_string(js, "description", b->description);
1246 json_add_s64(js, "in_bias", b->in_bias);
1247 json_add_s64(js, "out_bias", b->out_bias);
1248 json_add_u64(js, "timestamp", b->timestamp);
1249 json_object_end(js);
1250}
1251
1252static void json_add_layer(struct json_stream *js,
1253 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