34#ifndef qcbor_number_encode_h
35#define qcbor_number_encode_h
39#include "qcbor/qcbor_private.h"
131#define QCBOR_HEAD_BUFFER_SIZE (sizeof(uint64_t) + 2)
262#ifndef USEFULBUF_DISABLE_ALL_FLOAT
523 uint8_t uTagRequirement,
531 uint8_t uTagRequirement,
539 uint8_t uTagRequirement,
568 uint8_t uTagRequirement,
576 uint8_t uTagRequirement,
584 uint8_t uTagRequirement,
622 uint8_t uTagRequirement,
630 uint8_t uTagRequirement,
638 uint8_t uTagRequirement,
644#ifndef QCBOR_DISABLE_EXP_AND_MANTISSA
687 uint8_t uTagRequirement,
689 int64_t nBase10Exponent);
695 uint8_t uTagRequirement,
697 int64_t nBase10Exponent);
703 uint8_t uTagRequirement,
705 int64_t nBase10Exponent);
737 uint8_t uTagRequirement,
740 int64_t nBase10Exponent);
746 uint8_t uTagRequirement,
749 int64_t nBase10Exponent);
755 uint8_t uTagRequirement,
758 int64_t nBase10Exponent);
773 uint8_t uTagRequirement,
776 int64_t nBase10Exponent);
782 uint8_t uTagRequirement,
785 int64_t nBase10Exponent);
791 uint8_t uTagRequirement,
794 int64_t nBase10Exponent);
837 uint8_t uTagRequirement,
839 int64_t nBase2Exponent);
845 uint8_t uTagRequirement,
847 int64_t nBase2Exponent);
853 uint8_t uTagRequirement,
855 int64_t nBase2Exponent);
881 uint8_t uTagRequirement,
884 int64_t nBase2Exponent);
890 uint8_t uTagRequirement,
893 int64_t nBase2Exponent);
899 uint8_t uTagRequirement,
902 int64_t nBase2Exponent);
920 uint8_t uTagRequirement,
923 int64_t nBase2Exponent);
930 uint8_t uTagRequirement,
933 int64_t nBase2Exponent);
939 uint8_t uTagRequirement,
942 int64_t nBase2Exponent);
963#ifndef USEFULBUF_DISABLE_ALL_FLOAT
985 uint8_t uTagRequirement,
992 uint8_t uTagRequirement,
999 uint8_t uTagRequirement,
1011 const char *szLabel,
1024 uint8_t uTagRequirement,
1030 const char *szLabel,
1031 uint8_t uTagRequirement,
1038 uint8_t uTagRequirement,
1049 const char *szLabel,
1059#ifndef QCBOR_CONFIG_DISABLE_EXP_AND_MANTISSA
1064 int64_t nBase10Exponent);
1069 const char *szLabel,
1071 int64_t nBase10Exponent);
1078 int64_t nBase10Exponent);
1083 uint8_t uTagRequirement,
1086 int64_t nBase10Exponent);
1091 const char *szLabel,
1092 uint8_t uTagRequirement,
1095 int64_t nBase10Exponent);
1101 uint8_t uTagRequirement,
1104 int64_t nBase10Exponent);
1111 int64_t nBase10Exponent);
1116 const char *szLabel,
1119 int64_t nBase10Exponent);
1127 int64_t nBase10Exponent);
1133 int64_t nBase2Exponent);
1138 const char *szLabel,
1140 int64_t nBase2Exponent);
1147 int64_t nBase2Exponent);
1152 uint8_t uTagRequirement,
1155 int64_t nBase2Exponent);
1160 const char *szLabel,
1161 uint8_t uTagRequirement,
1164 int64_t nBase2Exponent);
1170 uint8_t uTagRequirement,
1173 int64_t nBase2Exponent);
1180 int64_t nBase2Exponent);
1185 const char *szLabel,
1188 int64_t nBase2Exponent);
1196 int64_t nBase2Exponent);
1228 const uint8_t uTagRequirement,
1230 const bool bNegative,
1236 const int uTagRequirement,
1237 const uint64_t uTagNumber,
1238 const int64_t nExponent,
1239 const int64_t nMantissa);
1245 const int uTagRequirement,
1246 const uint64_t uTagNumber,
1247 const int64_t nExponent,
1249 const bool bBigNumIsNegative);
1255 const int uTagRequirement,
1256 const uint64_t uTagNumber,
1257 const int64_t nExponent,
1259 const bool bBigNumIsNegative);
1267 const char *szLabel,
1282 const int64_t nLabel,
1293 QCBOREncode_Private_AppendCBORHead(pMe, CBOR_MAJOR_TYPE_POSITIVE_INT, uValue, 0);
1299 const char *szLabel,
1300 const uint64_t uNum)
1314 const int64_t nLabel,
1315 const uint64_t uNum)
1325 QCBOREncode_Private_AppendCBORHead(pMe, CBOR_MAJOR_TYPE_NEGATIVE_INT, uValue, 0);
1346#ifndef USEFULBUF_DISABLE_ALL_FLOAT
1355 QCBOREncode_Private_AddType7(pMe,
1363#ifndef QCBOR_DISABLE_ENCODE_USAGE_GUARDS
1370 QCBOREncode_Private_AddDoubleRaw(pMe, dNum);
1376#ifndef QCBOR_DISABLE_PREFERRED_FLOAT
1377 QCBOREncode_Private_AddPreferredDouble(pMe, dNum);
1379 QCBOREncode_Private_AddDoubleRaw(pMe, dNum);
1385 const char *szLabel,
1400 const int64_t nLabel,
1414 QCBOREncode_Private_AddType7(pMe,
1422#ifndef QCBOR_DISABLE_ENCODE_USAGE_GUARDS
1429 QCBOREncode_Private_AddFloatRaw(pMe, fNum);
1435#ifndef QCBOR_DISABLE_PREFERRED_FLOAT
1436 QCBOREncode_Private_AddPreferredFloat(pMe, fNum);
1438 QCBOREncode_Private_AddFloatRaw(pMe, fNum);
1444 const char *szLabel,
1459 const int64_t nLabel,
1468 const char *szLabel,
1483 const int64_t nLabel,
1492 const char *szLabel,
1507 const int64_t nLabel,
1520 const uint8_t uTagRequirement,
1521 const bool bNegative,
1524 QCBOREncode_Private_AddTBigNumberMain(pMe, uTagRequirement,
true, bNegative, BigNumber);
1530 const char *szLabel,
1531 uint8_t uTagRequirement,
1542 uint8_t uTagRequirement,
1552 const uint8_t uTagRequirement,
1553 const bool bNegative,
1556 QCBOREncode_Private_AddTBigNumberMain(pMe, uTagRequirement,
false, bNegative, BigNumber);
1561 const char *szLabel,
1562 uint8_t uTagRequirement,
1573 uint8_t uTagRequirement,
1591 const uint8_t uTagRequirement,
1602 const uint8_t uTagRequirement,
1606#ifndef QCBOR_DISABLE_ENCODE_USAGE_GUARDS
1613 QCBOREncode_Private_BigNumberTag(pMe, uTagRequirement, bNegative);
1619 const char *szLabel,
1620 const uint8_t uTagRequirement,
1632 const uint8_t uTagRequirement,
1644#ifndef QCBOR_DISABLE_EXP_AND_MANTISSA
1648 const uint8_t uTagRequirement,
1649 const int64_t nMantissa,
1650 const int64_t nBase10Exponent)
1652 QCBOREncode_Private_AddTExpIntMantissa(pMe,
1661 const char *szLabel,
1662 const uint8_t uTagRequirement,
1663 const int64_t nMantissa,
1664 const int64_t nBase10Exponent)
1675 const int64_t nLabel,
1676 const uint8_t uTagRequirement,
1677 const int64_t nMantissa,
1678 const int64_t nBase10Exponent)
1691 const uint8_t uTagRequirement,
1693 const bool bIsNegative,
1694 const int64_t nBase10Exponent)
1696 QCBOREncode_Private_AddTExpBigMantissa(pMe,
1707 const char *szLabel,
1708 const uint8_t uTagRequirement,
1710 const bool bIsNegative,
1711 const int64_t nBase10Exponent)
1723 const int64_t nLabel,
1724 const uint8_t uTagRequirement,
1726 const bool bIsNegative,
1727 const int64_t nBase10Exponent)
1739 const uint8_t uTagRequirement,
1741 const bool bIsNegative,
1742 const int64_t nBase10Exponent)
1744 QCBOREncode_Private_AddTExpBigMantissaRaw(pMe,
1755 const char *szLabel,
1756 const uint8_t uTagRequirement,
1758 const bool bIsNegative,
1759 const int64_t nBase10Exponent)
1771 const int64_t nLabel,
1772 const uint8_t uTagRequirement,
1774 const bool bIsNegative,
1775 const int64_t nBase10Exponent)
1788 const uint8_t uTagRequirement,
1789 const int64_t nMantissa,
1790 const int64_t nBase2Exponent)
1792 QCBOREncode_Private_AddTExpIntMantissa(pMe,
1801 const char *szLabel,
1802 const uint8_t uTagRequirement,
1803 const int64_t nMantissa,
1804 const int64_t nBase2Exponent)
1812 const int64_t nLabel,
1813 const uint8_t uTagRequirement,
1814 const int64_t nMantissa,
1815 const int64_t nBase2Exponent)
1824 const uint8_t uTagRequirement,
1826 const bool bIsNegative,
1827 const int64_t nBase2Exponent)
1829 QCBOREncode_Private_AddTExpBigMantissa(pMe,
1839 const char *szLabel,
1840 const uint8_t uTagRequirement,
1842 const bool bIsNegative,
1843 const int64_t nBase2Exponent)
1855 const int64_t nLabel,
1856 const uint8_t uTagRequirement,
1858 const bool bIsNegative,
1859 const int64_t nBase2Exponent)
1872 const uint8_t uTagRequirement,
1874 const bool bIsNegative,
1875 const int64_t nBase2Exponent)
1877 QCBOREncode_Private_AddTExpBigMantissaRaw(pMe,
1887 const char *szLabel,
1888 const uint8_t uTagRequirement,
1890 const bool bIsNegative,
1891 const int64_t nBase2Exponent)
1903 const int64_t nLabel,
1904 const uint8_t uTagRequirement,
1906 const bool bIsNegative,
1907 const int64_t nBase2Exponent)
1935 const uint8_t uTagRequirement,
1943 const char *szLabel,
1944 const uint8_t uTagRequirement,
1952 const int64_t nLabel,
1953 const uint8_t uTagRequirement,
1967 const char *szLabel,
1975 const int64_t nLabel,
1983 const uint8_t uTagRequirement,
1991 const char *szLabel,
1992 const uint8_t uTagRequirement,
2004 const int64_t nLabel,
2005 const uint8_t uTagRequirement,
2023 const char *szLabel,
2031 const int64_t nLabel,
2038#ifndef QCBOR_CONFIG_DISABLE_EXP_AND_MANTISSA
2041 const int64_t nMantissa,
2042 const int64_t nBase10Exponent)
2052 const char *szLabel,
2053 const int64_t nMantissa,
2054 const int64_t nBase10Exponent)
2065 const int64_t nLabel,
2066 const int64_t nMantissa,
2067 const int64_t nBase10Exponent)
2079 const uint8_t uTagRequirement,
2081 const bool bIsNegative,
2082 const int64_t nBase10Exponent)
2094 const char *szLabel,
2095 const uint8_t uTagRequirement,
2097 const bool bIsNegative,
2098 const int64_t nBase10Exponent)
2110 const int64_t nLabel,
2111 const uint8_t uTagRequirement,
2113 const bool bIsNegative,
2114 const int64_t nBase10Exponent)
2127 const bool bIsNegative,
2128 const int64_t nBase10Exponent)
2139 const char *szLabel,
2141 const bool bIsNegative,
2142 const int64_t nBase10Exponent)
2154 const int64_t nLabel,
2156 const bool bIsNegative,
2157 const int64_t nBase10Exponent)
2170 const int64_t nMantissa,
2171 const int64_t nBase2Exponent)
2181 const char *szLabel,
2182 const int64_t nMantissa,
2183 const int64_t nBase2Exponent)
2194 const int64_t nLabel,
2195 const int64_t nMantissa,
2196 const int64_t nBase2Exponent)
2207 const uint8_t uTagRequirement,
2209 const bool bIsNegative,
2210 const int64_t nBase2Exponent)
2221 const char *szLabel,
2222 const uint8_t uTagRequirement,
2224 const bool bIsNegative,
2225 const int64_t nBase2Exponent)
2237 const int64_t nLabel,
2238 const uint8_t uTagRequirement,
2240 const bool bIsNegative,
2241 const int64_t nBase2Exponent)
2255 const bool bIsNegative,
2256 const int64_t nBase2Exponent)
2267 const char *szLabel,
2269 const bool bIsNegative,
2270 const int64_t nBase2Exponent)
2282 const int64_t nLabel,
2284 const bool bIsNegative,
2285 const int64_t nBase2Exponent)
static uint32_t UsefulBufUtil_CopyFloatToUint32(float f)
Copy a float to a uint32_t.
Definition UsefulBuf.h:2099
static uint64_t UsefulBufUtil_CopyDoubleToUint64(double d)
Copy a double to a uint64_t.
Definition UsefulBuf.h:2106
#define CBOR_TAG_POS_BIGNUM
Definition qcbor_common.h:129
#define CBOR_TAG_BIGFLOAT
Definition qcbor_common.h:140
#define CBOR_TAG_DECIMAL_FRACTION
Definition qcbor_common.h:136
@ QCBOR_ERR_NOT_PREFERRED
Definition qcbor_common.h:554
#define CBOR_TAG_NEG_BIGNUM
Definition qcbor_common.h:132
struct _QCBOREncodeContext QCBOREncodeContext
Definition qcbor_main_encode.h:311
@ QCBOR_ENCODE_CONFIG_DISALLOW_NON_PREFERRED_NUMBERS
Definition qcbor_main_encode.h:198
@ QCBOR_ENCODE_CONFIG_ONLY_PREFERRED_BIG_NUMBERS
Definition qcbor_main_encode.h:212
static void QCBOREncode_AddSZString(QCBOREncodeContext *pCtx, const char *szString)
Add a UTF-8 text string to the encoded output.
Definition qcbor_main_encode.h:1508
static void QCBOREncode_AddTBigNumberRawToMapN(QCBOREncodeContext *pCtx, int64_t nLabel, uint8_t uTagRequirement, bool bNegative, UsefulBufC BigNumber)
Definition qcbor_number_encode.h:1630
static void QCBOREncode_AddTPositiveBignumToMapSZ(QCBOREncodeContext *pCtx, const char *szLabel, uint8_t uTagRequirement, UsefulBufC BigNumber)
Definition qcbor_number_encode.h:1942
static void QCBOREncode_AddUInt64ToMapSZ(QCBOREncodeContext *pCtx, const char *szLabel, uint64_t uNum)
Definition qcbor_number_encode.h:1298
static void QCBOREncode_AddFloatNoPreferredToMapSZ(QCBOREncodeContext *pCtx, const char *szLabel, float fNum)
Definition qcbor_number_encode.h:1491
static void QCBOREncode_AddDoubleNoPreferred(QCBOREncodeContext *pCtx, double dNum)
Add a double-precision floating-point number without preferred encoding.
Definition qcbor_number_encode.h:1361
static void QCBOREncode_AddTDecimalFractionBigMantissaRaw(QCBOREncodeContext *pCtx, uint8_t uTagRequirement, UsefulBufC Mantissa, bool bIsNegative, int64_t nBase10Exponent)
Add a decimal fraction with a raw big number mantissa.
Definition qcbor_number_encode.h:1738
static void QCBOREncode_AddTBigNumberNoPreferredToMapN(QCBOREncodeContext *pCtx, int64_t nLabel, uint8_t uTagRequirement, bool bNegative, UsefulBufC BigNumber)
Definition qcbor_number_encode.h:1571
static void QCBOREncode_AddDecimalFractionBigNumToMapN(QCBOREncodeContext *pCtx, int64_t nLabel, UsefulBufC Mantissa, bool bIsNegative, int64_t nBase10Exponent)
Definition qcbor_number_encode.h:2153
static void QCBOREncode_AddFloatToMap(QCBOREncodeContext *pCtx, const char *szLabel, float fNum)
Definition qcbor_number_encode.h:1452
static void QCBOREncode_AddFloatToMapSZ(QCBOREncodeContext *pCtx, const char *szLabel, float fNum)
Definition qcbor_number_encode.h:1443
static void QCBOREncode_AddTBigFloatBigNum(QCBOREncodeContext *pCtx, uint8_t uTagRequirement, UsefulBufC Mantissa, bool bIsNegative, int64_t nBase2Exponent)
Definition qcbor_number_encode.h:2206
static void QCBOREncode_AddTNegativeBignum(QCBOREncodeContext *pCtx, uint8_t uTagRequirement, UsefulBufC BigNumber)
Definition qcbor_number_encode.h:1982
static void QCBOREncode_AddTDecimalFractionBigMantissa(QCBOREncodeContext *pCtx, uint8_t uTagRequirement, UsefulBufC Mantissa, bool bIsNegative, int64_t nBase10Exponent)
Add a decimal fraction with a big number mantissa..
Definition qcbor_number_encode.h:1690
static void QCBOREncode_AddTDecimalFractionBigNumToMapN(QCBOREncodeContext *pCtx, int64_t nLabel, uint8_t uTagRequirement, UsefulBufC Mantissa, bool bIsNegative, int64_t nBase10Exponent)
Definition qcbor_number_encode.h:2109
static void QCBOREncode_AddFloatToMapN(QCBOREncodeContext *pCtx, int64_t nLabel, float dNum)
Definition qcbor_number_encode.h:1458
static void QCBOREncode_AddTDecimalFractionBigNum(QCBOREncodeContext *pCtx, uint8_t uTagRequirement, UsefulBufC Mantissa, bool bIsNegative, int64_t nBase10Exponent)
Definition qcbor_number_encode.h:2078
static void QCBOREncode_AddTBigNumberToMapN(QCBOREncodeContext *pCtx, int64_t nLabel, uint8_t uTagRequirement, bool bNegative, UsefulBufC BigNumber)
Definition qcbor_number_encode.h:1540
static void QCBOREncode_AddNegativeBignumToMapN(QCBOREncodeContext *pCtx, int64_t nLabel, UsefulBufC BigNumber)
Definition qcbor_number_encode.h:2030
static void QCBOREncode_AddTNegativeBignumToMapSZ(QCBOREncodeContext *pCtx, const char *szLabel, uint8_t uTagRequirement, UsefulBufC BigNumber)
Definition qcbor_number_encode.h:1990
static void QCBOREncode_AddNegativeUInt64ToMapN(QCBOREncodeContext *pCtx, int64_t nLabel, uint64_t uNum)
Definition qcbor_number_encode.h:1336
static void QCBOREncode_AddBytesToMapN(QCBOREncodeContext *pCtx, int64_t nLabel, UsefulBufC Bytes)
static void QCBOREncode_AddUInt64ToMap(QCBOREncodeContext *pCtx, const char *szLabel, uint64_t uNum)
Definition qcbor_number_encode.h:1307
static void QCBOREncode_AddDecimalFraction(QCBOREncodeContext *pCtx, int64_t nMantissa, int64_t nBase10Exponent)
Definition qcbor_number_encode.h:2040
static void QCBOREncode_OpenBytesInMapSZ(QCBOREncodeContext *pCtx, const char *szLabel, UsefulBuf *pPlace)
static void QCBOREncode_AddBigFloatBigNum(QCBOREncodeContext *pCtx, UsefulBufC Mantissa, bool bIsNegative, int64_t nBase2Exponent)
Definition qcbor_number_encode.h:2253
static void QCBOREncode_AddTBigNumberToMapSZ(QCBOREncodeContext *pCtx, const char *szLabel, uint8_t uTagRequirement, bool bNegative, UsefulBufC BigNumber)
Definition qcbor_number_encode.h:1529
static void QCBOREncode_AddTBigFloatBigMantissaToMapN(QCBOREncodeContext *pCtx, int64_t nLabel, uint8_t uTagRequirement, UsefulBufC Mantissa, bool bIsNegative, int64_t nBase2Exponent)
Definition qcbor_number_encode.h:1854
static void QCBOREncode_AddTDecimalFractionBigMantissaToMapN(QCBOREncodeContext *pCtx, int64_t nLabel, uint8_t uTagRequirement, UsefulBufC Mantissa, bool bIsNegative, int64_t nBase10Exponent)
Definition qcbor_number_encode.h:1722
void QCBOREncode_CloseBytes(QCBOREncodeContext *pCtx, size_t uAmount)
Close out a byte string written directly to encoded output.
static void QCBOREncode_AddTPositiveBignum(QCBOREncodeContext *pCtx, uint8_t uTagRequirement, UsefulBufC BigNumber)
Definition qcbor_number_encode.h:1934
static void QCBOREncode_AddDoubleNoPreferredToMapN(QCBOREncodeContext *pCtx, int64_t nLabel, double dNum)
Definition qcbor_number_encode.h:1482
static void QCBOREncode_AddTDecimalFraction(QCBOREncodeContext *pCtx, uint8_t uTagRequirement, int64_t nMantissa, int64_t nBase10Exponent)
Add a decimal fraction.
Definition qcbor_number_encode.h:1647
static void QCBOREncode_AddTBigFloatBigMantissaRawToMapSZ(QCBOREncodeContext *pCtx, const char *szLabel, uint8_t uTagRequirement, UsefulBufC Mantissa, bool bIsNegative, int64_t nBase2Exponent)
Definition qcbor_number_encode.h:1886
static void QCBOREncode_AddDoubleToMapN(QCBOREncodeContext *pCtx, int64_t nLabel, double dNum)
Definition qcbor_number_encode.h:1399
static void QCBOREncode_AddFloatNoPreferredToMapN(QCBOREncodeContext *pCtx, int64_t nLabel, float fNum)
Definition qcbor_number_encode.h:1506
static void QCBOREncode_OpenBytesInMapN(QCBOREncodeContext *pCtx, int64_t nLabel, UsefulBuf *pPlace)
static void QCBOREncode_AddTBigNumberRawToMapSZ(QCBOREncodeContext *pCtx, const char *szLabel, uint8_t uTagRequirement, bool bNegative, UsefulBufC BigNumber)
Definition qcbor_number_encode.h:1618
static void QCBOREncode_AddNegativeUInt64ToMap(QCBOREncodeContext *pCtx, const char *szLabel, uint64_t uNum)
Definition qcbor_number_encode.h:1329
static void QCBOREncode_AddDoubleToMap(QCBOREncodeContext *pCtx, const char *szLabel, double dNum)
Definition qcbor_number_encode.h:1393
static void QCBOREncode_AddTBigFloat(QCBOREncodeContext *pCtx, uint8_t uTagRequirement, int64_t nMantissa, int64_t nBase2Exponent)
Add a big floating-point number to the encoded output.
Definition qcbor_number_encode.h:1787
static void QCBOREncode_AddDecimalFractionToMapN(QCBOREncodeContext *pCtx, int64_t nLabel, int64_t nMantissa, int64_t nBase10Exponent)
Definition qcbor_number_encode.h:2064
static void QCBOREncode_AddDoubleNoPreferredToMapSZ(QCBOREncodeContext *pCtx, const char *szLabel, double dNum)
Definition qcbor_number_encode.h:1467
static void QCBOREncode_AddFloatNoPreferred(QCBOREncodeContext *pCtx, float fNum)
Add a single-precision floating-point number without preferred encoding.
Definition qcbor_number_encode.h:1420
static void QCBOREncode_AddBigFloatBigNumToMapN(QCBOREncodeContext *pCtx, int64_t nLabel, UsefulBufC Mantissa, bool bIsNegative, int64_t nBase2Exponent)
Definition qcbor_number_encode.h:2281
static void QCBOREncode_AddTDecimalFractionBigMantissaRawToMapSZ(QCBOREncodeContext *pCtx, const char *szLabel, uint8_t uTagRequirement, UsefulBufC Mantissa, bool bIsNegative, int64_t nBase10Exponent)
Definition qcbor_number_encode.h:1754
static void QCBOREncode_AddNegativeBignum(QCBOREncodeContext *pCtx, UsefulBufC BigNumber)
Definition qcbor_number_encode.h:2016
static void QCBOREncode_AddTDecimalFractionBigMantissaToMapSZ(QCBOREncodeContext *pCtx, const char *szLabel, uint8_t uTagRequirement, UsefulBufC Mantissa, bool bIsNegative, int64_t nBase10Exponent)
Definition qcbor_number_encode.h:1706
void QCBOREncode_AddInt64(QCBOREncodeContext *pCtx, int64_t nNum)
Add a signed 64-bit integer to the encoded output.
static void QCBOREncode_AddTDecimalFractionToMapSZ(QCBOREncodeContext *pCtx, const char *szLabel, uint8_t uTagRequirement, int64_t nMantissa, int64_t nBase10Exponent)
Definition qcbor_number_encode.h:1660
static void QCBOREncode_AddUInt64ToMapN(QCBOREncodeContext *pCtx, int64_t nLabel, uint64_t uNum)
Definition qcbor_number_encode.h:1313
static void QCBOREncode_AddInt64ToMapSZ(QCBOREncodeContext *pCtx, const char *szLabel, int64_t nNum)
Definition qcbor_number_encode.h:1266
static void QCBOREncode_AddDoubleNoPreferredToMap(QCBOREncodeContext *pCtx, const char *szLabel, double dNum)
Definition qcbor_number_encode.h:1476
static void QCBOREncode_AddBytes(QCBOREncodeContext *pCtx, UsefulBufC Bytes)
Add a byte string to the encoded output.
static void QCBOREncode_AddDecimalFractionBigNumToMapSZ(QCBOREncodeContext *pCtx, const char *szLabel, UsefulBufC Mantissa, bool bIsNegative, int64_t nBase10Exponent)
Definition qcbor_number_encode.h:2138
static void QCBOREncode_AddTNegativeBignumToMapN(QCBOREncodeContext *pCtx, int64_t nLabel, uint8_t uTagRequirement, UsefulBufC BigNumber)
Definition qcbor_number_encode.h:2003
static void QCBOREncode_AddTBigFloatToMapN(QCBOREncodeContext *pCtx, int64_t nLabel, uint8_t uTagRequirement, int64_t nMantissa, int64_t nBase2Exponent)
Definition qcbor_number_encode.h:1811
static void QCBOREncode_AddTBigNumber(QCBOREncodeContext *pCtx, uint8_t uTagRequirement, bool bNegative, UsefulBufC BigNumber)
Add a big number to encoded output using preferred serialization.
Definition qcbor_number_encode.h:1519
static void QCBOREncode_AddTBigNumberNoPreferredToMapSZ(QCBOREncodeContext *pCtx, const char *szLabel, uint8_t uTagRequirement, bool bNegative, UsefulBufC BigNumber)
Definition qcbor_number_encode.h:1560
static void QCBOREncode_AddPositiveBignum(QCBOREncodeContext *pCtx, UsefulBufC BigNumber)
Definition qcbor_number_encode.h:1960
static void QCBOREncode_AddTBigFloatBigNumToMapSZ(QCBOREncodeContext *pCtx, const char *szLabel, uint8_t uTagRequirement, UsefulBufC Mantissa, bool bIsNegative, int64_t nBase2Exponent)
Definition qcbor_number_encode.h:2220
static void QCBOREncode_AddTBigFloatBigMantissaToMapSZ(QCBOREncodeContext *pCtx, const char *szLabel, uint8_t uTagRequirement, UsefulBufC Mantissa, bool bIsNegative, int64_t nBase2Exponent)
Definition qcbor_number_encode.h:1838
static void QCBOREncode_AddFloatNoPreferredToMap(QCBOREncodeContext *pCtx, const char *szLabel, float fNum)
Definition qcbor_number_encode.h:1500
static void QCBOREncode_AddDecimalFractionBigNum(QCBOREncodeContext *pCtx, UsefulBufC Mantissa, bool bIsNegative, int64_t nBase10Exponent)
Definition qcbor_number_encode.h:2125
static void QCBOREncode_AddTBigNumberNoPreferred(QCBOREncodeContext *pCtx, uint8_t uTagRequirement, bool bNegative, UsefulBufC BigNumber)
Add a big number to encoded output without preferred serialization.
Definition qcbor_number_encode.h:1551
static void QCBOREncode_AddTBigFloatToMapSZ(QCBOREncodeContext *pCtx, const char *szLabel, uint8_t uTagRequirement, int64_t nMantissa, int64_t nBase2Exponent)
Definition qcbor_number_encode.h:1800
static void QCBOREncode_AddFloat(QCBOREncodeContext *pCtx, float fNum)
Add a single-precision floating-point number to the encoded output.
Definition qcbor_number_encode.h:1433
static void QCBOREncode_AddInt64ToMap(QCBOREncodeContext *pCtx, const char *szLabel, int64_t nNum)
Definition qcbor_number_encode.h:1275
static void QCBOREncode_AddDouble(QCBOREncodeContext *pCtx, double dNum)
Add a double-precision floating-point number to the encoded output.
Definition qcbor_number_encode.h:1374
static void QCBOREncode_AddTPositiveBignumToMapN(QCBOREncodeContext *pCtx, int64_t nLabel, uint8_t uTagRequirement, UsefulBufC BigNumber)
Definition qcbor_number_encode.h:1951
static void QCBOREncode_AddTBigNumberRaw(QCBOREncodeContext *pCtx, uint8_t uTagRequirement, bool bNegative, UsefulBufC BigNumber)
Add a big number to encoded output with no processing.
Definition qcbor_number_encode.h:1601
void QCBOREncode_OpenBytes(QCBOREncodeContext *pCtx, UsefulBuf *pPlace)
Set up to write a byte string value directly to encoded output.
static void QCBOREncode_AddTBigFloatBigMantissaRawToMapN(QCBOREncodeContext *pCtx, int64_t nLabel, uint8_t uTagRequirement, UsefulBufC Mantissa, bool bIsNegative, int64_t nBase2Exponent)
Definition qcbor_number_encode.h:1902
static void QCBOREncode_AddBigFloat(QCBOREncodeContext *pCtx, int64_t nMantissa, int64_t nBase2Exponent)
Definition qcbor_number_encode.h:2169
static void QCBOREncode_AddBigFloatToMapN(QCBOREncodeContext *pCtx, int64_t nLabel, int64_t nMantissa, int64_t nBase2Exponent)
Definition qcbor_number_encode.h:2193
static void QCBOREncode_AddTDecimalFractionToMapN(QCBOREncodeContext *pCtx, int64_t nLabel, uint8_t uTagRequirement, int64_t nMantissa, int64_t nBase10Exponent)
Definition qcbor_number_encode.h:1674
static void QCBOREncode_AddBytesToMapSZ(QCBOREncodeContext *pCtx, const char *szLabel, UsefulBufC Bytes)
static void QCBOREncode_AddNegativeBignumToMap(QCBOREncodeContext *pCtx, const char *szLabel, UsefulBufC BigNumber)
Definition qcbor_number_encode.h:2022
static void QCBOREncode_AddUInt64(QCBOREncodeContext *pCtx, uint64_t uNum)
Add an unsigned 64-bit integer to the encoded output.
Definition qcbor_number_encode.h:1291
static void QCBOREncode_AddDoubleToMapSZ(QCBOREncodeContext *pCtx, const char *szLabel, double dNum)
Definition qcbor_number_encode.h:1384
static void QCBOREncode_AddDecimalFractionToMap(QCBOREncodeContext *pCtx, const char *szLabel, int64_t nMantissa, int64_t nBase10Exponent)
Definition qcbor_number_encode.h:2051
static void QCBOREncode_AddTBigFloatBigNumToMapN(QCBOREncodeContext *pCtx, int64_t nLabel, uint8_t uTagRequirement, UsefulBufC Mantissa, bool bIsNegative, int64_t nBase2Exponent)
Definition qcbor_number_encode.h:2236
static void QCBOREncode_AddTDecimalFractionBigNumToMapSZ(QCBOREncodeContext *pCtx, const char *szLabel, uint8_t uTagRequirement, UsefulBufC Mantissa, bool bIsNegative, int64_t nBase10Exponent)
Definition qcbor_number_encode.h:2093
static void QCBOREncode_AddBigFloatToMap(QCBOREncodeContext *pCtx, const char *szLabel, int64_t nMantissa, int64_t nBase2Exponent)
Definition qcbor_number_encode.h:2180
static void QCBOREncode_AddNegativeUInt64(QCBOREncodeContext *pCtx, uint64_t uNum)
Add a negative 64-bit integer to encoded output.
Definition qcbor_number_encode.h:1323
static void QCBOREncode_AddInt64ToMapN(QCBOREncodeContext *pCtx, int64_t nLabel, int64_t nNum)
Definition qcbor_number_encode.h:1281
static void QCBOREncode_AddTDecimalFractionBigMantissaRawToMapN(QCBOREncodeContext *pCtx, int64_t nLabel, uint8_t uTagRequirement, UsefulBufC Mantissa, bool bIsNegative, int64_t nBase10Exponent)
Definition qcbor_number_encode.h:1770
static void QCBOREncode_AddTBigFloatBigMantissa(QCBOREncodeContext *pCtx, uint8_t uTagRequirement, UsefulBufC Mantissa, bool bIsNegative, int64_t nBase2Exponent)
Add a big floating-point number with a big number mantissa.
Definition qcbor_number_encode.h:1823
static void QCBOREncode_AddPositiveBignumToMap(QCBOREncodeContext *pCtx, const char *szLabel, UsefulBufC BigNumber)
Definition qcbor_number_encode.h:1966
static void QCBOREncode_AddBigFloatBigNumToMap(QCBOREncodeContext *pCtx, const char *szLabel, UsefulBufC Mantissa, bool bIsNegative, int64_t nBase2Exponent)
Definition qcbor_number_encode.h:2266
static void QCBOREncode_AddTBigFloatBigMantissaRaw(QCBOREncodeContext *pCtx, uint8_t uTagRequirement, UsefulBufC Mantissa, bool bIsNegative, int64_t nBase2Exponent)
Add a big floating-point number with a big number mantissa.
Definition qcbor_number_encode.h:1871
static void QCBOREncode_AddPositiveBignumToMapN(QCBOREncodeContext *pCtx, int64_t nLabel, UsefulBufC BigNumber)
Definition qcbor_number_encode.h:1974
@ QCBOR_ENCODE_AS_TAG
Definition qcbor_tag_encode.h:121
static void QCBOREncode_AddTagNumber(QCBOREncodeContext *pCtx, uint64_t uTagNumber)
Add a tag number.
Definition qcbor_tag_encode.h:709
Definition UsefulBuf.h:280
Definition UsefulBuf.h:291