MCPcopy Create free account
hub / github.com/RedisGraph/RedisGraph / AR_TOJSON

Function AR_TOJSON

src/arithmetic/string_funcs/string_funcs.c:501–505  ·  view source on GitHub ↗

Returns a JSON string representation of a map value.

Source from the content-addressed store, hash-verified

499
500// Returns a JSON string representation of a map value.
501SIValue AR_TOJSON(SIValue *argv, int argc, void *private_data) {
502 if(SIValue_IsNull(argv[0])) return SI_NullVal();
503 char *buf = JsonEncoder_SIValue(argv[0]);
504 return SI_TransferStringVal(buf);
505}
506
507// returns the original string with leading and trailing whitespace removed.
508SIValue AR_TRIM(SIValue *argv, int argc, void *private_data) {

Callers

nothing calls this directly

Calls 4

SIValue_IsNullFunction · 0.85
SI_NullValFunction · 0.85
JsonEncoder_SIValueFunction · 0.85
SI_TransferStringValFunction · 0.85

Tested by

no test coverage detected