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

Method IcingaToStreamValue

lib/icingadb/icingadb-utility.cpp:438–451  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

436}
437
438String IcingaDB::IcingaToStreamValue(const Value& value)
439{
440 switch (value.GetType()) {
441 case ValueBoolean:
442 return Convert::ToString(int(value));
443 case ValueString:
444 return Utility::ValidateUTF8(value);
445 case ValueNumber:
446 case ValueEmpty:
447 return Convert::ToString(value);
448 default:
449 return JsonEncode(value);
450 }
451}
452
453// Returns the items that exist in "arrayOld" but not in "arrayNew"
454std::vector<Value> IcingaDB::GetArrayDeletedValues(const Array::Ptr& arrayOld, const Array::Ptr& arrayNew) {

Callers

nothing calls this directly

Calls 1

GetTypeMethod · 0.45

Tested by

no test coverage detected