Line data Source code
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 : #pragma once 11 : 12 : #include "GeneralUserObject.h" 13 : 14 : /** 15 : * User object that get a message from an input file and 16 : * print it out during the simulation 17 : */ 18 : class MessageFromInput : public GeneralUserObject 19 : { 20 : public: 21 : static InputParameters validParams(); 22 : 23 : MessageFromInput(const InputParameters & parameters); 24 : virtual ~MessageFromInput(); 25 : 26 : /// Required implementation of a pure virtual function (not used) 27 10 : virtual void initialize() override{}; 28 : 29 : /// Required implementation of a pure virtual function (not used) 30 10 : virtual void finalize() override{}; 31 : 32 : /// Print out the message 33 : virtual void execute() override; 34 : 35 : private: 36 : /// hold the message from the input file 37 : const std::string _input_message; 38 : };