Autonomy Software C++ 24.5.1
Welcome to the Autonomy Software repository of the Mars Rover Design Team (MRDT) at Missouri University of Science and Technology (Missouri S&T)! API reference contains the source code and other resources for the development of the autonomy software for our Mars rover. The Autonomy Software project aims to compete in the University Rover Challenge (URC) by demonstrating advanced autonomous capabilities and robust navigation algorithms.
Loading...
Searching...
No Matches
duckdb_yyjson::yyjson_mut_obj_iter Struct Reference
Collaboration diagram for duckdb_yyjson::yyjson_mut_obj_iter:

Public Attributes

size_t idx
size_t max
yyjson_mut_val * cur
yyjson_mut_val * pre
yyjson_mut_val * obj

Detailed Description

A mutable JSON object iterator.

Warning
You should not modify the object while iterating over it, but you can use yyjson_mut_obj_iter_remove() to remove current value.
Example
yyjson_mut_val *key, *val;
while ((key = yyjson_mut_obj_iter_next(&iter))) {
your_func(key, val);
if (your_val_is_unused(key, val)) {
}
}
yyjson_api_inline yyjson_mut_val * yyjson_mut_obj_iter_remove(yyjson_mut_obj_iter *iter)
Definition duckdb.cpp:43559
yyjson_api_inline yyjson_mut_obj_iter yyjson_mut_obj_iter_with(yyjson_mut_val *obj)
Definition duckdb.cpp:43531
yyjson_api_inline yyjson_mut_val * yyjson_mut_obj_iter_next(yyjson_mut_obj_iter *iter)
Definition duckdb.cpp:43542
yyjson_api_inline yyjson_mut_val * yyjson_mut_obj_iter_get_val(yyjson_mut_val *key)
Definition duckdb.cpp:43554
Definition duckdb.cpp:40339
yyjson_mut_val * obj
Definition duckdb.cpp:40344
Definition duckdb.cpp:42310

If the ordering of the keys is known at compile-time, you can use this method to speed up value lookups:

// {"k1":1, "k2": 3, "k3": 3}
yyjson_mut_val *key, *val;
yyjson_api_inline yyjson_mut_val * yyjson_mut_obj_iter_get(yyjson_mut_obj_iter *iter, const char *key)
Definition duckdb.cpp:43576
See also
yyjson_mut_obj_iter_get() and yyjson_mut_obj_iter_getn()

Member Data Documentation

◆ idx

size_t duckdb_yyjson::yyjson_mut_obj_iter::idx

next key's index

◆ max

size_t duckdb_yyjson::yyjson_mut_obj_iter::max

maximum key index (obj.size)

◆ cur

yyjson_mut_val* duckdb_yyjson::yyjson_mut_obj_iter::cur

current key

◆ pre

yyjson_mut_val* duckdb_yyjson::yyjson_mut_obj_iter::pre

previous key

◆ obj

yyjson_mut_val* duckdb_yyjson::yyjson_mut_obj_iter::obj

the object being iterated


The documentation for this struct was generated from the following file: