MCPcopy Create free account
hub / github.com/Icinga/icinga2 / JsonEncode

Method JsonEncode

lib/base/json.cpp:364–370  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

362};
363
364String icinga::JsonEncode(const Value& value, bool prettify)
365{
366 std::string output;
367 JsonEncoder encoder(output, prettify);
368 encoder.Encode(value);
369 return String(std::move(output));
370}
371
372/**
373 * Serializes an Icinga Value into a JSON object and writes it to the given output stream.

Callers

nothing calls this directly

Calls 2

StringClass · 0.70
EncodeMethod · 0.45

Tested by

no test coverage detected