18 for (
int existing : ids_) {
19 if (existing ==
id)
return;
28 int getCount()
const {
return static_cast<int>(ids_.size()); }
33 if (index < 0 || index >=
getCount())
return -1;
34 return ids_[
static_cast<size_t>(
index)];
37 const std::vector<int> &
ids()
const {
return ids_; }
38 std::vector<int> &
ids() {
return ids_; }
41 std::vector<int> ids_;
Last-query hit buffer shared by spatial indexes. Script pattern: call query* → getResultCount / getRe...
std::vector< int > & ids()
void clear()
Removes all stored entries.
void addUnchecked(int id)
Appends id without uniqueness checks.
int getId(int index) const
Id at dense index, or -1 if out of range.
int getCount() const
Number of stored ids.
const std::vector< int > & ids() const
void addUnique(int id)
Appends id if not already present.