Template Class t8_partition_search_with_batched_queries
Defined in File t8_forest_search.hxx
Inheritance Relationships
Base Type
public t8_partition_search< void >(Template Class t8_partition_search)
Class Documentation
-
template<typename Query_T, typename Udata = void>
class t8_partition_search_with_batched_queries : public t8_partition_search<void> A class that performs a search in the partition of a forest with batched queries.
All active queries are passed to the callback function, which processes them in a batch. It is recommended to use this version of the searcch if further computations have to be done to evaluate the queries. That way these precomputations are not done for every call to the callback again and only have to be evaluated once per call.
- Template Parameters:
Query_T – The type of queries
Udata – The type of the user data, defaults to void.
Public Functions
-
inline t8_partition_search_with_batched_queries(t8_partition_search_element_callback<Udata> element_callback, t8_partition_search_batched_queries_callback<Query_T, Udata> queries_callback, std::vector<Query_T> &queries, const t8_forest_t forest = nullptr, Udata *user_data = nullptr)
Constructor for the t8_partition_search_with_batched_queries class. This constructor initializes a t8_partition_search_with_batched_queries object with the given element callback, queries callback, forest, and user data. If the forest is not null, it increments the reference count of the forest and asserts that the forest is committed.
- Parameters:
element_callback – [in] A callback function of type t8_partition_search_element_callback<Udata>.
queries_callback – [in] A callback function of type t8_partition_search_batched_queries_callback<Query_T, Udata>.
queries – [in] A reference to a vector of Query_T objects.
forest – [in] A pointer to a t8_forest_t object. Defaults to nullptr.
user_data – [in] A pointer to a Udata object. Defaults to nullptr.
-
inline void update_queries(std::vector<Query_T> &queries)
Updates the queries associated with the object.
-
inline ~t8_partition_search_with_batched_queries()
Destructor for the t8_partition_search_with_batched_queries class.