forked from bblanchon/ArduinoJson
Moved IndentedPrint into the namespace ArduinoJson::Generator
This commit is contained in:
@ -1,5 +1,7 @@
|
|||||||
#include "IndentedPrint.h"
|
#include "IndentedPrint.h"
|
||||||
|
|
||||||
|
using namespace ArduinoJson::Generator;
|
||||||
|
|
||||||
void IndentedPrint::indent()
|
void IndentedPrint::indent()
|
||||||
{
|
{
|
||||||
if (level<127)
|
if (level<127)
|
||||||
|
@ -7,9 +7,13 @@
|
|||||||
|
|
||||||
#include "Print.h"
|
#include "Print.h"
|
||||||
|
|
||||||
class IndentedPrint : public Print
|
namespace ArduinoJson
|
||||||
{
|
{
|
||||||
public:
|
namespace Generator
|
||||||
|
{
|
||||||
|
class IndentedPrint : public Print
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
|
||||||
IndentedPrint(Print& p)
|
IndentedPrint(Print& p)
|
||||||
: sink(p)
|
: sink(p)
|
||||||
@ -23,11 +27,13 @@ public:
|
|||||||
void indent();
|
void indent();
|
||||||
void unindent();
|
void unindent();
|
||||||
|
|
||||||
private:
|
private:
|
||||||
Print& sink;
|
Print& sink;
|
||||||
uint8_t level : 7;
|
uint8_t level : 7;
|
||||||
bool isNewLine : 1;
|
bool isNewLine : 1;
|
||||||
|
|
||||||
size_t writeTabs();
|
size_t writeTabs();
|
||||||
};
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user