www.mooseframework.org
ExecutionerAttributeReporter.C
Go to the documentation of this file.
1 //* This file is part of the MOOSE framework
2 //* https://www.mooseframework.org
3 //*
4 //* All rights reserved, see COPYRIGHT for full restrictions
5 //* https://github.com/idaholab/moose/blob/master/COPYRIGHT
6 //*
7 //* Licensed under LGPL 2.1, please see LICENSE for details
8 //* https://www.gnu.org/licenses/lgpl-2.1.html
9 
10 // MOOSE includes
12 #include "MooseApp.h"
13 
15 
16 template <>
19 {
21 
22  // Parameter for passing in a pointer the attribute being reported (see
23  // Executioner::addAttributeReporter)
24  params.addPrivateParam<Real *>("value", NULL);
25  return params;
26 }
27 
29  : GeneralPostprocessor(parameters),
30  _value(getCheckedPointerParam<Real *>(
31  "value",
32  "Invalid pointer to an attribute, this object should only be created via "
33  "Executioner::addAttributeReporter"))
34 {
35 }
36 
39 {
40  return *_value;
41 }
ExecutionerAttributeReporter(const InputParameters &parameters)
Class constructor.
void addPrivateParam(const std::string &name, const T &value)
These method add a parameter to the InputParameters object which can be retrieved like any other para...
The main MOOSE class responsible for handling user-defined parameters in almost every MOOSE system...
InputParameters validParams< GeneralPostprocessor >()
A class to report class attributes value from Executioners.
This class is here to combine the Postprocessor interface and the base class Postprocessor object alo...
virtual PostprocessorValue getValue() override
Returns the value of the eigen value as computed by an EigenExecutionerBase object.
registerMooseObject("MooseApp", ExecutionerAttributeReporter)
Real PostprocessorValue
MOOSE typedefs.
Definition: MooseTypes.h:154
Real * _value
Pointer to the attribute to report, this is assigned via the "value" parameter.
InputParameters validParams< ExecutionerAttributeReporter >()