Minh Nguyen / ArduinoJson
Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers conditional.hpp Source File

conditional.hpp

00001 // ArduinoJson - arduinojson.org
00002 // Copyright Benoit Blanchon 2014-2021
00003 // MIT License
00004 
00005 #pragma once
00006 
00007 #include <ArduinoJson/Namespace.hpp>
00008 
00009 namespace ARDUINOJSON_NAMESPACE {
00010 
00011 template <bool Condition, class TrueType, class FalseType>
00012 struct conditional {
00013   typedef TrueType type;
00014 };
00015 
00016 template <class TrueType, class FalseType>
00017 struct conditional<false, TrueType, FalseType> {
00018   typedef FalseType type;
00019 };
00020 }  // namespace ARDUINOJSON_NAMESPACE