www.mooseframework.org
StateSimTester.C
Go to the documentation of this file.
1 /****************************************************************/
2 /* MOOSE - Multiphysics Object Oriented Simulation Environment */
3 /* */
4 /* All contents are licensed under LGPL V2.1 */
5 /* See LICENSE for full restrictions */
6 /****************************************************************/
7 
8 #include "StateSimTester.h"
9 #include "StateSimTester.h"
10 
11 #include "libmesh/system.h"
12 #include "StateSimRunner.h"
13 
14 template <>
15 InputParameters
17 {
18  InputParameters params = validParams<GeneralPostprocessor>();
19  params.addRequiredParam<UserObjectName>("state_sim_runner", "The StateSimRunner to test.");
20  MooseEnum system_enum("SYNCTIMES", "SYNCTIMES");
21  params.addParam<MooseEnum>(
22  "test_type", system_enum, "The value for testing (SYNCTIMES). Default == SYNCTIMES");
23  return params;
24 }
25 
26 StateSimTester::StateSimTester(const InputParameters & parameters)
27  : GeneralPostprocessor(parameters),
28  _state_sim_runner_ptr(getUserObject<StateSimRunner>("state_sim_runner")),
29  _test_val_enum(parameters.get<MooseEnum>("test_type").getEnum<SystemEnum>())
30 {
31 }
32 
33 Real
35 {
36  switch (_test_val_enum)
37  {
38  case SYNCTIMES:
40  default:
41  return -1;
42  }
43 }
const StateSimRunner & _state_sim_runner_ptr
InputParameters validParams< StateSimTester >()
StateSimTester(const InputParameters &parameters)
Real getValue() const
virtual Real getValue() override
Object to start a State Simulation and manage the moose timesteping with state event times...
const SystemEnum _test_val_enum