27 declareValueByName<const SolutionInvalidity *>(
34 mooseAssert(solution_invalidity->
processor_id() == 0,
"should only be called on rank 0");
37 const auto & counts = solution_invalidity->
counts();
38 if (counts.size() == 0)
40 json = nlohmann::json::array();
46 entry[
"object_type"] = solution_registry.item(
id).object_type;
47 entry[
"message"] = solution_registry.item(
id).message;
48 entry[
"converged_counts"] = counts[id].current_counts;
49 entry[
"timestep_counts"] = counts[id].current_timestep_counts;
50 entry[
"total_counts"] = counts[id].total_counts;
51 json.push_back(entry);
const std::vector< InvalidCounts > & counts() const
Access the private solution invalidity counts.
Reporter object that has a single execution of the "execute" method for for each execute flag...
const ReporterMode REPORTER_MODE_ROOT
static InputParameters validParams()
SolutionInvalidity & solutionInvalidity()
Get the SolutionInvalidity for this app.
registerMooseObject("MooseApp", SolutionInvalidityReporter)
MooseApp & _app
The MOOSE application this is associated with.
The SolutionInvalidity will contain all the information about the occurrence(s) of solution invalidit...
SolutionInvalidityRegistry & getSolutionInvalidityRegistry()
Get the global SolutionInvalidityRegistry singleton.
Reports the summary table of solution invalid warnings.
void to_json(nlohmann::json &json, const SolutionInvalidity *const &solution_invalidity)
SolutionInvalidityReporter(const InputParameters ¶meters)
processor_id_type processor_id() const
auto index_range(const T &sizable)
static InputParameters validParams()