A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://arduinojson.org/v6/api/config/enable_std_stream/ below:

ARDUINOJSON_ENABLE_STD_STREAM | ArduinoJson 6

The macro ARDUINOJSON_ENABLE_STD_STREAM controls the support of std::istream and std::ostream in the library.

Default value

On C++17-capable compilers, ArduinoJson can detect the presence of specific header files. In that case, the default value of ARDUINOJSON_ENABLE_STD_STREAM is:

On older compilers, ArduinoJson tries to guess whether std::istream/std::ostream are available or not, based on the presence of the ARDUINO macro. In that case, the default value of ARDUINOJSON_ENABLE_STD_STREAM is:

In other words, ArduinoJson assumes that std::istream/std::ostream are available as soon as you work outside of Arduino.

Examples

If you need to force the support of std::istream/std::ostream, add the following line at the top of your program:

#define ARDUINOJSON_ENABLE_STD_STREAM 1
#include <ArduinoJson.h>

If for some reason, you need to disable the support for std::istream/std::ostream, add the following line at the top of your program:

#define ARDUINOJSON_ENABLE_STD_STREAM 0
#include <ArduinoJson.h>

Only 0 and 1 are valid. Any other value (like false or true) will produce a compilation error.

See also
  1. Home
  2. Version 6
  3. API
  4. Configuration
  5. ARDUINOJSON_ENABLE_STD_STREAM

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4