www.mooseframework.org
Distribution.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 #include "Distribution.h"
11 #include "MooseRandom.h"
12 
15 {
17  params.addRequiredParam<std::string>("type", "class/type name identifying the distribution");
18  params.registerBase("Distribution");
19  params.registerSystemAttributeName("Distribution");
20  return params;
21 }
22 
24  : MooseObject(parameters), PerfGraphInterface(this)
25 {
26 }
27 
28 Real
30 {
31  mooseError("The distribution '", name(), "' must override the median method.");
32  return 0;
33 }
void registerSystemAttributeName(const std::string &value)
This method is used to define the MOOSE system name that is used by the TheWarehouse object for stori...
virtual Real median() const
Compute the median of the distribution.
Definition: Distribution.C:29
The main MOOSE class responsible for handling user-defined parameters in almost every MOOSE system...
Distribution(const InputParameters &parameters)
Definition: Distribution.C:23
virtual const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:57
void addRequiredParam(const std::string &name, const std::string &doc_string)
This method adds a parameter and documentation string to the InputParameters object that will be extr...
void registerBase(const std::string &value)
This method must be called from every base "Moose System" to create linkage with the Action System...
Every object that can be built by the factory should be derived from this class.
Definition: MooseObject.h:33
Interface for objects interacting with the PerfGraph.
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
static InputParameters validParams()
Definition: Distribution.C:14
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type.
static InputParameters validParams()
Definition: MooseObject.C:25