MCPcopy Create free account
hub / github.com/MariaDB/server / GetArraySize

Method GetArraySize

storage/connect/bson.cpp:1120–1131  ·  view source on GitHub ↗

/ Return the number of values in this object. */ /

Source from the content-addressed store, hash-verified

1118/* Return the number of values in this object. */
1119/***********************************************************************/
1120int BJSON::GetArraySize(PBVAL bap, bool b)
1121{
1122 CheckType(bap, TYPE_JAR);
1123 int n = 0;
1124
1125 for (PBVAL bvp = GetArray(bap); bvp; bvp = GetNext(bvp))
1126 // If b, return only non null values
1127 if (!b || bvp->Type != TYPE_NULL)
1128 n++;
1129
1130 return n;
1131} // end of GetArraySize
1132
1133/***********************************************************************/
1134/* Get the Nth value of an Array. */

Callers 3

bson_delete_itemFunction · 0.80
bbin_delete_itemFunction · 0.80
FindMethod · 0.80

Calls 1

GetNextFunction · 0.70

Tested by

no test coverage detected