https://mooseframework.inl.gov
Loading...
Searching...
No Matches
ElementIntegerAux.C
Go to the documentation of this file.
1//* This file is part of the MOOSE framework
2//* https://mooseframework.inl.gov
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 "ElementIntegerAux.h"
11
13
16{
18 params.addClassDescription("Creates a field showing the element integer.");
19 params.addParam<std::vector<ExtraElementIDName>>("integer_names",
20 "Element integers to be retrieved");
21 return params;
22}
23
25 : AuxKernel(parameters), _id(getElementID("integer_names"))
26{
27 if (isNodal())
28 mooseError("ElementIntegerAux must be for an elemental variable");
29}
30
31Real
registerMooseObject("MooseApp", ElementIntegerAux)
void mooseError(Args &&... args)
Emit an error message with the given stringified, concatenated args and terminate the application.
Definition MooseError.h:311
bool isNodal() const
Nodal or elemental kernel?
Definition AuxKernel.h:43
static InputParameters validParams()
Definition AuxKernel.C:27
const dof_id_type & _id
ElementIntegerAux(const InputParameters &parameters)
static InputParameters validParams()
virtual Real computeValue() override
Compute and return the value of the aux variable.
The main MOOSE class responsible for handling user-defined parameters in almost every MOOSE system.
void addParam(const std::string &name, const S &value, const std::string &doc_string)
These methods add an optional parameter and a documentation string to the InputParameters object.
void addClassDescription(const std::string &doc_string)
This method adds a description of the class that will be displayed in the input file syntax dump.