Renamed StdStringAdapter to StlStringAdapter (internal use only)

This commit is contained in:
Benoit Blanchon
2020-10-01 10:01:33 +02:00
parent 8385d5fa3a
commit f3f44d7812
3 changed files with 8 additions and 8 deletions

View File

@ -13,9 +13,9 @@
namespace ARDUINOJSON_NAMESPACE {
template <typename TString>
class StlStringAdapter {
class StdStringAdapter {
public:
StlStringAdapter(const TString& str) : _str(&str) {}
StdStringAdapter(const TString& str) : _str(&str) {}
void copyTo(char* p, size_t n) const {
memcpy(p, _str->c_str(), n);
@ -56,9 +56,9 @@ struct IsString<std::basic_string<char, TCharTraits, TAllocator> > : true_type {
};
template <typename TCharTraits, typename TAllocator>
inline StlStringAdapter<std::basic_string<char, TCharTraits, TAllocator> >
inline StdStringAdapter<std::basic_string<char, TCharTraits, TAllocator> >
adaptString(const std::basic_string<char, TCharTraits, TAllocator>& str) {
return StlStringAdapter<std::basic_string<char, TCharTraits, TAllocator> >(
return StdStringAdapter<std::basic_string<char, TCharTraits, TAllocator> >(
str);
}

View File

@ -9,7 +9,7 @@
#include <ArduinoJson/Strings/SizedRamStringAdapter.hpp>
#if ARDUINOJSON_ENABLE_STD_STRING
#include <ArduinoJson/Strings/StlStringAdapter.hpp>
#include <ArduinoJson/Strings/StdStringAdapter.hpp>
#endif
#if ARDUINOJSON_ENABLE_ARDUINO_STRING