www.mooseframework.org
ExecutionerAttributeReporter.C
Go to the documentation of this file.
1 /****************************************************************/
2 /* DO NOT MODIFY THIS HEADER */
3 /* MOOSE - Multiphysics Object Oriented Simulation Environment */
4 /* */
5 /* (c) 2010 Battelle Energy Alliance, LLC */
6 /* ALL RIGHTS RESERVED */
7 /* */
8 /* Prepared by Battelle Energy Alliance, LLC */
9 /* Under Contract No. DE-AC07-05ID14517 */
10 /* With the U. S. Department of Energy */
11 /* */
12 /* See COPYRIGHT for full restrictions */
13 /****************************************************************/
14 
15 // MOOSE includes
17 #include "MooseApp.h"
18 
19 template <>
22 {
24 
25  // Parameter for passing in a pointer the attribute being reported (see
26  // Executioner::addAttributeReporter)
27  params.addPrivateParam<Real *>("value", NULL);
28  return params;
29 }
30 
32  : GeneralPostprocessor(parameters),
33  _value(parameters.getCheckedPointerParam<Real *>(
34  "value",
35  "Invalid pointer to an attribute, this object should only be created via "
36  "Executioner::addAttributeReporter"))
37 {
38 }
39 
42 {
43  return *_value;
44 }
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 >()
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.
Real PostprocessorValue
MOOSE typedefs.
Definition: MooseTypes.h:73
Real * _value
Pointer to the attribute to report, this is assigned via the "value" parameter.
InputParameters validParams< ExecutionerAttributeReporter >()