https://mooseframework.inl.gov
Loading...
Searching...
No Matches
ShaftConnectedComponentPostprocessor.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
12
14
17{
19 MooseEnum quantity("torque inertia");
20 params.addRequiredParam<MooseEnum>("quantity", quantity, "Quantity to get");
21 params.addRequiredParam<UserObjectName>("shaft_connected_component_uo",
22 "Shaft-connected component user object");
23 params.addClassDescription("Gets torque or moment of inertia for a shaft-connected component.");
24 return params;
25}
26
28 const InputParameters & parameters)
29 : GeneralPostprocessor(parameters),
30
31 _quantity(getParam<MooseEnum>("quantity").getEnum<Quantity>()),
32 _component_uo(
33 getUserObject<ADShaftConnectableUserObjectInterface>("shaft_connected_component_uo"))
34{
35}
36
37void
41
42void
46
47Real
49{
50 switch (_quantity)
51 {
54 break;
57 break;
58 default:
59 mooseError("Invalid 'quantity' parameter.");
60 }
61}
registerMooseObject("ThermalHydraulicsApp", ShaftConnectedComponentPostprocessor)
Interface class for user objects that are connected to a shaft.
static InputParameters validParams()
void addRequiredParam(const std::string &name, const std::string &doc_string)
void addClassDescription(const std::string &doc_string)
void mooseError(Args &&... args) const
Gets torque or moment of inertia for a shaft-connected component.
const ADShaftConnectableUserObjectInterface & _component_uo
Shaft-connected component user object.
ShaftConnectedComponentPostprocessor(const InputParameters &parameters)
auto raw_value(const Eigen::Map< T > &in)