FastLED 3.9.15
Loading...
Searching...
No Matches

◆ as_int() [3/4]

fl::optional< i64 > fl::json_value::as_int ( )
inline

Definition at line 935 of file types.h.

935 {
936 // Check if we have a valid value first
937 if (data.empty()) {
938 return fl::nullopt;
939 }
940
941 int_conversion_visitor<i64> visitor;
942 data.visit(visitor);
943 return visitor.result;
944 }
constexpr nullopt_t nullopt
Definition optional.h:13
variant_t data
Definition types.h:700

References data, FL_NOEXCEPT, fl::nullopt, and fl::int_conversion_visitor< IntType >::result.

Referenced by fl::json_value::array_iterator< T >::get_value().

+ Here is the caller graph for this function: