14 #ifndef __JSONV_COERCE_HPP_INCLUDED__ 15 #define __JSONV_COERCE_HPP_INCLUDED__ JSONV_PUBLIC bool can_coerce(const value &from, const kind &to)
Can the given value be converted from a kind to another?
JSONV_PUBLIC std::int64_t coerce_integer(const value &from)
Coerce from into an integer.
JSONV_PUBLIC std::string coerce_string(const value &from)
Coerce from into an std::string.
JSONV_PUBLIC std::vector< value > coerce_array(const value &from)
Coerce from into a vector.
JSONV_PUBLIC value coerce_merge(value a, value b)
Combines a and b in any way possible.
Copyright (c) 2014-2019 by Travis Gockel.
kind
Describes the kind of data a value holds.
JSONV_PUBLIC std::map< std::string, value > coerce_object(const value &from)
Coerce from into a map.
JSONV_PUBLIC bool coerce_boolean(const value &from)
Coerce from into a bool.
JSONV_PUBLIC double coerce_decimal(const value &from)
Coerce from into a double.
#define JSONV_PUBLIC
This function or class is part of the public API for JsonVoorhees.
JSONV_PUBLIC std::nullptr_t coerce_null(const value &from)
Coerce from into a null.
Copyright (c) 2012-2018 by Travis Gockel.