Added an overload of prettyPrintTo()

This commit is contained in:
Benoit Blanchon committed 2014-09-01 21:22:56 +02:00
1 parent cd88fb0882
commit 763aa7fe37
2 files changed
+9 -2

No files matched your search

+7 -1
View File
@@ -10,12 +10,18 @@
using namespace ArduinoJson::Generator;
using namespace ArduinoJson::Internals;
size_t JsonPrintable::printTo(char* buffer, size_t bufferSize)
size_t JsonPrintable::printTo(char* buffer, size_t bufferSize) const
{
StringBuilder sb(buffer, bufferSize);
return printTo(sb);
}
size_t JsonPrintable::prettyPrintTo(char* buffer, size_t bufferSize) const
{
StringBuilder sb(buffer, bufferSize);
return prettyPrintTo(sb);
}
size_t JsonPrintable::prettyPrintTo(IndentedPrint& p) const
{
JsonPrettyPrint prettyPrint(p);