2014-11-03 14:38:46 +01:00
|
|
|
// Copyright Benoit Blanchon 2014
|
|
|
|
// MIT License
|
|
|
|
//
|
|
|
|
// Arduino JSON library
|
|
|
|
// https://github.com/bblanchon/ArduinoJson
|
|
|
|
|
|
|
|
#include "Printers.hpp"
|
|
|
|
|
|
|
|
std::ostream& ArduinoJson::operator<<(std::ostream& os,
|
2014-11-03 18:23:39 +01:00
|
|
|
const ArduinoJson::JsonValue& v) {
|
|
|
|
if (v.is<long>())
|
|
|
|
os << v.as<long>();
|
|
|
|
else if (v.is<double>())
|
|
|
|
os << v.as<double>();
|
|
|
|
else
|
|
|
|
os << "JsonValue"; // TODO
|
2014-11-03 14:38:46 +01:00
|
|
|
return os;
|
|
|
|
}
|