forked from bblanchon/ArduinoJson
Renamed EscapedString into QuotedString
This commit is contained in:
@ -3,7 +3,7 @@
|
||||
* Benoit Blanchon 2014 - MIT License
|
||||
*/
|
||||
|
||||
#include "ArduinoJson/Internals/EscapedString.h"
|
||||
#include "ArduinoJson/Internals/QuotedString.h"
|
||||
|
||||
using namespace ArduinoJson::Internals;
|
||||
|
||||
@ -30,7 +30,7 @@ static inline size_t printCharTo(char c, Print* p)
|
||||
: p->write(c);
|
||||
}
|
||||
|
||||
size_t EscapedString::printTo(const char* s, Print* p)
|
||||
size_t QuotedString::printTo(const char* s, Print* p)
|
||||
{
|
||||
if (!s) return p->print("null");
|
||||
|
||||
@ -63,7 +63,7 @@ static inline bool isQuote(char c)
|
||||
return c == '\"' || c == '\'';
|
||||
}
|
||||
|
||||
char* EscapedString::extractFrom(char* input, char** endPtr)
|
||||
char* QuotedString::extractFrom(char* input, char** endPtr)
|
||||
{
|
||||
char firstChar = *input;
|
||||
char stopChar;
|
||||
|
@ -4,7 +4,7 @@
|
||||
#include <ctype.h>
|
||||
|
||||
#include "ArduinoJson/JsonBuffer.h"
|
||||
#include "ArduinoJson/Internals/EscapedString.h"
|
||||
#include "ArduinoJson/Internals/QuotedString.h"
|
||||
|
||||
using namespace ArduinoJson::Internals;
|
||||
|
||||
@ -176,6 +176,6 @@ JsonNode* JsonParser::parseNull()
|
||||
|
||||
JsonNode* JsonParser::parseString()
|
||||
{
|
||||
const char* s = EscapedString::extractFrom(_ptr, &_ptr);
|
||||
const char* s = QuotedString::extractFrom(_ptr, &_ptr);
|
||||
return _buffer->createStringNode(s);
|
||||
}
|
||||
|
@ -1,11 +1,11 @@
|
||||
#include "ArduinoJson/Internals/JsonWriter.h"
|
||||
#include "ArduinoJson/Internals/EscapedString.h"
|
||||
#include "ArduinoJson/Internals/QuotedString.h"
|
||||
|
||||
using namespace ArduinoJson::Internals;
|
||||
|
||||
void JsonWriter::writeString(char const* value)
|
||||
{
|
||||
_length += EscapedString::printTo(value, _sink);
|
||||
_length += QuotedString::printTo(value, _sink);
|
||||
}
|
||||
|
||||
void JsonWriter::writeInteger(long value)
|
||||
|
@ -4,7 +4,6 @@
|
||||
|
||||
#include "ArduinoJson/JsonBuffer.h"
|
||||
#include "ArduinoJson/JsonValue.h"
|
||||
#include "ArduinoJson/Internals/EscapedString.h"
|
||||
#include "ArduinoJson/Internals/JsonNode.h"
|
||||
#include "ArduinoJson/Internals/StringBuilder.h"
|
||||
|
||||
|
Reference in New Issue
Block a user