MCPcopy Create free account
hub / github.com/bloomberg/comdb2 / cson_array_get

Function cson_array_get

cson/cson.c:507–518  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

505 return 0;
506}
507cson_value *cson_array_get(cson_array *ar, unsigned int pos)
508{
509 cson__render(ar->value);
510 char path[256];
511 sprintf(path, "$[%d]", pos);
512 cson_get *get = cson__get(ar->value, path);
513 if (!get) {
514 return NULL;
515 }
516 LIST_INSERT_HEAD(&ar->get_list, get, entry);
517 return get->value;
518}
519unsigned int cson_array_length_get(cson_array const *ar)
520{
521 cson__render(ar->value);

Callers 9

do_bindingsFunction · 0.85
dump_sql_eventFunction · 0.85
test_h_arrFunction · 0.85
print_arrayFunction · 0.85
test_jFunction · 0.85
timepart_deserializeFunction · 0.85
cson_to_tableFunction · 0.85
cson_to_table_annotatedFunction · 0.85

Calls 2

cson__renderFunction · 0.85
cson__getFunction · 0.85

Tested by 3

test_h_arrFunction · 0.68
print_arrayFunction · 0.68
test_jFunction · 0.68