bson_decimal128_from_string(3)

bson_decimal128_from_string3

Usage

bool
bson_decimal128_from_string (const char *string, bson_decimal128_t *dec);

Parameters

•

string: A string containing ASCII encoded Decimal128.

•

dec: A bson_decimal128_t.

Overview

Parses the string containing ascii encoded Decimal128 and initialize the bytes in dec. See the Decimal128 specification for the exact string format.

Returns

Returns true if valid Decimal128 string was provided, otherwise false and dec will be set to NaN.

Examples

bson_decimal128_t dec;
bson_decimal128_from_string ("1.00", &dec);

Releases

4 releases since Debian 10 (Buster); the text changed 3 times.

  1. 10
  2. 11
  3. 12
  4. 13

Author

MongoDB, Inc

From libbson-doc 1.30.4-1+deb13u3 in Debian 13 (Trixie). Parsed by carta from the page's man source.