/ Return the number of values in this object. */ /
| 1118 | /* Return the number of values in this object. */ |
| 1119 | /***********************************************************************/ |
| 1120 | int 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. */ |
no test coverage detected