* PgbsonDecomposeFields takes a bson object and splits its fields into * individual (single-element) bson objects. * * .e.g.: {"a": [1,2,3], "b": {"x": 1, "y": 1}} -> * List[{"a": [1,2,3]}, {"b": {"x": 1, "y": 1}}] */
| 125 | * List[{"a": [1,2,3]}, {"b": {"x": 1, "y": 1}}] |
| 126 | */ |
| 127 | List * |
| 128 | PgbsonDecomposeFields(const pgbson *document) |
| 129 | { |
| 130 | bson_value_t docValue = ConvertPgbsonToBsonValue(document); |
| 131 | return BsonValueDocumentDecomposeFields(&docValue); |
| 132 | } |
| 133 | |
| 134 | |
| 135 | /* |
nothing calls this directly
no test coverage detected