11 #include "IO/Importers/Tags.hpp"
12 #include "IO/Observer/ArrayComponentId.hpp"
14 #include "Parallel/Invoke.hpp"
17 #include "Utilities/MakeString.hpp"
20 #include "Utilities/TaggedTuple.hpp"
24 template <
typename Metavariables>
25 struct ElementDataReader;
27 struct RegisterElementWithSelf;
32 namespace importers::Actions {
43 template <
typename DbTagsList,
typename... InboxTags,
typename Metavariables,
44 size_t Dim,
typename ActionList,
typename ParallelComponent>
46 db::DataBox<DbTagsList>& box,
50 const ParallelComponent*
const ) noexcept {
53 auto& local_reader_component =
57 Parallel::simple_action<importers::Actions::RegisterElementWithSelf>(
58 local_reader_component,
63 return {std::move(box)};
79 typename ParallelComponent,
typename DbTagsList,
typename Metavariables,
80 typename ArrayIndex,
typename DataBox = db::DataBox<DbTagsList>,
83 static void apply(db::DataBox<DbTagsList>& box,
88 db::mutate<Tags::RegisteredElements>(
90 [&array_component_id, &grid_name ](
93 registered_elements) noexcept {
94 (*registered_elements)[array_component_id] = grid_name;
Definition: ElementReceiveInterpPoints.hpp:15
auto get_parallel_component(GlobalCache< Metavariables > &cache) noexcept -> Parallel::proxy_from_parallel_component< GlobalCache_detail::get_component_if_mocked< typename Metavariables::component_list, ParallelComponentTag >> &
Access the Charm++ proxy associated with a ParallelComponent.
Definition: GlobalCache.hpp:521
Items related to loading data from files.
Definition: ReadVolumeData.hpp:39
A nodegroup parallel component that reads in a volume data file and distributes its data to elements ...
Definition: ElementDataReader.hpp:38
An associative container that is indexed by structs.
Definition: TaggedTuple.hpp:271
Invoked on the importers::ElementDataReader component to store the registered data.
Definition: RegisterWithElementDataReader.hpp:77
An ID type that identifies both the parallel component and the index in the parallel component.
Definition: ArrayComponentId.hpp:27
gsl::not_null< T * > make_not_null(T *ptr) noexcept
Construct a not_null from a pointer. Often this will be done as an implicit conversion,...
Definition: Gsl.hpp:880
The array index used for indexing Chare Arrays, mostly an implementation detail.
Definition: ArrayIndex.hpp:28
typename Requires_detail::requires_impl< B >::template_error_type_failed_to_meet_requirements_on_template_parameters Requires
Express requirements on the template parameters of a function or class, replaces std::enable_if_t
Definition: Requires.hpp:67
Register an element with the volume data reader component.
Definition: RegisterWithElementDataReader.hpp:42
Make a string by streaming into object.
Definition: MakeString.hpp:18
Require a pointer to not be a nullptr
Definition: ReadSpecThirdOrderPiecewisePolynomial.hpp:13