https://mooseframework.inl.gov
Classes | Public Member Functions | Static Public Member Functions | Public Attributes | Static Public Attributes | Protected Types | Protected Member Functions | Protected Attributes | Private Types | Private Member Functions | Static Private Member Functions | Private Attributes | Friends | List of all members
MooseApp Class Reference

Base class for MOOSE-based applications. More...

#include <MooseApp.h>

Inheritance diagram for MooseApp:
[legend]

Classes

struct  DynamicLibraryInfo
 
struct  FixedPointConfig
 Stores configuration options relating to the fixed-point solving capability. More...
 
struct  InterfaceRegistryObjects
 
struct  InterfaceRegistryObjectsBase
 

Public Member Functions

std::optional< MooseEnumgetComputeDevice () const
 Get the device accelerated computations are supposed to be running on. More...
 
torch::DeviceType getLibtorchDevice () const
 Get the device torch is supposed to be running on. More...
 
virtual ~MooseApp ()
 
TheWarehousetheWarehouse ()
 
virtual std::string getPrintableName () const
 Get printable name of the application. More...
 
virtual std::string appBinaryName () const
 
int exitCode () const
 Get the shell exit code for the application. More...
 
void setExitCode (const int exit_code)
 Sets the exit code that the application will exit with. More...
 
const RankMaprankMap ()
 The RankMap is a useful object for determining how the processes are laid out on the physical nodes of the cluster. More...
 
PerfGraphperfGraph ()
 Get the PerfGraph for this app. More...
 
virtual void run ()
 Run the application. More...
 
std::string getFrameworkVersion () const
 Returns the framework version. More...
 
virtual std::string getVersion () const
 Returns the current version of the framework or application (default: framework version). More...
 
std::string getPrintableVersion () const
 Non-virtual method for printing out the version string in a consistent format. More...
 
virtual void setupOptions ()
 Setup options based on InputParameters. More...
 
ActionWarehouseactionWarehouse ()
 Return a writable reference to the ActionWarehouse associated with this app. More...
 
const ActionWarehouseactionWarehouse () const
 Return a const reference to the ActionWarehouse associated with this app. More...
 
Moose::Builderbuilder ()
 Returns a writable reference to the builder. More...
 
Syntaxsyntax ()
 Returns a writable reference to the syntax object. More...
 
const std::vector< std::string > & getInputFileNames () const
 
const std::string & getLastInputFileName () const
 
void setOutputFileBase (const std::string &output_file_base)
 Override the selection of the output file base name. More...
 
std::string getOutputFileBase (bool for_non_moose_build_output=false) const
 Get the output file base name. More...
 
void setOutputPosition (const Point &p)
 Tell the app to output in a specific position. More...
 
std::list< std::string > getCheckpointDirectories () const
 Get all checkpoint directories. More...
 
std::list< std::string > getCheckpointFiles () const
 Extract all possible checkpoint file names. More...
 
bool hasOutputPosition () const
 Whether or not an output position has been set. More...
 
Point getOutputPosition () const
 Get the output position. More...
 
void setStartTime (Real time)
 Set the starting time for the simulation. More...
 
bool hasStartTime () const
 
Real getStartTime () const
 
void setGlobalTimeOffset (Real offset)
 Each App has it's own local time. More...
 
Real getGlobalTimeOffset () const
 Each App has it's own local time. More...
 
std::string getFileName (bool stripLeadingPath=true) const
 Return the primary (first) filename that was parsed Note: When stripLeadingPath is false, this function returns the same name as getInputFileName() method when the input file is not a link. More...
 
void setErrorOverridden ()
 Set a flag so that the parser will throw an error if overridden parameters are detected. More...
 
void disableCheckUnusedFlag ()
 Removes warnings and error checks for unrecognized variables in the input file. More...
 
ExecutionergetExecutioner () const
 Retrieve the Executioner for this App. More...
 
ExecutorgetExecutor () const
 
NullExecutorgetNullExecutor () const
 
bool useExecutor () const
 
FEProblemBasefeProblem () const
 
void setExecutioner (std::shared_ptr< Executioner > &&executioner)
 Set the Executioner for this App. More...
 
void setExecutor (std::shared_ptr< Executor > &&executor)
 
void addExecutor (const std::string &type, const std::string &name, const InputParameters &params)
 
void addExecutorParams (const std::string &type, const std::string &name, const InputParameters &params)
 Adds the parameters for an Executor to the list of parameters. More...
 
void createExecutors ()
 After adding all of the Executor Params - this function will actually cause all of them to be built. More...
 
ExecutorgetExecutor (const std::string &name, bool fail_if_not_found=true)
 Get an Executor. More...
 
FixedPointConfigfixedPointConfig ()
 This info is stored here because we need a "globalish" place to put it in order to allow communication between a multiapp and solver-specific internals (i.e. More...
 
bool & useNonlinear ()
 Returns a writable Boolean indicating whether this app will use a Nonlinear or Eigen System. More...
 
bool & useEigenvalue ()
 Returns a writable Boolean indicating whether this app will use an eigenvalue executioner. More...
 
FactorygetFactory ()
 Retrieve a writable reference to the Factory associated with this App. More...
 
ActionFactorygetActionFactory ()
 Retrieve a writable reference to the ActionFactory associated with this App. More...
 
processor_id_type processor_id () const
 Returns the MPI processor ID of the current processor. More...
 
std::shared_ptr< CommandLinecommandLine () const
 Get the command line. More...
 
void setExodusFileRestart (bool flag)
 Set the flag to indicate whether or not we need to use a separate Exodus reader to read the mesh BEFORE we create the mesh. More...
 
bool getExodusFileRestart () const
 Whether or not we need to use a separate Exodus reader to read the mesh BEFORE we create the mesh. More...
 
void setExReaderForRestart (std::shared_ptr< libMesh::ExodusII_IO > &&exreader)
 Set the Exodus reader to restart variables from an Exodus mesh file. More...
 
libMesh::ExodusII_IOgetExReaderForRestart () const
 Get the Exodus reader to restart variables from an Exodus mesh file. More...
 
virtual void runInputFile ()
 Actually build everything in the input file. More...
 
virtual void executeExecutioner ()
 Execute the Executioner that was built. More...
 
bool getDistributedMeshOnCommandLine () const
 Returns true if the user specified –distributed-mesh (or –parallel-mesh, for backwards compatibility) on the command line and false otherwise. More...
 
bool isRecovering () const
 Whether or not this is a "recover" calculation. More...
 
bool isRestarting () const
 Whether or not this is a "restart" calculation. More...
 
bool isSplitMesh () const
 Whether or not this is a split mesh operation. More...
 
void setRestartRecoverFileBase (const std::string &file_base)
 mutator for recover_base (set by RecoverBaseAction) More...
 
bool testCheckpointHalfTransient () const
 Whether or not this simulation should only run half its transient (useful for testing recovery) More...
 
bool testReStep () const
 Whether or not this simulation should fail a timestep and repeat (for testing). More...
 
void setOutputFileNumbers (const std::map< std::string, unsigned int > &numbers)
 Store a map of outputter names and file numbers The MultiApp system requires this to get the file numbering to propagate down through the Multiapps. More...
 
const std::map< std::string, unsigned int > & getOutputFileNumbers () const
 Store a map of outputter names and file numbers The MultiApp system requires this to get the file numbering to propogate down through the multiapps. More...
 
OutputWarehousegetOutputWarehouse ()
 Get the OutputWarehouse objects. More...
 
const OutputWarehousegetOutputWarehouse () const
 
const SystemInfogetSystemInfo () const
 Get SystemInfo object. More...
 
std::string appNameToLibName (const std::string &app_name) const
 Converts an application name to a library name: Examples: AnimalApp -> libanimal-oprof.la (assuming METHOD=oprof) ThreeWordAnimalApp -> libthree_word_animal-dbg.la (assuming METHOD=dbg) More...
 
std::string libNameToAppName (const std::string &library_name) const
 Converts a library name to an application name: More...
 
std::set< std::string > getLoadedLibraryPaths () const
 Return the paths of loaded libraries. More...
 
std::set< std::string > getLibrarySearchPaths (const std::string &library_path_from_param) const
 Return the paths searched by MOOSE when loading libraries. More...
 
InputParameterWarehousegetInputParameterWarehouse ()
 Get the InputParameterWarehouse for MooseObjects. More...
 
RestartableDataValueregisterRestartableData (std::unique_ptr< RestartableDataValue > data, THREAD_ID tid, bool read_only, const RestartableDataMapName &metaname="")
 
RestartableDataValueregisterRestartableData (const std::string &name, std::unique_ptr< RestartableDataValue > data, THREAD_ID tid, bool read_only, const RestartableDataMapName &metaname="")
 
bool hasRestartableMetaData (const std::string &name, const RestartableDataMapName &metaname) const
 
RestartableDataValuegetRestartableMetaData (const std::string &name, const RestartableDataMapName &metaname, THREAD_ID tid)
 
void possiblyLoadRestartableMetaData (const RestartableDataMapName &name, const std::filesystem::path &folder_base)
 Loads the restartable meta data for name if it is available with the folder base folder_base. More...
 
void loadRestartableMetaData (const std::filesystem::path &folder_base)
 Loads all available restartable meta data if it is available with the folder base folder_base. More...
 
std::vector< std::filesystem::path > writeRestartableMetaData (const RestartableDataMapName &name, const std::filesystem::path &folder_base)
 Writes the restartable meta data for name with a folder base of folder_base. More...
 
std::vector< std::filesystem::path > writeRestartableMetaData (const std::filesystem::path &folder_base)
 Writes all available restartable meta data with a file base of file_base. More...
 
RestartableDataMapgetRestartableDataMap (const RestartableDataMapName &name)
 Return a reference to restartable data for the specific type flag. More...
 
bool hasRestartableDataMap (const RestartableDataMapName &name) const
 
void registerRestartableDataMapName (const RestartableDataMapName &name, std::string suffix="")
 Reserve a location for storing custom RestartableDataMap objects. More...
 
const std::string & getRestartableDataMapName (const RestartableDataMapName &name) const
 
const DataNamesgetRecoverableData () const
 Return a reference to the recoverable data object. More...
 
std::vector< std::filesystem::path > backup (const std::filesystem::path &folder_base)
 Backs up the application to the folder folder_base. More...
 
std::unique_ptr< Backupbackup ()
 Backs up the application memory in a Backup. More...
 
virtual void preBackup ()
 Insertion point for other apps that is called before backup() More...
 
void restore (const std::filesystem::path &folder_base, const bool for_restart)
 Restore an application from file. More...
 
void restore (std::unique_ptr< Backup > backup, const bool for_restart)
 Restore an application from the backup backup. More...
 
virtual void postRestore (const bool)
 Insertion point for other apps that is called after restore() More...
 
void restoreFromInitialBackup (const bool for_restart)
 Restores from a "initial" backup, that is, one set in _initial_backup. More...
 
std::unique_ptr< BackupfinalizeRestore ()
 Finalizes (closes) the restoration process done in restore(). More...
 
virtual std::string header () const
 Returns a string to be printed at the beginning of a simulation. More...
 
unsigned int multiAppLevel () const
 The MultiApp Level. More...
 
unsigned int multiAppNumber () const
 The MultiApp number. More...
 
bool isUltimateMaster () const
 Whether or not this app is the ultimate master app. More...
 
bool useMasterMesh () const
 Returns whether to use the parent app mesh as the mesh for this app. More...
 
const MooseMeshmasterMesh () const
 Returns a pointer to the master mesh. More...
 
const MooseMeshmasterDisplacedMesh () const
 Returns a pointer to the master displaced mesh. More...
 
MeshGeneratorSystemgetMeshGeneratorSystem ()
 Gets the system that manages the MeshGenerators. More...
 
ChainControlDataSystemgetChainControlDataSystem ()
 Gets the system that manages the ChainControls. More...
 
void addMeshGenerator (const std::string &type, const std::string &name, const InputParameters &params)
 Add a mesh generator that will act on the meshes in the system. More...
 
bool hasMeshGenerator (const MeshGeneratorName &name) const
 
const MeshGeneratorgetMeshGenerator (const std::string &name) const
 
std::unique_ptr< MeshBase > getMeshGeneratorMesh ()
 
std::vector< std::string > getMeshGeneratorNames () const
 
const MeshGeneratorappendMeshGenerator (const std::string &type, const std::string &name, InputParameters params)
 Append a mesh generator that will act on the final mesh generator in the system. More...
 
virtual bool constructingMeshGenerators () const
 Whether this app is constructing mesh generators. More...
 
bool checkInput () const
 Returns whether the Application is running in check input mode. More...
 
bool getFPTrapFlag () const
 Returns whether FPE trapping is turned on (either because of debug or user requested) More...
 
bool hasRelationshipManager (const std::string &name) const
 Returns a Boolean indicating whether a RelationshipManater exists with the same name. More...
 
bool addRelationshipManager (std::shared_ptr< RelationshipManager > relationship_manager)
 Transfers ownership of a RelationshipManager to the application for lifetime management. More...
 
std::filesystem::path restartFolderBase (const std::filesystem::path &folder_base) const
 The file suffix for restartable data. More...
 
const hit::Node * getCurrentActionHitNode () const
 
void attachRelationshipManagers (Moose::RelationshipManagerType rm_type, bool attach_geometric_rm_final=false)
 Attach the relationship managers of the given type Note: Geometric relationship managers that are supposed to be attached late will be attached when Algebraic are attached. More...
 
void attachRelationshipManagers (MeshBase &mesh, MooseMesh &moose_mesh)
 Attach geometric relationship managers to the given MeshBase object. More...
 
const std::vector< std::shared_ptr< RelationshipManager > > & getReleationshipManagers ()
 Retrieve the relationship managers. More...
 
std::vector< std::pair< std::string, std::string > > getRelationshipManagerInfo () const
 Returns the Relationship managers info suitable for printing. More...
 
const ExecFlagEnumgetExecuteOnEnum () const
 Return the app level ExecFlagEnum, this contains all the available flags for the app. More...
 
bool hasInitialBackup () const
 
bool defaultAutomaticScaling () const
 Whether to enable automatic scaling by default. More...
 
const std::shared_ptr< libMesh::Parallel::CommunicatorgetCommunicator () const
 
const std::set< std::shared_ptr< RelationshipManager > > & relationshipManagers () const
 Return the container of relationship managers. More...
 
void checkMetaDataIntegrity () const
 Function to check the integrity of the restartable meta data structure. More...
 
virtual bool errorOnJacobianNonzeroReallocation () const
 Whether this application should by default error on Jacobian nonzero reallocations. More...
 
template<class T >
void registerInterfaceObject (T &interface)
 Registers an interface object for accessing with getInterfaceObjects. More...
 
template<class T >
const std::vector< T * > & getInterfaceObjects () const
 Gets the registered interface objects for a given interface. More...
 
bool forceRestart () const
 Whether or not we are forcefully restarting (allowing the load of potentially incompatibie checkpoints); used within RestartableDataReader. More...
 
bool unusedFlagIsWarning () const
 Returns whether the flag for unused parameters is set to throw a warning only. More...
 
bool unusedFlagIsError () const
 Returns whether the flag for unused parameters is set to throw an error. More...
 
void setMFEMDevice (const std::string &device_string, Moose::PassKey< MFEMProblemSolve >)
 Create/configure the MFEM device with the provided device_string. More...
 
std::shared_ptr< mfem::Device > getMFEMDevice (Moose::PassKey< MultiApp >)
 Get the MFEM device object. More...
 
const std::set< std::string > & getMFEMDevices (Moose::PassKey< MultiApp >) const
 Get the configured MFEM devices. More...
 
const Parallel::Communicatorcomm () const
 
processor_id_type n_processors () const
 
MooseAppgetMooseApp () const
 Get the MooseApp this class is associated with. More...
 
const std::string & type () const
 Get the type of this class. More...
 
const std::string & name () const
 Get the name of the class. More...
 
std::string typeAndName () const
 Get the class's combined type and name; useful in error handling. More...
 
MooseObjectParameterName uniqueParameterName (const std::string &parameter_name) const
 
MooseObjectName uniqueName () const
 
const InputParametersparameters () const
 Get the parameters of the object. More...
 
const hit::Node * getHitNode () const
 
bool hasBase () const
 
const std::string & getBase () const
 
template<typename T >
const T & getParam (const std::string &name) const
 Retrieve a parameter for the object. More...
 
template<typename T1 , typename T2 >
std::vector< std::pair< T1, T2 > > getParam (const std::string &param1, const std::string &param2) const
 Retrieve two parameters and provide pair of parameters for the object. More...
 
template<typename T >
const T * queryParam (const std::string &name) const
 Query a parameter for the object. More...
 
template<typename T >
const T & getRenamedParam (const std::string &old_name, const std::string &new_name) const
 Retrieve a renamed parameter for the object. More...
 
template<typename T >
getCheckedPointerParam (const std::string &name, const std::string &error_string="") const
 Verifies that the requested parameter exists and is not NULL and returns it to the caller. More...
 
bool isParamValid (const std::string &name) const
 Test if the supplied parameter is valid. More...
 
bool isParamSetByUser (const std::string &name) const
 Test if the supplied parameter is set by a user, as opposed to not set or set to default. More...
 
void connectControllableParams (const std::string &parameter, const std::string &object_type, const std::string &object_name, const std::string &object_parameter) const
 Connect controllable parameter of this action with the controllable parameters of the objects added by this action. More...
 
template<typename... Args>
void paramError (const std::string &param, Args... args) const
 Emits an error prefixed with the file and line number of the given param (from the input file) along with the full parameter path+name followed by the given args as the message. More...
 
template<typename... Args>
void paramWarning (const std::string &param, Args... args) const
 Emits a warning prefixed with the file and line number of the given param (from the input file) along with the full parameter path+name followed by the given args as the message. More...
 
template<typename... Args>
void paramInfo (const std::string &param, Args... args) const
 Emits an informational message prefixed with the file and line number of the given param (from the input file) along with the full parameter path+name followed by the given args as the message. More...
 
std::string messagePrefix (const bool hit_prefix=true) const
 
std::string errorPrefix (const std::string &) const
 Deprecated message prefix; the error type is no longer used. More...
 
template<typename... Args>
void mooseError (Args &&... args) const
 Emits an error prefixed with object name and type and optionally a file path to the top-level block parameter if available. More...
 
template<typename... Args>
void mooseDocumentedError (const std::string &repo_name, const unsigned int issue_num, Args &&... args) const
 
template<typename... Args>
void mooseErrorNonPrefixed (Args &&... args) const
 Emits an error without the prefixing included in mooseError(). More...
 
template<typename... Args>
void mooseWarning (Args &&... args) const
 Emits a warning prefixed with object name and type. More...
 
template<typename... Args>
void mooseWarningNonPrefixed (Args &&... args) const
 Emits a warning without the prefixing included in mooseWarning(). More...
 
template<typename... Args>
void mooseDeprecated (Args &&... args) const
 
template<typename... Args>
void mooseInfo (Args &&... args) const
 
void callMooseError (std::string msg, const bool with_prefix, const hit::Node *node=nullptr) const
 External method for calling moose error with added object context. More...
 
SolutionInvaliditysolutionInvalidity ()
 Get the SolutionInvalidity for this app. More...
 
const SolutionInvaliditysolutionInvalidity () const
 
const Parserparser () const
 
Parserparser ()
 
bool hasRestartRecoverFileBase () const
 Return true if the recovery file base is set. More...
 
bool hasRecoverFileBase () const
 
std::string getRestartRecoverFileBase () const
 The file_base for the recovery file. More...
 
std::string getRecoverFileBase () const
 
void dynamicAllRegistration (const std::string &app_name, Factory *factory, ActionFactory *action_factory, Syntax *syntax, std::string library_path, const std::string &library_name)
 Thes methods are called to register applications or objects on demand. More...
 
void dynamicAppRegistration (const std::string &app_name, std::string library_path, const std::string &library_name, bool lib_load_deps)
 
const std::vector< RestartableDataMap > & getRestartableData () const
 Return reference to the restartable data object. More...
 
std::vector< RestartableDataMap > & getRestartableData ()
 
void setRestart (bool value)
 Sets the restart/recover flags. More...
 
void setRecover (bool value)
 
auto getRestartableDataMapBegin ()
 Iterator based access to the extra RestartableDataMap objects; see Checkpoint.C for use case. More...
 
auto getRestartableDataMapEnd ()
 

Static Public Member Functions

static InputParameters validParams ()
 
static const std::string & checkpointSuffix ()
 The file suffix for the checkpoint mesh. More...
 
static std::filesystem::path metaDataFolderBase (const std::filesystem::path &folder_base, const std::string &map_suffix)
 The file suffix for meta data (header and data) More...
 
static void addAppParam (InputParameters &params)
 
static void addInputParam (InputParameters &params)
 
static void callMooseError (MooseApp *const app, const InputParameters &params, std::string msg, const bool with_prefix, const hit::Node *node)
 External method for calling moose error with added object context. More...
 

Public Attributes

const ConsoleStream _console
 An instance of helper class to write streams to the Console objects. More...
 

Static Public Attributes

static const RestartableDataMapName MESH_META_DATA = "MeshMetaData"
 
static const std::string MESH_META_DATA_SUFFIX = "mesh"
 
static const std::string type_param = "_type"
 The name of the parameter that contains the object type. More...
 
static const std::string name_param = "_object_name"
 The name of the parameter that contains the object name. More...
 
static const std::string unique_name_param = "_unique_name"
 The name of the parameter that contains the unique object name. More...
 
static const std::string app_param = "_moose_app"
 The name of the parameter that contains the MooseApp. More...
 
static const std::string moose_base_param = "_moose_base"
 The name of the parameter that contains the moose system base. More...
 

Protected Types

enum  UNUSED_CHECK { OFF, WARN_UNUSED, ERROR_UNUSED }
 Indicates whether warnings, errors, or no output is displayed when unused parameters are detected. More...
 

Protected Member Functions

void dynamicRegistration (const libMesh::Parameters &params)
 Helper method for dynamic loading of objects. More...
 
void loadLibraryAndDependencies (const std::string &library_filename, const libMesh::Parameters &params, bool load_dependencies=true)
 Recursively loads libraries and dependencies in the proper order to fully register a MOOSE application that may have several dependencies. More...
 
 MooseApp (const InputParameters &parameters)
 Constructor is protected so that this object is constructed through the AppFactory object. More...
 
void registerRestartableNameWithFilter (const std::string &name, Moose::RESTARTABLE_FILTER filter)
 NOTE: This is an internal function meant for MOOSE use only! More...
 
void errorCheck ()
 Runs post-initialization error checking that cannot be run correctly unless the simulation has been fully set up and initialized. More...
 
void outputMachineReadableData (const std::string &param, const std::string &start_marker, const std::string &end_marker, const std::string &data) const
 Outputs machine readable data (JSON, YAML, etc.) either to the screen (if no filename was provided as an argument to the parameter param) or to a file (if a filename was provided). More...
 
PerfID registerTimedSection (const std::string &section_name, const unsigned int level) const
 Call to register a named section for timing. More...
 
PerfID registerTimedSection (const std::string &section_name, const unsigned int level, const std::string &live_message, const bool print_dots=true) const
 Call to register a named section for timing. More...
 
std::string timedSectionName (const std::string &section_name) const
 

Static Protected Member Functions

static void addCapability (const std::string &capability, CapabilityUtils::Type value, const std::string &doc)
 register a new capability More...
 
static void addCapability (const std::string &capability, const char *value, const std::string &doc)
 

Protected Attributes

const std::string _type
 The string representation of the type of this object as registered (see registerApp(AppName)) More...
 
const std::shared_ptr< libMesh::Parallel::Communicator_comm
 The MPI communicator this App is going to use. More...
 
std::string _output_file_base
 The output file basename. More...
 
bool _file_base_set_by_user
 Whether or not file base is set through input or setOutputFileBase by MultiApp. More...
 
bool _output_position_set
 Whether or not an output position has been set for this app. More...
 
Point _output_position
 The output position. More...
 
bool _start_time_set
 Whether or not an start time has been set. More...
 
Real _start_time
 The time at which to start the simulation. More...
 
Real _global_time_offset
 Offset of the local App time to the "global" problem time. More...
 
Syntax _syntax
 Syntax of the input file. More...
 
std::unique_ptr< InputParameterWarehouse_input_parameter_warehouse
 Input parameter storage structure; unique_ptr so we can control its destruction order. More...
 
ActionFactory _action_factory
 The Factory responsible for building Actions. More...
 
ActionWarehouse _action_warehouse
 Where built actions are stored. More...
 
OutputWarehouse _output_warehouse
 OutputWarehouse object for this App. More...
 
const std::shared_ptr< Parser_parser
 Parser for parsing the input file (owns the root hit node) More...
 
const std::shared_ptr< CommandLine_command_line
 The CommandLine object. More...
 
SystemInfo _sys_info
 System Information. More...
 
Moose::Builder _builder
 Builder for building app related parser tree. More...
 
std::vector< RestartableDataMap_restartable_data
 Where the restartable data is held (indexed on tid) More...
 
DataNames _recoverable_data_names
 Data names that will only be read from the restart file during RECOVERY. More...
 
PerfGraph_perf_graph
 The PerfGraph object for this application (recoverable) More...
 
SolutionInvalidity_solution_invalidity
 The SolutionInvalidity object for this application. More...
 
const RankMap _rank_map
 The RankMap is a useful object for determining how the processes are laid out on the physical hardware. More...
 
std::shared_ptr< Executioner_executioner
 Pointer to the executioner of this run (typically build by actions) More...
 
std::shared_ptr< Executor_executor
 Pointer to the Executor of this run. More...
 
std::map< std::string, std::shared_ptr< Executor > > _executors
 Pointers to all of the Executors for this run. More...
 
std::unordered_map< std::string, std::pair< std::string, std::unique_ptr< InputParameters > > > _executor_params
 Used in building the Executors Maps the name of the Executor block to the <type, params> More...
 
FixedPointConfig _fixed_point_config
 Multiapp-related fixed point algorithm configuration details primarily intended to be passed to and used by the executioner/executor system. More...
 
const bool _use_executor
 Indicates whether we are operating in the new/experimental executor mode instead of using the legacy executioner system. More...
 
std::shared_ptr< NullExecutor_null_executor
 Used to return an executor that does nothing. More...
 
bool _use_nonlinear
 Boolean to indicate whether to use a Nonlinear or EigenSystem (inspected by actions) More...
 
bool _use_eigen_value
 Boolean to indicate whether to use an eigenvalue executioner. More...
 
enum MooseApp::UNUSED_CHECK _enable_unused_check
 
Factory _factory
 
bool _error_overridden
 Indicates whether warnings or errors are displayed when overridden parameters are detected. More...
 
std::string _early_exit_param
 Indicates if simulation is ready to exit, and keeps track of which param caused it to exit. More...
 
bool _ready_to_exit
 
int _exit_code
 The exit code. More...
 
bool _initial_from_file
 This variable indicates when a request has been made to restart from an Exodus file. More...
 
std::shared_ptr< libMesh::ExodusII_IO_ex_reader
 The Exodus reader when _initial_from_file is set to true. More...
 
bool _distributed_mesh_on_command_line
 This variable indicates that DistributedMesh should be used for the libMesh mesh underlying MooseMesh. More...
 
bool _recover
 Whether or not this is a recovery run. More...
 
bool _restart
 Whether or not this is a restart run. More...
 
bool _split_mesh
 Whether or not we are performing a split mesh operation (–split-mesh) More...
 
const bool _use_split
 Whether or not we are using a (pre-)split mesh (automatically DistributedMesh) More...
 
const bool _force_restart
 Whether or not we are forcefully attempting to load checkpoints (–force-restart) More...
 
bool _trap_fpe
 Whether or not FPE trapping should be turned on. More...
 
std::string _restart_recover_base
 The base name to restart/recover from. If blank then we will find the newest checkpoint file. More...
 
const bool _test_checkpoint_half_transient
 Whether or not this simulation should only run half its transient (useful for testing recovery) More...
 
const bool _test_restep
 Whether or not this simulation should fail its middle timestep and repeat (for testing) More...
 
std::map< std::string, unsigned int_output_file_numbers
 Map of outputer name and file number (used by MultiApps to propagate file numbers down through the multiapps) More...
 
bool _check_input
 true if we want to just check the input file More...
 
std::set< std::shared_ptr< RelationshipManager > > _relationship_managers
 The relationship managers that have been added. More...
 
std::map< Moose::RelationshipManagerType, std::set< const RelationshipManager * > > _attached_relationship_managers
 The relationship managers that have been attached (type -> RMs) More...
 
std::unordered_map< RelationshipManager *, std::shared_ptr< libMesh::GhostingFunctor > > _undisp_to_disp_rms
 A map from undisplaced relationship managers to their displaced clone (stored as the base GhostingFunctor). More...
 
std::unordered_map< std::string, DynamicLibraryInfo_lib_handles
 The library archive (name only), registration method and the handle to the method. More...
 
MooseApp_pg_moose_app
 The MooseApp that owns the PerfGraph. More...
 
const std::string _prefix
 A prefix to use for all sections. More...
 
const Parallel::Communicator_communicator
 
MooseApp_app
 The MOOSE application this is associated with. More...
 
const std::string & _name
 The name of this class. More...
 
const InputParameters_pars
 The object's parameters. More...
 

Private Types

enum  RegistrationType { APPLICATION, REGALL }
 Enumeration for holding the valid types of dynamic registrations allowed. More...
 

Private Member Functions

void recursivelyCreateExecutors (const std::string &current_executor_name, std::list< std::string > &possible_roots, std::list< std::string > &current_branch)
 Internal function used to recursively create the executor objects. More...
 
void registerCapabilities ()
 Register all base MooseApp capabilities to the Moose::Capabilities registry. More...
 
void removeRelationshipManager (std::shared_ptr< RelationshipManager > relationship_manager)
 Purge this relationship manager from meshes and DofMaps and finally from us. More...
 
torch::DeviceType determineLibtorchDeviceType (const MooseEnum &device) const
 Function to determine the device which should be used by libtorch on this application. More...
 
void createMinimalApp ()
 Method for creating the minimum required actions for an application (no input file) More...
 
void setCheckUnusedFlag (bool warn_is_error=false)
 Set a flag so that the parser will either warn or error when unused variables are seen after parsing is complete. More...
 
bool hasRMClone (const RelationshipManager &template_rm, const MeshBase &mesh) const
 
RelationshipManagergetRMClone (const RelationshipManager &template_rm, const MeshBase &mesh) const
 Return the relationship manager clone originally created from the provided template relationship manager and mesh. More...
 
RelationshipManagercreateRMFromTemplateAndInit (const RelationshipManager &template_rm, MooseMesh &moose_mesh, MeshBase &mesh, const libMesh::DofMap *dof_map=nullptr)
 Take an input relationship manager, clone it, and then initialize it with provided mesh and optional dof_map. More...
 
PerfGraphcreateRecoverablePerfGraph ()
 Creates a recoverable PerfGraph. More...
 
SolutionInvaliditycreateRecoverableSolutionInvalidity ()
 Creates a recoverable SolutionInvalidity. More...
 
bool showInputs () const
 Prints a message showing the installable inputs for a given application (if getInstallableInputs has been overridden for an application). More...
 
virtual std::string getInstallableInputs () const
 Method to retrieve the installable inputs from a given applications <app>Revision.h file. More...
 
bool copyInputs ()
 Handles the copy_inputs input parameter logic: Checks to see whether the passed argument is valid (a readable installed directory) and recursively copies those files into a read/writable location for the user. More...
 
bool runInputs ()
 Handles the run input parameter logic: Checks to see whether a directory exists in user space and launches the TestHarness to process the given directory. More...
 

Static Private Member Functions

static void checkReservedCapability (const std::string &capability)
 Helper that reports an error if the given capability is reserved and should not be added via addCapability(). More...
 

Private Attributes

std::unordered_map< RestartableDataMapName, std::pair< RestartableDataMap, std::string > > _restartable_meta_data
 General storage for custom RestartableData that can be added to from outside applications. More...
 
std::unique_ptr< TheWarehouse_the_warehouse
 The combined warehouse for storing any MooseObject based object. More...
 
unsigned int _multiapp_level
 Level of multiapp, the master is level 0. This used by the Console to indent output. More...
 
unsigned int _multiapp_number
 Numbering in all the sub-apps on the same level. More...
 
const bool _use_master_mesh
 Whether to use the parent app mesh for this app. More...
 
const MooseMesh *const _master_mesh
 The mesh from master app. More...
 
const MooseMesh *const _master_displaced_mesh
 The displaced mesh from master app. More...
 
MeshGeneratorSystem _mesh_generator_system
 The system that manages the MeshGenerators. More...
 
ChainControlDataSystem _chain_control_system
 The system that manages the ChainControls. More...
 
RestartableDataReader _rd_reader
 
const ExecFlagEnum _execute_flags
 Execution flags for this App. More...
 
std::streambuf * _output_buffer_cache
 Cache output buffer so the language server can turn it off then back on. More...
 
const bool _automatic_automatic_scaling
 Whether to turn on automatic scaling by default. More...
 
bool _cpu_profiling = false
 CPU profiling. More...
 
bool _heap_profiling = false
 Memory profiling. More...
 
std::map< const RelationshipManager *, std::map< const MeshBase *, std::unique_ptr< RelationshipManager > > > _template_to_clones
 Map from a template relationship manager to a map in which the key-value pairs represent the MeshBase object and the clone of the template relationship manager, e.g. More...
 
std::map< std::type_index, std::unique_ptr< InterfaceRegistryObjectsBase > > _interface_registry
 Registration for interface objects. More...
 
std::unique_ptr< Backup > *const _initial_backup
 The backup for use in initial setup; this will get set from the _initial_backup input parameter that typically gets set from a MultiApp that has a backup This is a pointer to a pointer because at the time of construction of the app, the backup will not be filled yet. More...
 
const torch::DeviceType _libtorch_device
 The libtorch device this app is using (converted from compute_device) More...
 
std::shared_ptr< mfem::Device > _mfem_device
 The MFEM Device object. More...
 
std::set< std::string > _mfem_devices
 MFEM supported devices based on user-provided config. More...
 

Friends

class FEProblemBase
 
class Restartable
 
class SubProblem
 

Detailed Description

Base class for MOOSE-based applications.

This generic class for application provides:

Each application should register its own objects and register its own special syntax

Definition at line 96 of file MooseApp.h.

Member Enumeration Documentation

◆ RegistrationType

Enumeration for holding the valid types of dynamic registrations allowed.

Enumerator
APPLICATION 
REGALL 

Definition at line 1497 of file MooseApp.h.

1498  {
1499  APPLICATION,
1500  REGALL
1501  };

◆ UNUSED_CHECK

enum MooseApp::UNUSED_CHECK
protected

Indicates whether warnings, errors, or no output is displayed when unused parameters are detected.

Enumerator
OFF 
WARN_UNUSED 
ERROR_UNUSED 

Definition at line 1243 of file MooseApp.h.

1244  {
1245  OFF,
1246  WARN_UNUSED,
1247  ERROR_UNUSED
enum MooseApp::UNUSED_CHECK _enable_unused_check

Constructor & Destructor Documentation

◆ ~MooseApp()

MooseApp::~MooseApp ( )
virtual

Definition at line 1180 of file MooseApp.C.

1181 {
1182 #ifdef HAVE_GPERFTOOLS
1183  // CPU profiling stop
1184  if (_cpu_profiling)
1185  ProfilerStop();
1186  // Heap profiling stop
1187  if (_heap_profiling)
1188  HeapProfilerStop();
1189 #endif
1191  _the_warehouse.reset();
1192  _executioner.reset();
1193 
1194  // Don't wait for implicit destruction of input parameter storage
1196 
1197  // This is dirty, but I don't know what else to do. Obviously, others
1198  // have had similar problems if you look above. In specific, the
1199  // dlclose below on macs is destructing some data that does not
1200  // belong to it in garbage collection. So... don't even give
1201  // dlclose an option
1202  _restartable_data.clear();
1203 
1204  // Remove this app's parameters from the AppFactory. This allows
1205  // for creating an app with this name again in the same execution,
1206  // which needs to be done when resetting applications in MultiApp
1208 
1209 #ifdef LIBMESH_HAVE_DLOPEN
1210  // Close any open dynamic libraries
1211  for (const auto & lib_pair : _lib_handles)
1212  dlclose(lib_pair.second.library_handle);
1213 #endif
1214 }
std::unique_ptr< TheWarehouse > _the_warehouse
The combined warehouse for storing any MooseObject based object.
Definition: MooseApp.h:1504
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:127
ActionWarehouse _action_warehouse
Where built actions are stored.
Definition: MooseApp.h:1176
std::vector< RestartableDataMap > _restartable_data
Where the restartable data is held (indexed on tid)
Definition: MooseApp.h:1194
void clearAppParams(const InputParameters &params, const ClearAppParamsKey)
Clears the stored parameters for the given application parameteres.
Definition: AppFactory.C:51
std::shared_ptr< Executioner > _executioner
Pointer to the executioner of this run (typically build by actions)
Definition: MooseApp.h:1212
bool _heap_profiling
Memory profiling.
Definition: MooseApp.h:1548
std::unordered_map< std::string, DynamicLibraryInfo > _lib_handles
The library archive (name only), registration method and the handle to the method.
Definition: MooseApp.h:1323
static AppFactory & instance()
Get the instance of the AppFactory.
Definition: AppFactory.C:18
bool _cpu_profiling
CPU profiling.
Definition: MooseApp.h:1545
std::unique_ptr< InputParameterWarehouse > _input_parameter_warehouse
Input parameter storage structure; unique_ptr so we can control its destruction order.
Definition: MooseApp.h:1170
void clear()
This method deletes all of the Actions in the warehouse.

◆ MooseApp()

MooseApp::MooseApp ( const InputParameters parameters)
protected

Constructor is protected so that this object is constructed through the AppFactory object.

Definition at line 439 of file MooseApp.C.

440  : PerfGraphInterface(*this, "MooseApp"),
441  ParallelObject(*parameters.get<std::shared_ptr<Parallel::Communicator>>(
442  "_comm")), // Can't call getParam() before pars is set
443  // The use of AppFactory::getAppParams() is atrocious. However, a long time ago
444  // we decided to copy construct parameters in each derived application...
445  // which means that the "parameters" we get if someone derives from MooseApp are
446  // actually a copy of the ones built by the factory. Because we have unique
447  // application names, this allows us to reference (using _pars and MooseBase)
448  // the actual const parameters that the AppFactory made for this application
449  MooseBase(*this, AppFactory::instance().getAppParams(parameters)),
450  _comm(getParam<std::shared_ptr<Parallel::Communicator>>("_comm")),
451  _file_base_set_by_user(false),
452  _output_position_set(false),
453  _start_time_set(false),
454  _start_time(0.0),
455  _global_time_offset(0.0),
456  _input_parameter_warehouse(std::make_unique<InputParameterWarehouse>()),
457  _action_factory(*this),
459  _output_warehouse(*this),
460  _parser(getCheckedPointerParam<std::shared_ptr<Parser>>("_parser")),
461  _command_line(getCheckedPointerParam<std::shared_ptr<CommandLine>>("_command_line")),
467  _use_executor(getParam<bool>("use_executor")),
468  _null_executor(NULL),
469  _use_nonlinear(true),
470  _use_eigen_value(false),
472  _factory(*this),
473  _error_overridden(false),
474  _early_exit_param(""),
475  _ready_to_exit(false),
476  _exit_code(0),
477  _initial_from_file(false),
479  _recover(false),
480  _restart(false),
481  _split_mesh(false),
482  _use_split(getParam<bool>("use_split")),
483  _force_restart(getParam<bool>("force_restart")),
484 #ifdef DEBUG
485  _trap_fpe(true),
486 #else
487  _trap_fpe(false),
488 #endif
489  _test_checkpoint_half_transient(parameters.get<bool>("test_checkpoint_half_transient")),
490  _test_restep(parameters.get<bool>("test_restep")),
491  _check_input(getParam<bool>("check_input")),
492  _multiapp_level(isParamValid("_multiapp_level") ? getParam<unsigned int>("_multiapp_level")
493  : 0),
494  _multiapp_number(isParamValid("_multiapp_number") ? getParam<unsigned int>("_multiapp_number")
495  : 0),
496  _use_master_mesh(getParam<bool>("_use_master_mesh")),
497  _master_mesh(isParamValid("_master_mesh") ? getParam<const MooseMesh *>("_master_mesh")
498  : nullptr),
499  _master_displaced_mesh(isParamValid("_master_displaced_mesh")
500  ? getParam<const MooseMesh *>("_master_displaced_mesh")
501  : nullptr),
502  _mesh_generator_system(*this),
503  _chain_control_system(*this),
506  _output_buffer_cache(nullptr),
507  _automatic_automatic_scaling(getParam<bool>("automatic_automatic_scaling")),
508  _initial_backup(getParam<std::unique_ptr<Backup> *>("_initial_backup"))
509 #ifdef MOOSE_LIBTORCH_ENABLED
510  ,
511  _libtorch_device(determineLibtorchDeviceType(getParam<MooseEnum>("compute_device")))
512 #endif
513 #ifdef MOOSE_MFEM_ENABLED
514  ,
515  _mfem_device(isParamValid("_mfem_device")
516  ? getParam<std::shared_ptr<mfem::Device>>("_mfem_device")
517  : nullptr),
518  _mfem_devices(isParamValid("_mfem_devices") ? getParam<std::set<std::string>>("_mfem_devices")
519  : std::set<std::string>{})
520 #endif
521 {
522  if (&parameters != &_pars)
523  {
524  const auto show_trace = Moose::show_trace;
525  Moose::show_trace = false;
526  const std::string bad_params = "(InputParameters parameters)";
527  const std::string good_params = "(const InputParameters & parameters)";
528  const std::string source_constructor = type() + "::" + type();
529  mooseDoOnce(mooseDeprecated(type(),
530  " copy-constructs its input parameters.\n\n",
531  "This is deprecated and will not be allowed in the future.\n\n",
532  "In ",
533  type(),
534  ".C, change:\n ",
535  source_constructor,
536  bad_params,
537  " -> ",
538  source_constructor,
539  good_params,
540  "\n\n",
541  "In ",
542  type(),
543  ".h, change:\n ",
544  type(),
545  bad_params,
546  "; -> ",
547  type(),
548  good_params,
549  ";"));
551  }
552 
553  mooseAssert(_command_line->hasParsed(), "Command line has not parsed");
554  mooseAssert(_parser->queryRoot() && _parser->queryCommandLineRoot(), "Parser has not parsed");
555 
556  // Set the TIMPI sync type via --timpi-sync
557  const auto & timpi_sync = getParam<std::string>("timpi_sync");
558  const_cast<Parallel::Communicator &>(comm()).sync_type(timpi_sync);
559 
560 #ifdef HAVE_GPERFTOOLS
561  if (isUltimateMaster())
562  {
563  bool has_cpu_profiling = false;
564  bool has_heap_profiling = false;
565  static std::string cpu_profile_file;
566  static std::string heap_profile_file;
567 
568  // For CPU profiling, users need to have environment 'MOOSE_PROFILE_BASE'
569  if (std::getenv("MOOSE_PROFILE_BASE"))
570  {
571  has_cpu_profiling = true;
572  cpu_profile_file =
573  std::getenv("MOOSE_PROFILE_BASE") + std::to_string(_comm->rank()) + ".prof";
574  // create directory if needed
575  auto name = MooseUtils::splitFileName(cpu_profile_file);
576  if (!name.first.empty())
577  {
578  if (processor_id() == 0)
579  MooseUtils::makedirs(name.first.c_str());
580  _comm->barrier();
581  }
582  }
583 
584  // For Heap profiling, users need to have 'MOOSE_HEAP_BASE'
585  if (std::getenv("MOOSE_HEAP_BASE"))
586  {
587  has_heap_profiling = true;
588  heap_profile_file = std::getenv("MOOSE_HEAP_BASE") + std::to_string(_comm->rank());
589  // create directory if needed
590  auto name = MooseUtils::splitFileName(heap_profile_file);
591  if (!name.first.empty())
592  {
593  if (processor_id() == 0)
594  MooseUtils::makedirs(name.first.c_str());
595  _comm->barrier();
596  }
597  }
598 
599  // turn on profiling only on selected ranks
600  if (isParamSetByUser("gperf_profiler_on"))
601  {
602  auto rankstr = getParam<std::string>("gperf_profiler_on");
603  std::vector<processor_id_type> ranks;
604  bool success = MooseUtils::tokenizeAndConvert(rankstr, ranks, ", ");
605  if (!success)
606  mooseError("Invalid argument for --gperf-profiler-on: '", rankstr, "'");
607  for (auto & rank : ranks)
608  {
609  if (rank >= _comm->size())
610  mooseError("Invalid argument for --gperf-profiler-on: ",
611  rank,
612  " is greater than or equal to ",
613  _comm->size());
614  if (rank == _comm->rank())
615  {
616  _cpu_profiling = has_cpu_profiling;
617  _heap_profiling = has_heap_profiling;
618  }
619  }
620  }
621  else
622  {
623  _cpu_profiling = has_cpu_profiling;
624  _heap_profiling = has_heap_profiling;
625  }
626 
627  if (_cpu_profiling)
628  if (!ProfilerStart(cpu_profile_file.c_str()))
629  mooseError("CPU profiler is not started properly");
630 
631  if (_heap_profiling)
632  {
633  HeapProfilerStart(heap_profile_file.c_str());
634  if (!IsHeapProfilerRunning())
635  mooseError("Heap profiler is not started properly");
636  }
637  }
638 #else
639  if (std::getenv("MOOSE_PROFILE_BASE") || std::getenv("MOOSE_HEAP_BASE"))
640  mooseError("gperftool is not available for CPU or heap profiling");
641 #endif
642 
643  // If this will be a language server then turn off output until that starts
644  if (isParamValid("language_server") && getParam<bool>("language_server"))
645  _output_buffer_cache = Moose::out.rdbuf(nullptr);
646 
649 
650  _the_warehouse = std::make_unique<TheWarehouse>();
651  _the_warehouse->registerAttribute<AttribMatrixTags>("matrix_tags", 0);
652  _the_warehouse->registerAttribute<AttribVectorTags>("vector_tags", 0);
653  _the_warehouse->registerAttribute<AttribExecOns>("exec_ons", 0);
654  _the_warehouse->registerAttribute<AttribSubdomains>("subdomains", 0);
655  _the_warehouse->registerAttribute<AttribBoundaries>("boundaries", 0);
656  _the_warehouse->registerAttribute<AttribThread>("thread", 0);
657  _the_warehouse->registerAttribute<AttribExecutionOrderGroup>("execution_order_group", 0);
658  _the_warehouse->registerAttribute<AttribPreIC>("pre_ic", 0);
659  _the_warehouse->registerAttribute<AttribPreAux>("pre_aux");
660  _the_warehouse->registerAttribute<AttribPostAux>("post_aux");
661  _the_warehouse->registerAttribute<AttribName>("name", "dummy");
662  _the_warehouse->registerAttribute<AttribSystem>("system", "dummy");
663  _the_warehouse->registerAttribute<AttribVar>("variable", -1);
664  _the_warehouse->registerAttribute<AttribInterfaces>("interfaces", 0);
665  _the_warehouse->registerAttribute<AttribSysNum>("sys_num", libMesh::invalid_uint);
666  _the_warehouse->registerAttribute<AttribResidualObject>("residual_object");
667  _the_warehouse->registerAttribute<AttribSorted>("sorted");
668  _the_warehouse->registerAttribute<AttribDisplaced>("displaced", -1);
669 
671 
672  if (_check_input && isParamSetByUser("recover"))
673  mooseError("Cannot run --check-input with --recover. Recover files might not exist");
674 
675  if (isParamSetByUser("start_in_debugger") && isUltimateMaster())
676  {
677  auto command = getParam<std::string>("start_in_debugger");
678 
679  Moose::out << "Starting in debugger using: " << command << std::endl;
680 
682 
683  std::stringstream command_stream;
684 
685  // This will start XTerm and print out some info first... then run the debugger
686  command_stream << "xterm -e \"echo 'Rank: " << processor_id() << " Hostname: " << hostname
687  << " PID: " << getpid() << "'; echo ''; ";
688 
689  // Figure out how to run the debugger
690  if (command.find("lldb") != std::string::npos || command.find("gdb") != std::string::npos)
691  command_stream << command << " -p " << getpid();
692  else
693  mooseError("Unknown debugger: ",
694  command,
695  "\nIf this is truly what you meant then contact moose-users to have a discussion "
696  "about adding your debugger.");
697 
698  // Finish up the command
699  command_stream << "\""
700  << " & ";
701  std::string command_string = command_stream.str();
702  Moose::out << "Running: " << command_string << std::endl;
703 
704  int ret = std::system(command_string.c_str());
705  libmesh_ignore(ret);
706 
707  // Sleep to allow time for the debugger to attach
708  std::this_thread::sleep_for(std::chrono::seconds(10));
709  }
710 
711  if (isParamSetByUser("stop_for_debugger") && isUltimateMaster())
712  {
713  Moose::out << "\nStopping for " << getParam<unsigned int>("stop_for_debugger")
714  << " seconds to allow attachment from a debugger.\n";
715 
716  Moose::out << "\nAll of the processes you can connect to:\n";
717  Moose::out << "rank - hostname - pid\n";
718 
720 
721  {
722  // The 'false' turns off the serialization warning
723  SerializerGuard sg(_communicator, false); // Guarantees that the processors print in order
724  Moose::err << processor_id() << " - " << hostname << " - " << getpid() << "\n";
725  }
726 
727  Moose::out << "\nWaiting...\n" << std::endl;
728 
729  // Sleep to allow time for the debugger to attach
730  std::this_thread::sleep_for(std::chrono::seconds(getParam<unsigned int>("stop_for_debugger")));
731  }
732 
734  mooseError("Mesh can be passed in only for sub-apps");
735 
737  mooseError("_master_mesh should have been set when _master_displaced_mesh is set");
738 
739 #ifdef MOOSE_MFEM_ENABLED
740  if (_mfem_device)
741  {
742  mooseAssert(!isUltimateMaster(),
743  "The MFEM device should only be auto-set for sub-applications");
744  mooseAssert(!_mfem_devices.empty(),
745  "If we are a sub-application and we have an MFEM device object, then we must know "
746  "its configuration string");
747  }
748 #endif
749 
750  // Data specifically associated with the mesh (meta-data) that will read from the restart
751  // file early during the simulation setup so that they are available to Actions and other objects
752  // that need them during the setup process. Most of the restartable data isn't made available
753  // until all objects have been created and all Actions have been executed (i.e. initialSetup).
755 
756  if (_pars.have_parameter<bool>("use_legacy_dirichlet_bc"))
757  mooseDeprecated("The parameter 'use_legacy_dirichlet_bc' is no longer valid.\n\n",
758  "All Dirichlet boundary conditions are preset by default.\n\n",
759  "Remove said parameter in ",
760  name(),
761  " to remove this deprecation warning.");
762 
764  mooseError("Cannot use --test-restep and --test-checkpoint-half-transient together");
765 
767 
768  Moose::out << std::flush;
769 }
770 
771 std::optional<MooseEnum>
773 {
774  if (isParamSetByUser("compute_device"))
775  return getParam<MooseEnum>("compute_device");
776  return {};
777 }
778 
779 void
781 {
782  // helper lambdas
783  auto haveCapability = [](const std::string & capability, const std::string & doc)
784  { addCapability(capability, true, doc + " is available."); };
785 
786  auto missingCapability =
787  [](const std::string & capability, const std::string & doc, const std::string & help = "")
788  { addCapability(capability, false, doc + " is not available. " + help); };
789 
790  auto haveCapabilityVersion =
791  [](const std::string & capability, const std::string & doc, const std::string & version)
792  { addCapability(capability, version, doc + " version " + version + " is available."); };
793 
794  auto petscMissingCapability = [](const std::string & capability, const std::string & doc)
795  {
797  capability, false, doc + " is not available. Check your PETSc configure options.");
798  };
799 
800  auto libmeshMissingCapability =
801  [](const std::string & capability, const std::string & doc, const std::string & config_option)
802  {
803  addCapability(capability,
804  false,
805  doc + " is not available. It is controlled by the `" + config_option +
806  "` libMesh configure option.");
807  };
808 
809  // register capabilities
810  if (_trap_fpe)
811  addCapability("trap_fpe",
812  true,
813  "Trapping floating point exceptions is enabled (in debug mode this "
814  "can be disabled using the --no-trap-fpe option).");
815  else
816  addCapability("trap_fpe",
817  false,
818  "Trapping floating point exceptions is not enabled (enable them using "
819  "the --trap-fpe option or by running a debug mode executable).");
820 
821  {
822  const auto doc = "LibTorch machine learning and parallel tensor algebra library";
823 #ifdef MOOSE_LIBTORCH_ENABLED
824  addCapability("libtorch", TORCH_VERSION, doc);
825 #else
826  missingCapability("libtorch",
827  doc,
828  "Check "
829  "https://mooseframework.inl.gov/moose/getting_started/installation/"
830  "install_libtorch.html for "
831  "instructions on how to configure and build moose with libTorch.");
832 #endif
833  }
834 
835  {
836  const auto doc = "MFEM finite element library";
837 #ifdef MOOSE_MFEM_ENABLED
838  haveCapability("mfem", doc);
839 #else
840  missingCapability("mfem",
841  doc,
842  "Install mfem using the scripts/update_and_rebuild_mfem.sh script after "
843  "first running scripts/update_and_rebuild_conduit.sh. Finally, configure "
844  "moose with ./configure --with-mfem");
845 #endif
846  }
847 
848  {
849  const auto doc = "New Engineering Material model Library, version 2";
850 #ifdef NEML2_ENABLED
851  haveCapability("neml2", doc);
852 #else
853  missingCapability("neml2",
854  doc,
855  "Install neml2 using the scripts/update_and_rebuild_neml2.sh script, then "
856  "configure moose with ./configure --with-neml2 --with-libtorch");
857 #endif
858  }
859 
860  {
861  const auto doc = "gperftools code performance analysis and profiling library";
862 #ifdef HAVE_GPERFTOOLS
863  haveCapability("gperftools", doc);
864 #else
865  missingCapability("gperftools",
866  doc,
867  "Check https://mooseframework.inl.gov/application_development/profiling.html "
868  "for instructions on profiling MOOSE based applications.");
869 #endif
870  }
871 
872  {
873  const auto doc = "libPNG portable network graphics format library";
874 #ifdef MOOSE_HAVE_LIBPNG
875  haveCapability("libpng", doc);
876 #else
877  missingCapability("libpng",
878  doc,
879  "Install libpng through conda or your distribution and check that it gets "
880  "detected through pkg-config, then reconfigure and rebuild MOOSE.");
881 #endif
882  }
883 
884  {
885  const auto doc = "NVIDIA GPU parallel computing platform";
886 #ifdef PETSC_HAVE_CUDA
887  haveCapability("cuda", doc);
888 #else
889  missingCapability("cuda", doc, "Add the CUDA bin directory to your path and rebuild PETSc.");
890 #endif
891  }
892 
894  "ad_size",
895  MOOSE_AD_MAX_DOFS_PER_ELEM,
896  "MOOSE was configured and built with a dual number backing store size of " +
897  Moose::stringify(MOOSE_AD_MAX_DOFS_PER_ELEM) +
898  ". Complex simulations with many variables or contact problems may require larger "
899  "values. Reconfigure MOOSE with the --with-derivative-size=<n> option in the root of the "
900  "repository.");
901  {
902  const std::string method = QUOTE(METHOD);
903  addCapability("method", method, "The executable was built with METHOD=\"" + method + "\"");
904  }
905 
906  {
907  const std::string version = QUOTE(LIBMESH_DETECTED_PETSC_VERSION_MAJOR) "." QUOTE(
908  LIBMESH_DETECTED_PETSC_VERSION_MINOR) "." QUOTE(LIBMESH_DETECTED_PETSC_VERSION_SUBMINOR);
909  addCapability("petsc", version, "Using PETSc version " + version + ".");
910  }
911 
912 #ifdef LIBMESH_PETSC_USE_DEBUG
913  addCapability("petsc_debug", true, "PETSc was built with debugging options.");
914 #else
915  addCapability("petsc_debug", false, "PETSc was built without debugging options.");
916 #endif
917 
918  {
919  const auto doc = "SuperLU direct solver";
920 #ifdef LIBMESH_PETSC_HAVE_SUPERLU_DIST
921  haveCapability("superlu", doc);
922 #else
923  petscMissingCapability("superlu", doc);
924 #endif
925  }
926 
927  {
928  const auto doc = "MUltifrontal Massively Parallel sparse direct Solver (MUMPS)";
929 #ifdef LIBMESH_PETSC_HAVE_MUMPS
930  haveCapability("mumps", doc);
931 #else
932  petscMissingCapability("mumps", doc);
933 #endif
934  }
935 
936  {
937  const auto doc = "STRUMPACK - STRUctured Matrix PACKage solver library";
938 #ifdef LIBMESH_PETSC_HAVE_STRUMPACK
939  haveCapability("strumpack", doc);
940 #else
941  petscMissingCapability("strumpack", doc);
942 #endif
943  }
944 
945  {
946  const auto doc = "Parmetis partitioning library";
947 #if defined(LIBMESH_PETSC_HAVE_PARMETIS) || defined(LIBMESH_HAVE_PARMETIS)
948  haveCapability("parmetis", doc);
949 #else
950  petscMissingCapability("parmetis", doc);
951 #endif
952  }
953 
954  {
955  const auto doc = "Chaco graph partitioning library";
956 #ifdef LIBMESH_PETSC_HAVE_CHACO
957  haveCapability("chaco", doc);
958 #else
959  petscMissingCapability("chaco", doc);
960 #endif
961  }
962 
963  {
964  const auto doc = "Party matrix or graph partitioning library";
965 #ifdef LIBMESH_PETSC_HAVE_PARTY
966  haveCapability("party", doc);
967 #else
968  petscMissingCapability("party", doc);
969 #endif
970  }
971 
972  {
973  const auto doc = "PT-Scotch graph partitioning library";
974 #ifdef LIBMESH_PETSC_HAVE_PTSCOTCH
975  haveCapability("ptscotch", doc);
976 #else
977  petscMissingCapability("ptscotch", doc);
978 #endif
979  }
980 
981  {
982  const auto doc = "Scalable Library for Eigenvalue Problem Computations (SLEPc)";
983 #ifdef LIBMESH_HAVE_SLEPC
984  const auto version = QUOTE(LIBMESH_DETECTED_SLEPC_VERSION_MAJOR) "." QUOTE(
985  LIBMESH_DETECTED_SLEPC_VERSION_MINOR) "." QUOTE(LIBMESH_DETECTED_SLEPC_VERSION_SUBMINOR);
986  haveCapabilityVersion("slepc", doc, version);
987 #else
988  petscMissingCapability("slepc", doc);
989 #endif
990  }
991 
992  {
993  const auto doc = "Exodus mesh file format library";
994 #ifdef LIBMESH_HAVE_EXODUS_API
995  const std::string version = QUOTE(LIBMESH_DETECTED_EXODUS_VERSION_MAJOR) "." QUOTE(
996  LIBMESH_DETECTED_EXODUS_VERSION_MINOR);
997  haveCapabilityVersion("exodus", doc, version);
998 #else
999  libmeshMissingCapability("exodus", doc, "--enable-exodus");
1000 #endif
1001  }
1002 
1003  {
1004  const auto doc = "Netgen meshing library";
1005 #ifdef LIBMESH_HAVE_NETGEN
1006  haveCapability("netgen", doc);
1007 #else
1008  libmeshMissingCapability("netgen", doc, "--enable-netgen");
1009 #endif
1010  }
1011 
1012  {
1013  const auto doc = "Visualization Toolkit (VTK)";
1014 #ifdef LIBMESH_HAVE_VTK
1015  const std::string version = QUOTE(LIBMESH_DETECTED_VTK_VERSION_MAJOR) "." QUOTE(
1016  LIBMESH_DETECTED_VTK_VERSION_MINOR) "." QUOTE(LIBMESH_DETECTED_VTK_VERSION_SUBMINOR);
1017  haveCapabilityVersion("vtk", doc, version);
1018 #else
1019  libmeshMissingCapability("vtk", doc, "--disable-vtk and --enable-vtk-required");
1020 #endif
1021  }
1022 
1023  {
1024  const auto doc = "libcurl - the multiprotocol file transfer library";
1025 #ifdef LIBMESH_HAVE_CURL
1026  haveCapability("curl", doc);
1027 #else
1028  libmeshMissingCapability("curl", doc, "--enable-curl");
1029 #endif
1030  }
1031 
1032  {
1033  const auto doc = "Tecplot post-processing tools API";
1034 #ifdef LIBMESH_HAVE_TECPLOT_API
1035  haveCapability("tecplot", doc);
1036 #else
1037  libmeshMissingCapability("tecplot", doc, "--enable-tecplot");
1038 #endif
1039  }
1040 
1041  {
1042  const auto doc = "Boost C++ library";
1043 #ifdef LIBMESH_HAVE_EXTERNAL_BOOST
1044  haveCapability("boost", doc);
1045 #else
1046  libmeshMissingCapability("boost", doc, "--with-boost");
1047 #endif
1048  }
1049 
1050  // libmesh stuff
1051  {
1052  const auto doc = "Adaptive mesh refinement";
1053 #ifdef LIBMESH_ENABLE_AMR
1054  haveCapability("amr", doc);
1055 #else
1056  libmeshMissingCapability("amr", doc, "--disable-amr");
1057 #endif
1058  }
1059 
1060  {
1061  const auto doc = "nanoflann library for Nearest Neighbor (NN) search with KD-trees";
1062 #ifdef LIBMESH_HAVE_NANOFLANN
1063  haveCapability("nanoflann", doc);
1064 #else
1065  libmeshMissingCapability("nanoflann", doc, "--disable-nanoflann");
1066 #endif
1067  }
1068 
1069  {
1070  const auto doc = "sfcurves library for space filling curves (required by geometric "
1071  "partitioners such as SFCurves, Hilbert and Morton - not LGPL compatible)";
1072 #ifdef LIBMESH_HAVE_SFCURVES
1073  haveCapability("sfcurves", doc);
1074 #else
1075  libmeshMissingCapability("sfcurves", doc, "--disable-sfc");
1076 #endif
1077  }
1078 
1079 #ifdef LIBMESH_HAVE_FPARSER
1080 #ifdef LIBMESH_HAVE_FPARSER_JIT
1081  addCapability("fparser", "jit", "FParser enabled with just in time compilation support.");
1082 #else
1083  addCapability("fparser", "byte_code", "FParser enabled.");
1084 #endif
1085 #else
1086  addCapability("fparser",
1087  false,
1088  "FParser is disabled, libMesh was likely configured with --disable-fparser.");
1089 #endif
1090 
1091 #ifdef LIBMESH_HAVE_DLOPEN
1092  addCapability(
1093  "dlopen", true, "The dlopen() system call is available to dynamically load libraries.");
1094 #else
1095  addCapability("dlopen",
1096  false,
1097  "The dlopen() system call is not available. Dynamic library loading is "
1098  "not supported on this system.");
1099 #endif
1100 
1101  {
1102  const auto doc = "LibMesh support for threaded execution";
1103 #ifdef LIBMESH_USING_THREADS
1104  haveCapability("threads", doc);
1105 #else
1106  libmeshMissingCapability("threads", doc, "--with-thread-model=tbb,pthread,openmp,auto,none");
1107 #endif
1108  }
1109 
1110  {
1111  const auto doc = "OpenMP multi-platform shared-memory parallel programming API";
1112 #ifdef LIBMESH_HAVE_OPENMP
1113  haveCapability("openmp", doc);
1114 #else
1115  libmeshMissingCapability("openmp", doc, "--with-thread-model=tbb,pthread,openmp,auto,none");
1116 #endif
1117  }
1118  {
1119  const auto doc = "oneAPI Threading Building Blocks (TBB) API";
1120 #ifdef LIBMESH_HAVE_TBB_API
1121  haveCapability("tbb", doc);
1122 #else
1123  libmeshMissingCapability("tbb", doc, "--with-thread-model=tbb,pthread,openmp,auto,none");
1124 #endif
1125  }
1126 
1127  {
1128  const auto doc = "libMesh unique ID support";
1129 #ifdef LIBMESH_ENABLE_UNIQUE_ID
1130  haveCapability("unique_id", doc);
1131 #else
1132  libmeshMissingCapability("unique_id", doc, "--enable-unique-id");
1133 #endif
1134  }
1135 
1136  {
1137  const auto doc = "libMesh default mesh mode";
1138 #ifdef LIBMESH_ENABLE_PARMESH
1139  addCapability("mesh_mode", "distributed", doc);
1140 #else
1141  addCapability("mesh_mode", "replicated", doc);
1142 #endif
1143  }
1144 
1145  addCapability("dof_id_bytes",
1146  static_cast<int>(sizeof(dof_id_type)),
1147  "Degree of freedom (DOF) identifiers use " + Moose::stringify(sizeof(dof_id_type)) +
1148  " bytes for storage. This is controlled by the "
1149  "--with-dof-id-bytes=<1|2|4|8> libMesh configure option.");
1150 
1151  // compiler
1152  {
1153  const auto doc = "Compiler used to build the MOOSE framework.";
1154 #if defined(__clang__)
1155  addCapability("compiler", "clang", doc);
1156 #elif defined(__GNUC__) || defined(__GNUG__)
1157  addCapability("compiler", "gcc", doc);
1158 #elif defined(_MSC_VER)
1159  addCapability("compiler", "msvc", doc);
1160 #else
1161  addCapability("compiler", false, "Unknown compiler");
1162 #endif
1163  }
1164 
1165  // OS related
1166  {
1167  const auto doc = "Operating system this executable is running on.";
1168 #ifdef __APPLE__
1169  addCapability("platform", "darwin", doc);
1170 #elif __WIN32__
1171  addCapability("platform", "win32", doc);
1172 #elif __linux__
1173  addCapability("platform", "linux", doc);
1174 #elif __unix__ // all unices not caught above
1175  addCapability("platform", "unix", doc);
1176 #endif
1177  }
1178 }
ParallelObject(const Parallel::Communicator &comm_in)
bool _use_eigen_value
Boolean to indicate whether to use an eigenvalue executioner.
Definition: MooseApp.h:1240
unsigned int _multiapp_level
Level of multiapp, the master is level 0. This used by the Console to indent output.
Definition: MooseApp.h:1507
PerfGraph & _perf_graph
The PerfGraph object for this application (recoverable)
Definition: MooseApp.h:1203
bool show_trace
Set to true (the default) to print the stack trace with error and warning messages - false to omit it...
Definition: Moose.C:783
const std::string _type
The string representation of the type of this object as registered (see registerApp(AppName)) ...
Definition: MooseApp.h:1139
bool isUltimateMaster() const
Whether or not this app is the ultimate master app.
Definition: MooseApp.h:813
bool _initial_from_file
This variable indicates when a request has been made to restart from an Exodus file.
Definition: MooseApp.h:1261
unsigned int n_threads()
const InputParameters & _pars
The object&#39;s parameters.
Definition: MooseBase.h:362
PerfGraph & createRecoverablePerfGraph()
Creates a recoverable PerfGraph.
Definition: MooseApp.C:3496
const unsigned int invalid_uint
void registerCapabilities()
Register all base MooseApp capabilities to the Moose::Capabilities registry.
const std::shared_ptr< Parser > _parser
Parser for parsing the input file (owns the root hit node)
Definition: MooseApp.h:1182
const T & getParam(const std::string &name) const
Retrieve a parameter for the object.
Definition: MooseBase.h:384
Real _global_time_offset
Offset of the local App time to the "global" problem time.
Definition: MooseApp.h:1163
torch::DeviceType determineLibtorchDeviceType(const MooseEnum &device) const
Function to determine the device which should be used by libtorch on this application.
Definition: MooseApp.C:3535
bool _file_base_set_by_user
Whether or not file base is set through input or setOutputFileBase by MultiApp.
Definition: MooseApp.h:1148
bool _output_position_set
Whether or not an output position has been set for this app.
Definition: MooseApp.h:1151
std::unique_ptr< TheWarehouse > _the_warehouse
The combined warehouse for storing any MooseObject based object.
Definition: MooseApp.h:1504
std::vector< std::pair< R1, R2 > > get(const std::string &param1, const std::string &param2) const
Combine two vector parameters into a single vector of pairs.
bool tokenizeAndConvert(const std::string &str, std::vector< T > &tokenized_vector, const std::string &delimiter=" \\\)
tokenizeAndConvert splits a string using delimiter and then converts to type T.
bool _use_nonlinear
Boolean to indicate whether to use a Nonlinear or EigenSystem (inspected by actions) ...
Definition: MooseApp.h:1237
static const RestartableDataMapName MESH_META_DATA
Definition: MooseApp.h:123
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:127
const bool _use_master_mesh
Whether to use the parent app mesh for this app.
Definition: MooseApp.h:1513
Real _start_time
The time at which to start the simulation.
Definition: MooseApp.h:1160
This attribute describes sorting state.
Definition: TheWarehouse.h:112
bool forceRestart() const
Whether or not we are forcefully restarting (allowing the load of potentially incompatibie checkpoint...
Definition: MooseApp.h:1061
const bool _use_split
Whether or not we are using a (pre-)split mesh (automatically DistributedMesh)
Definition: MooseApp.h:1279
std::pair< std::filesystem::path, std::filesystem::path > splitFileName(const T &full_file)
Function for splitting path and filename.
Definition: MooseUtils.h:261
bool _check_input
true if we want to just check the input file
Definition: MooseApp.h:1299
TODO: delete this later - it is a temporary hack for dealing with inter-system dependencies.
Definition: Attributes.h:313
const Parallel::Communicator & comm() const
std::set< std::string > _mfem_devices
MFEM supported devices based on user-provided config.
Definition: MooseApp.h:1575
Syntax _syntax
Syntax of the input file.
Definition: MooseApp.h:1166
const bool _test_restep
Whether or not this simulation should fail its middle timestep and repeat (for testing) ...
Definition: MooseApp.h:1293
bool _trap_fpe
Whether or not FPE trapping should be turned on.
Definition: MooseApp.h:1285
const Parallel::Communicator & _communicator
processor_id_type processor_id() const
Returns the MPI processor ID of the current processor.
Definition: MooseApp.h:404
ActionWarehouse _action_warehouse
Where built actions are stored.
Definition: MooseApp.h:1176
RestartableDataReader _rd_reader
Definition: MooseApp.h:1527
static ExecFlagRegistry & getExecFlagRegistry()
Return Singleton instance.
SolutionInvalidity & _solution_invalidity
The SolutionInvalidity object for this application.
Definition: MooseApp.h:1206
std::string hostname()
Get the hostname the current process is running on.
Definition: MooseUtils.C:620
std::optional< MooseEnum > getComputeDevice() const
Get the device accelerated computations are supposed to be running on.
std::vector< RestartableDataMap > _restartable_data
Where the restartable data is held (indexed on tid)
Definition: MooseApp.h:1194
const RankMap _rank_map
The RankMap is a useful object for determining how the processes are laid out on the physical hardwar...
Definition: MooseApp.h:1209
const bool _test_checkpoint_half_transient
Whether or not this simulation should only run half its transient (useful for testing recovery) ...
Definition: MooseApp.h:1291
int _exit_code
The exit code.
Definition: MooseApp.h:1258
T getCheckedPointerParam(const std::string &name, const std::string &error_string="") const
Verifies that the requested parameter exists and is not NULL and returns it to the caller...
Definition: MooseBase.h:428
TODO: delete this later - it is a temporary hack for dealing with inter-system dependencies.
Definition: Attributes.h:294
MeshGeneratorSystem _mesh_generator_system
The system that manages the MeshGenerators.
Definition: MooseApp.h:1522
bool _start_time_set
Whether or not an start time has been set.
Definition: MooseApp.h:1157
void libmesh_ignore(const Args &...)
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:99
std::shared_ptr< NullExecutor > _null_executor
Used to return an executor that does nothing.
Definition: MooseApp.h:1234
Tracks the libmesh system number that a MooseObject is associated with.
Definition: Attributes.h:275
bool _restart
Whether or not this is a restart run.
Definition: MooseApp.h:1273
void mooseDeprecated(Args &&... args) const
Definition: MooseBase.h:310
AttribBoundaries tracks all boundary IDs associated with an object.
Definition: Attributes.h:188
ActionFactory _action_factory
The Factory responsible for building Actions.
Definition: MooseApp.h:1173
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:89
enum MooseApp::UNUSED_CHECK _enable_unused_check
bool _recover
Whether or not this is a recovery run.
Definition: MooseApp.h:1270
const std::shared_ptr< CommandLine > _command_line
The CommandLine object.
Definition: MooseApp.h:1185
bool _error_overridden
Indicates whether warnings or errors are displayed when overridden parameters are detected...
Definition: MooseApp.h:1253
SolutionInvalidity & createRecoverableSolutionInvalidity()
Creates a recoverable SolutionInvalidity.
Definition: MooseApp.C:3514
bool _heap_profiling
Memory profiling.
Definition: MooseApp.h:1548
const MooseMesh *const _master_displaced_mesh
The displaced mesh from master app.
Definition: MooseApp.h:1519
TODO: delete this later - it is a temporary hack for dealing with inter-system dependencies.
Definition: Attributes.h:344
std::string stringify(const T &t)
conversion to string
Definition: Conversion.h:64
const bool _force_restart
Whether or not we are forcefully attempting to load checkpoints (–force-restart) ...
Definition: MooseApp.h:1282
static AppFactory & instance()
Get the instance of the AppFactory.
Definition: AppFactory.C:18
Residual objects have this attribute.
Definition: Attributes.h:411
bool have_parameter(std::string_view name) const
A wrapper around the Parameters base class method.
const ExecFlagEnum _execute_flags
Execution flags for this App.
Definition: MooseApp.h:1536
std::string help
void registerRestartableDataMapName(const RestartableDataMapName &name, std::string suffix="")
Reserve a location for storing custom RestartableDataMap objects.
Definition: MooseApp.C:3477
ChainControlDataSystem _chain_control_system
The system that manages the ChainControls.
Definition: MooseApp.h:1525
bool _distributed_mesh_on_command_line
This variable indicates that DistributedMesh should be used for the libMesh mesh underlying MooseMesh...
Definition: MooseApp.h:1267
Moose::Builder _builder
Builder for building app related parser tree.
Definition: MooseApp.h:1191
const torch::DeviceType _libtorch_device
The libtorch device this app is using (converted from compute_device)
Definition: MooseApp.h:1567
OutputWarehouse _output_warehouse
OutputWarehouse object for this App.
Definition: MooseApp.h:1179
std::streambuf * _output_buffer_cache
Cache output buffer so the language server can turn it off then back on.
Definition: MooseApp.h:1539
bool _cpu_profiling
CPU profiling.
Definition: MooseApp.h:1545
void registerAll(Factory &f, ActionFactory &af, Syntax &s)
Register objects that are in MOOSE.
Definition: Moose.C:67
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:267
static const std::string MESH_META_DATA_SUFFIX
Definition: MooseApp.h:124
const bool _automatic_automatic_scaling
Whether to turn on automatic scaling by default.
Definition: MooseApp.h:1542
Factory _factory
Definition: MooseApp.h:1250
std::unique_ptr< InputParameterWarehouse > _input_parameter_warehouse
Input parameter storage structure; unique_ptr so we can control its destruction order.
Definition: MooseApp.h:1170
Tracks whether the object is on the displaced mesh.
Definition: Attributes.h:481
static void addCapability(const std::string &capability, CapabilityUtils::Type value, const std::string &doc)
register a new capability
Definition: MooseApp.C:3595
void makedirs(const std::string &dir_name, bool throw_on_failure=false)
Recursively make directories.
Definition: MooseUtils.C:445
bool isParamValid(const std::string &name) const
Test if the supplied parameter is valid.
Definition: MooseBase.h:195
PerfGraphInterface(const MooseObject *moose_object)
For objects that are MooseObjects with a default prefix of type()
unsigned int _multiapp_number
Numbering in all the sub-apps on the same level.
Definition: MooseApp.h:1510
const std::shared_ptr< libMesh::Parallel::Communicator > _comm
The MPI communicator this App is going to use.
Definition: MooseApp.h:1142
std::shared_ptr< mfem::Device > _mfem_device
The MFEM Device object.
Definition: MooseApp.h:1572
bool _ready_to_exit
Definition: MooseApp.h:1256
const MooseMesh *const _master_mesh
The mesh from master app.
Definition: MooseApp.h:1516
bool isParamSetByUser(const std::string &name) const
Test if the supplied parameter is set by a user, as opposed to not set or set to default.
Definition: MooseBase.h:201
A scope guard that guarantees that whatever happens between when it gets created and when it is destr...
bool _split_mesh
Whether or not we are performing a split mesh operation (–split-mesh)
Definition: MooseApp.h:1276
const bool _use_executor
Indicates whether we are operating in the new/experimental executor mode instead of using the legacy ...
Definition: MooseApp.h:1231
void enableLivePrint()
Enables Live Print.
Definition: PerfGraph.C:57
static char addKnownLabel(const std::string &label)
addKnownLabel whitelists a label as valid for purposes of the checkLabels function.
Definition: Registry.C:84
MooseBase(const InputParameters &params)
Primary constructor for general objects.
Definition: MooseBase.C:48
uint8_t dof_id_type
std::string _early_exit_param
Indicates if simulation is ready to exit, and keeps track of which param caused it to exit...
Definition: MooseApp.h:1255
std::unique_ptr< Backup > *const _initial_backup
The backup for use in initial setup; this will get set from the _initial_backup input parameter that ...
Definition: MooseApp.h:1563

Member Function Documentation

◆ actionWarehouse() [1/2]

ActionWarehouse& MooseApp::actionWarehouse ( )
inline

◆ actionWarehouse() [2/2]

const ActionWarehouse& MooseApp::actionWarehouse ( ) const
inline

Return a const reference to the ActionWarehouse associated with this app.

Definition at line 208 of file MooseApp.h.

208 { return _action_warehouse; }
ActionWarehouse _action_warehouse
Where built actions are stored.
Definition: MooseApp.h:1176

◆ addAppParam()

void MooseApp::addAppParam ( InputParameters params)
static

Definition at line 95 of file MooseApp.C.

Referenced by AppFactory::createAppShared(), Moose::createMooseApp(), and validParams().

96 {
97  params.addCommandLineParam<std::string>(
98  "app_to_run", "--app <type>", "Specify the application type to run (case-sensitive)");
99 }
void addCommandLineParam(const std::string &name, const std::string &syntax, const std::string &doc_string)

◆ addCapability() [1/2]

void MooseApp::addCapability ( const std::string &  capability,
CapabilityUtils::Type  value,
const std::string &  doc 
)
staticprotected

register a new capability

Definition at line 3595 of file MooseApp.C.

3598 {
3599  checkReservedCapability(capability);
3600  Moose::Capabilities::getCapabilityRegistry().add(capability, value, doc);
3601 }
static Capabilities & getCapabilityRegistry()
Definition: Capabilities.C:22
static void checkReservedCapability(const std::string &capability)
Helper that reports an error if the given capability is reserved and should not be added via addCapab...
Definition: MooseApp.C:2366
void add(const std::string &capability, CapabilityUtils::Type value, const std::string &doc)
register a new capability
Definition: Capabilities.C:33

◆ addCapability() [2/2]

void MooseApp::addCapability ( const std::string &  capability,
const char *  value,
const std::string &  doc 
)
staticprotected

Definition at line 3604 of file MooseApp.C.

3605 {
3606  checkReservedCapability(capability);
3607  Moose::Capabilities::getCapabilityRegistry().add(capability, std::string(value), doc);
3608 }
static Capabilities & getCapabilityRegistry()
Definition: Capabilities.C:22
static void checkReservedCapability(const std::string &capability)
Helper that reports an error if the given capability is reserved and should not be added via addCapab...
Definition: MooseApp.C:2366
void add(const std::string &capability, CapabilityUtils::Type value, const std::string &doc)
register a new capability
Definition: Capabilities.C:33

◆ addExecutor()

void MooseApp::addExecutor ( const std::string &  type,
const std::string &  name,
const InputParameters params 
)

Definition at line 1967 of file MooseApp.C.

Referenced by recursivelyCreateExecutors().

1970 {
1971  std::shared_ptr<Executor> executor = _factory.create<Executor>(type, name, params);
1972 
1973  if (_executors.count(executor->name()) > 0)
1974  mooseError("an executor with name '", executor->name(), "' already exists");
1975  _executors[executor->name()] = executor;
1976 }
std::map< std::string, std::shared_ptr< Executor > > _executors
Pointers to all of the Executors for this run.
Definition: MooseApp.h:1218
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:99
virtual std::unique_ptr< Base > create()=0
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:89
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:267
Factory _factory
Definition: MooseApp.h:1250
The Executor class directs the execution flow of simulations.
Definition: Executor.h:26

◆ addExecutorParams()

void MooseApp::addExecutorParams ( const std::string &  type,
const std::string &  name,
const InputParameters params 
)

Adds the parameters for an Executor to the list of parameters.

This is done so that the Executors can be created in exactly the correct order.

Definition at line 1979 of file MooseApp.C.

Referenced by ReadExecutorParamsAction::act().

1982 {
1983  _executor_params[name] = std::make_pair(type, std::make_unique<InputParameters>(params));
1984 }
std::unordered_map< std::string, std::pair< std::string, std::unique_ptr< InputParameters > > > _executor_params
Used in building the Executors Maps the name of the Executor block to the <type, params> ...
Definition: MooseApp.h:1223
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:99
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:89

◆ addInputParam()

void MooseApp::addInputParam ( InputParameters params)
static

Definition at line 102 of file MooseApp.C.

Referenced by AppFactory::createAppShared(), Moose::createMooseApp(), and validParams().

103 {
104  params.addCommandLineParam<std::vector<std::string>>(
105  "input_file", "-i <input file(s)>", "Specify input file(s); multiple files are merged");
106 }
void addCommandLineParam(const std::string &name, const std::string &syntax, const std::string &doc_string)

◆ addMeshGenerator()

void MooseApp::addMeshGenerator ( const std::string &  type,
const std::string &  name,
const InputParameters params 
)
inline

Add a mesh generator that will act on the meshes in the system.

Parameters
typeThe type of MeshGenerator
nameThe name of the MeshGenerator
paramsThe params used to construct the MeshGenerator

See MeshGeneratorSystem::addMeshGenerator()

Definition at line 849 of file MooseApp.h.

Referenced by AddMeshGeneratorAction::act(), and MeshGenerator::addMeshSubgenerator().

852  {
854  }
void addMeshGenerator(const std::string &type, const std::string &name, const InputParameters &params)
Add a mesh generator that will act on the meshes in the system.
MeshGeneratorSystem _mesh_generator_system
The system that manages the MeshGenerators.
Definition: MooseApp.h:1522
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:99
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:89

◆ addRelationshipManager()

bool MooseApp::addRelationshipManager ( std::shared_ptr< RelationshipManager relationship_manager)

Transfers ownership of a RelationshipManager to the application for lifetime management.

The RelationshipManager will NOT be duplicately added if an equivalent RelationshipManager is already active. In that case, it's possible that the object will be destroyed if the reference count drops to zero.

Definition at line 3024 of file MooseApp.C.

Referenced by AdaptivityAction::act(), SetAdaptivityOptionsAction::act(), AddPeriodicBCAction::act(), CreateDisplacedProblemAction::addProxyRelationshipManagers(), Action::addRelationshipManager(), and FunctorSmootherTempl< T >::FunctorSmootherTempl().

3025 {
3026  // We prefer to always add geometric RMs. There is no hurt to add RMs for replicated mesh
3027  // since MeshBase::delete_remote_elements{} is a no-op (empty) for replicated mesh.
3028  // The motivation here is that MooseMesh::_use_distributed_mesh may not be properly set
3029  // at the time we are adding geometric relationship managers. We deleted the following
3030  // old logic to add all geometric RMs regardless of there is a distributed mesh or not.
3031  // Otherwise, all geometric RMs will be improperly ignored for a distributed mesh generator.
3032 
3033  // if (!_action_warehouse.mesh()->isDistributedMesh() && !_split_mesh &&
3034  // (relationship_manager->isType(Moose::RelationshipManagerType::GEOMETRIC) &&
3035  // !(relationship_manager->isType(Moose::RelationshipManagerType::ALGEBRAIC) ||
3036  // relationship_manager->isType(Moose::RelationshipManagerType::COUPLING))))
3037  // return false;
3038 
3039  bool add = true;
3040 
3041  std::set<std::shared_ptr<RelationshipManager>> rms_to_erase;
3042 
3043  for (const auto & existing_rm : _relationship_managers)
3044  {
3045  if (*existing_rm >= *new_rm)
3046  {
3047  add = false;
3048  donateForWhom(*new_rm, *existing_rm);
3049  break;
3050  }
3051  // The new rm did not provide less or the same amount/type of ghosting as the existing rm, but
3052  // what about the other way around?
3053  else if (*new_rm >= *existing_rm)
3054  rms_to_erase.emplace(existing_rm);
3055  }
3056 
3057  if (add)
3058  {
3059  _relationship_managers.emplace(new_rm);
3060  for (const auto & rm_to_erase : rms_to_erase)
3061  {
3062  donateForWhom(*rm_to_erase, *new_rm);
3063  removeRelationshipManager(rm_to_erase);
3064  }
3065  }
3066 
3067  // Inform the caller whether the object was added or not
3068  return add;
3069 }
void removeRelationshipManager(std::shared_ptr< RelationshipManager > relationship_manager)
Purge this relationship manager from meshes and DofMaps and finally from us.
Definition: MooseApp.C:3126
std::set< std::shared_ptr< RelationshipManager > > _relationship_managers
The relationship managers that have been added.
Definition: MooseApp.h:1302

◆ appBinaryName()

virtual std::string MooseApp::appBinaryName ( ) const
inlinevirtual

Definition at line 137 of file MooseApp.h.

Referenced by copyInputs(), run(), and runInputs().

138  {
140  name = name.substr(0, name.find_last_of("-"));
141  if (name.find_first_of("/") != std::string::npos)
142  name = name.substr(name.find_first_of("/") + 1, std::string::npos);
143  return name;
144  }
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:99
std::string getExecutableName()
Gets the name of the running executable on Mac OS X and linux.

◆ appendMeshGenerator()

const MeshGenerator& MooseApp::appendMeshGenerator ( const std::string &  type,
const std::string &  name,
InputParameters  params 
)
inline

Append a mesh generator that will act on the final mesh generator in the system.

Parameters
typeThe type of MeshGenerator
nameThe name of the MeshGenerator
paramsThe params used to construct the MeshGenerator

See MeshGeneratorSystem::appendMeshGenerator()

Definition at line 900 of file MooseApp.h.

901  {
903  }
const MeshGenerator & appendMeshGenerator(const std::string &type, const std::string &name, InputParameters params)
Append a mesh generator that will act on the current final mesh generator in the system.
MeshGeneratorSystem _mesh_generator_system
The system that manages the MeshGenerators.
Definition: MooseApp.h:1522
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:99
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:89

◆ appNameToLibName()

std::string MooseApp::appNameToLibName ( const std::string &  app_name) const

Converts an application name to a library name: Examples: AnimalApp -> libanimal-oprof.la (assuming METHOD=oprof) ThreeWordAnimalApp -> libthree_word_animal-dbg.la (assuming METHOD=dbg)

Definition at line 2454 of file MooseApp.C.

Referenced by dynamicAllRegistration(), and dynamicAppRegistration().

2455 {
2456  std::string library_name(app_name);
2457 
2458  // Strip off the App part (should always be the last 3 letters of the name)
2459  size_t pos = library_name.find("App");
2460  if (pos != library_name.length() - 3)
2461  mooseError("Invalid application name: ", library_name);
2462  library_name.erase(pos);
2463 
2464  // Now get rid of the camel case, prepend lib, and append the method and suffix
2465  return std::string("lib") + MooseUtils::camelCaseToUnderscore(library_name) + '-' +
2466  QUOTE(METHOD) + ".la";
2467 }
std::string camelCaseToUnderscore(const std::string &camel_case_name)
Function for converting a camel case name to a name containing underscores.
Definition: MooseUtils.C:564
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:267

◆ attachRelationshipManagers() [1/2]

void MooseApp::attachRelationshipManagers ( Moose::RelationshipManagerType  rm_type,
bool  attach_geometric_rm_final = false 
)

Attach the relationship managers of the given type Note: Geometric relationship managers that are supposed to be attached late will be attached when Algebraic are attached.

Definition at line 3237 of file MooseApp.C.

Referenced by AddRelationshipManager::act(), CouplingFunctorCheckAction::act(), and MooseMesh::buildTypedMesh().

3239 {
3240  for (auto & rm : _relationship_managers)
3241  {
3242  if (!rm->isType(rm_type))
3243  continue;
3244 
3245  // RM is already attached (this also handles the geometric early case)
3246  if (_attached_relationship_managers[rm_type].count(rm.get()))
3247  continue;
3248 
3250  {
3251  // The problem is not built yet - so the ActionWarehouse currently owns the mesh
3252  MooseMesh * const mesh = _action_warehouse.mesh().get();
3253 
3254  // "attach_geometric_rm_final = true" inidicate that it is the last chance to attach
3255  // geometric RMs. Therefore, we need to attach them.
3256  if (!rm->attachGeometricEarly() && !attach_geometric_rm_final)
3257  // Will attach them later (during algebraic). But also, we need to tell the mesh that we
3258  // shouldn't be deleting remote elements yet
3259  mesh->allowRemoteElementRemoval(false);
3260  else
3261  {
3262  MeshBase & undisp_mesh_base = mesh->getMesh();
3263  const DofMap * const undisp_sys_dof_map =
3264  _executioner ? &feProblem().getSolverSystem(0).dofMap() : nullptr;
3265  undisp_mesh_base.add_ghosting_functor(
3266  createRMFromTemplateAndInit(*rm, *mesh, undisp_mesh_base, undisp_sys_dof_map));
3267 
3268  // In the final stage, if there is a displaced mesh, we need to
3269  // clone ghosting functors for displacedMesh
3270  if (auto & disp_moose_mesh = _action_warehouse.displacedMesh();
3271  attach_geometric_rm_final && disp_moose_mesh)
3272  {
3273  MeshBase & disp_mesh_base = _action_warehouse.displacedMesh()->getMesh();
3274  const DofMap * disp_sys_dof_map = nullptr;
3275  if (_executioner && feProblem().getDisplacedProblem())
3276  disp_sys_dof_map = &feProblem().getDisplacedProblem()->solverSys(0).dofMap();
3277  disp_mesh_base.add_ghosting_functor(
3278  createRMFromTemplateAndInit(*rm, *disp_moose_mesh, disp_mesh_base, disp_sys_dof_map));
3279  }
3280  else if (_action_warehouse.displacedMesh())
3281  mooseError("The displaced mesh should not yet exist at the time that we are attaching "
3282  "early geometric relationship managers.");
3283 
3284  // Mark this RM as attached
3285  mooseAssert(!_attached_relationship_managers[rm_type].count(rm.get()), "Already attached");
3286  _attached_relationship_managers[rm_type].insert(rm.get());
3287  }
3288  }
3289  else // rm_type is algebraic or coupling
3290  {
3291  if (!_executioner && !_executor)
3292  mooseError("We must have an executioner by now or else we do not have to data to add "
3293  "algebraic or coupling functors to in MooseApp::attachRelationshipManagers");
3294 
3295  // Now we've built the problem, so we can use it
3296  auto & problem = feProblem();
3297  auto & undisp_moose_mesh = problem.mesh();
3298  auto & undisp_sys = feProblem().getSolverSystem(0);
3299  auto & undisp_sys_dof_map = undisp_sys.dofMap();
3300  auto & undisp_mesh = undisp_moose_mesh.getMesh();
3301 
3302  if (rm->useDisplacedMesh() && problem.getDisplacedProblem())
3303  {
3305  // We actually need to add this to the FEProblemBase NonlinearSystemBase's DofMap
3306  // because the DisplacedProblem "nonlinear" DisplacedSystem doesn't have any matrices
3307  // for which to do coupling. It's actually horrifying to me that we are adding a
3308  // coupling functor, that is going to determine its couplings based on a displaced
3309  // MeshBase object, to a System associated with the undisplaced MeshBase object (there
3310  // is only ever one EquationSystems object per MeshBase object and visa versa). So here
3311  // I'm left with the choice of whether to pass in a MeshBase object that is *not* the
3312  // MeshBase object that will actually determine the couplings or to pass in the MeshBase
3313  // object that is inconsistent with the System DofMap that we are adding the coupling
3314  // functor for! Let's err on the side of *libMesh* consistency and pass properly paired
3315  // MeshBase-DofMap
3316  problem.addCouplingGhostingFunctor(
3317  createRMFromTemplateAndInit(*rm, undisp_moose_mesh, undisp_mesh, &undisp_sys_dof_map),
3318  /*to_mesh = */ false);
3319 
3320  else if (rm_type == Moose::RelationshipManagerType::ALGEBRAIC)
3321  {
3322  auto & displaced_problem = *problem.getDisplacedProblem();
3323  auto & disp_moose_mesh = displaced_problem.mesh();
3324  auto & disp_mesh = disp_moose_mesh.getMesh();
3325  const DofMap * const disp_nl_dof_map = &displaced_problem.solverSys(0).dofMap();
3326  displaced_problem.addAlgebraicGhostingFunctor(
3327  createRMFromTemplateAndInit(*rm, disp_moose_mesh, disp_mesh, disp_nl_dof_map),
3328  /*to_mesh = */ false);
3329  }
3330  }
3331  else // undisplaced
3332  {
3334  problem.addCouplingGhostingFunctor(
3335  createRMFromTemplateAndInit(*rm, undisp_moose_mesh, undisp_mesh, &undisp_sys_dof_map),
3336  /*to_mesh = */ false);
3337 
3338  else if (rm_type == Moose::RelationshipManagerType::ALGEBRAIC)
3339  problem.addAlgebraicGhostingFunctor(
3340  createRMFromTemplateAndInit(*rm, undisp_moose_mesh, undisp_mesh, &undisp_sys_dof_map),
3341  /*to_mesh = */ false);
3342  }
3343 
3344  // Mark this RM as attached
3345  mooseAssert(!_attached_relationship_managers[rm_type].count(rm.get()), "Already attached");
3346  _attached_relationship_managers[rm_type].insert(rm.get());
3347  }
3348  }
3349 }
std::map< Moose::RelationshipManagerType, std::set< const RelationshipManager * > > _attached_relationship_managers
The relationship managers that have been attached (type -> RMs)
Definition: MooseApp.h:1306
std::shared_ptr< DisplacedProblem > displaced_problem
std::shared_ptr< MooseMesh > & displacedMesh()
MeshBase & mesh
ActionWarehouse _action_warehouse
Where built actions are stored.
Definition: MooseApp.h:1176
FEProblemBase & feProblem() const
Definition: MooseApp.C:1960
RelationshipManager & createRMFromTemplateAndInit(const RelationshipManager &template_rm, MooseMesh &moose_mesh, MeshBase &mesh, const libMesh::DofMap *dof_map=nullptr)
Take an input relationship manager, clone it, and then initialize it with provided mesh and optional ...
Definition: MooseApp.C:3168
std::shared_ptr< MooseMesh > & mesh()
virtual libMesh::DofMap & dofMap()
Gets writeable reference to the dof map.
Definition: SystemBase.C:1155
std::shared_ptr< Executioner > _executioner
Pointer to the executioner of this run (typically build by actions)
Definition: MooseApp.h:1212
MooseMesh wraps a libMesh::Mesh object and enhances its capabilities by caching additional data and s...
Definition: MooseMesh.h:88
virtual std::shared_ptr< const DisplacedProblem > getDisplacedProblem() const
std::set< std::shared_ptr< RelationshipManager > > _relationship_managers
The relationship managers that have been added.
Definition: MooseApp.h:1302
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:267
SolverSystem & getSolverSystem(unsigned int sys_num)
Get non-constant reference to a solver system.
std::shared_ptr< Executor > _executor
Pointer to the Executor of this run.
Definition: MooseApp.h:1215
void add_ghosting_functor(GhostingFunctor &ghosting_functor)

◆ attachRelationshipManagers() [2/2]

void MooseApp::attachRelationshipManagers ( MeshBase &  mesh,
MooseMesh moose_mesh 
)

Attach geometric relationship managers to the given MeshBase object.

This API is designed to work with MeshGenerators which are executed at the very beginning of a simulation. No attempt will be made to add relationship managers to a displaced mesh, because it doesn't exist yet.

◆ backup() [1/2]

std::vector< std::filesystem::path > MooseApp::backup ( const std::filesystem::path &  folder_base)

Backs up the application to the folder folder_base.

Returns
The files that are written in the backup

Definition at line 1848 of file MooseApp.C.

Referenced by Checkpoint::output().

1849 {
1850  TIME_SECTION("backup", 2, "Backing Up Application to File");
1851 
1852  preBackup();
1853 
1855  return writer.write(folder_base);
1856 }
Writer for restartable data, to be read by the RestartableDataReader.
std::vector< RestartableDataMap > _restartable_data
Where the restartable data is held (indexed on tid)
Definition: MooseApp.h:1194
virtual void preBackup()
Insertion point for other apps that is called before backup()
Definition: MooseApp.h:732

◆ backup() [2/2]

std::unique_ptr< Backup > MooseApp::backup ( )

Backs up the application memory in a Backup.

Returns
The backup

Definition at line 1859 of file MooseApp.C.

Referenced by finalizeRestore(), and restore().

1860 {
1861  TIME_SECTION("backup", 2, "Backing Up Application");
1862 
1864 
1865  preBackup();
1866 
1867  auto backup = std::make_unique<Backup>();
1868  writer.write(*backup->header, *backup->data);
1869 
1870  return backup;
1871 }
Writer for restartable data, to be read by the RestartableDataReader.
std::vector< RestartableDataMap > _restartable_data
Where the restartable data is held (indexed on tid)
Definition: MooseApp.h:1194
virtual void preBackup()
Insertion point for other apps that is called before backup()
Definition: MooseApp.h:732
std::unique_ptr< Backup > backup()
Backs up the application memory in a Backup.
Definition: MooseApp.C:1859

◆ builder()

Moose::Builder& MooseApp::builder ( )
inline

Returns a writable reference to the builder.

Definition at line 213 of file MooseApp.h.

Referenced by CreateProblemDefaultAction::act(), SetupMeshAction::act(), and MeshOnlyAction::act().

213 { return _builder; }
Moose::Builder _builder
Builder for building app related parser tree.
Definition: MooseApp.h:1191

◆ callMooseError() [1/2]

void MooseBase::callMooseError ( std::string  msg,
const bool  with_prefix,
const hit::Node *  node = nullptr 
) const
inherited

External method for calling moose error with added object context.

Parameters
msgThe message
with_prefixIf true, add the prefix from messagePrefix(), which is the object information (type, name, etc)
nodeOptional hit node to add file path context as a prefix

Definition at line 102 of file MooseBase.C.

Referenced by InputParameters::callMooseError(), MooseBase::mooseDocumentedError(), MooseBase::mooseError(), and MooseBase::mooseErrorNonPrefixed().

105 {
106  callMooseError(&_app, _pars, msg, with_prefix, node);
107 }
const InputParameters & _pars
The object&#39;s parameters.
Definition: MooseBase.h:362
void callMooseError(std::string msg, const bool with_prefix, const hit::Node *node=nullptr) const
External method for calling moose error with added object context.
Definition: MooseBase.C:102
MooseApp & _app
The MOOSE application this is associated with.
Definition: MooseBase.h:353

◆ callMooseError() [2/2]

void MooseBase::callMooseError ( MooseApp *const  app,
const InputParameters params,
std::string  msg,
const bool  with_prefix,
const hit::Node *  node 
)
staticinherited

External method for calling moose error with added object context.

Needed so that objects without the MooseBase context (InputParameters) can call errors with context

Parameters
appThe app pointer (if available); adds multiapp context and clears the console
paramsThe parameters, needed to obtain object information
msgThe message
with_prefixIf true, add the prefix from messagePrefix(), which is the object information (type, name, etc)
nodeOptional hit node to add file path context as a prefix

Definition at line 110 of file MooseBase.C.

115 {
116  if (!node)
117  node = MooseBase::getHitNode(params);
118 
119  std::string multiapp_prefix = "";
120  if (app)
121  {
122  if (!app->isUltimateMaster())
123  multiapp_prefix = app->name();
125  }
126 
127  if (with_prefix)
128  // False here because the hit context will get processed by the node
129  msg = messagePrefix(params, false) + msg;
130 
131  moose::internal::mooseErrorRaw(msg, multiapp_prefix, node);
132 }
bool isUltimateMaster() const
Whether or not this app is the ultimate master app.
Definition: MooseApp.h:813
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:99
void mooseErrorRaw(std::string msg, const std::string &prefix="", const hit::Node *node=nullptr)
Main callback for emitting a moose error.
Definition: MooseError.C:53
void mooseConsole()
Send current output buffer to Console output objects.
const hit::Node * getHitNode() const
Definition: MooseBase.h:132
OutputWarehouse & getOutputWarehouse()
Get the OutputWarehouse objects.
Definition: MooseApp.C:2442
std::string messagePrefix(const bool hit_prefix=true) const
Definition: MooseBase.h:252

◆ checkInput()

bool MooseApp::checkInput ( ) const
inline

Returns whether the Application is running in check input mode.

Definition at line 923 of file MooseApp.h.

923 { return _check_input; }
bool _check_input
true if we want to just check the input file
Definition: MooseApp.h:1299

◆ checkMetaDataIntegrity()

void MooseApp::checkMetaDataIntegrity ( ) const

Function to check the integrity of the restartable meta data structure.

Definition at line 3428 of file MooseApp.C.

Referenced by SetupRecoverFileBaseAction::act().

3429 {
3430  for (auto map_iter = _restartable_meta_data.begin(); map_iter != _restartable_meta_data.end();
3431  ++map_iter)
3432  {
3433  const RestartableDataMapName & name = map_iter->first;
3434  const RestartableDataMap & meta_data = map_iter->second.first;
3435 
3436  std::vector<std::string> not_declared;
3437 
3438  for (const auto & data : meta_data)
3439  if (!data.declared())
3440  not_declared.push_back(data.name());
3441 
3442  if (!not_declared.empty())
3443  {
3444  std::ostringstream oss;
3445  std::copy(
3446  not_declared.begin(), not_declared.end(), infix_ostream_iterator<std::string>(oss, ", "));
3447 
3448  mooseError("The following '",
3449  name,
3450  "' meta-data properties were retrieved but never declared: ",
3451  oss.str());
3452  }
3453  }
3454 }
std::unordered_map< RestartableDataMapName, std::pair< RestartableDataMap, std::string > > _restartable_meta_data
General storage for custom RestartableData that can be added to from outside applications.
Definition: MooseApp.h:1494
Storage for restartable data that is ordered based on insertion order.
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:99
std::string RestartableDataMapName
Definition: MooseTypes.h:214
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:267

◆ checkpointSuffix()

const std::string & MooseApp::checkpointSuffix ( )
static

The file suffix for the checkpoint mesh.

Definition at line 3072 of file MooseApp.C.

Referenced by SetupRecoverFileBaseAction::act(), MooseMesh::init(), and Checkpoint::output().

3073 {
3074  static const std::string suffix = "-mesh.cpa.gz";
3075  return suffix;
3076 }

◆ checkReservedCapability()

void MooseApp::checkReservedCapability ( const std::string &  capability)
staticprivate

Helper that reports an error if the given capability is reserved and should not be added via addCapability().

Definition at line 2366 of file MooseApp.C.

Referenced by addCapability().

2367 {
2368  // The list of these capabilities should match those within
2369  // Tester.checkRunnableBase() in the TestHarness
2370  static const std::set<std::string> reserved{
2371  "scale_refine", "valgrind", "recover", "heavy", "mpi_procs", "num_threads", "compute_device"};
2372  if (reserved.count(capability))
2373  ::mooseError("MooseApp::addCapability(): The capability \"",
2374  capability,
2375  "\" is reserved and may not be registered by an application.");
2376 }
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:267

◆ commandLine()

std::shared_ptr<CommandLine> MooseApp::commandLine ( ) const
inline

Get the command line.

Returns
The reference to the command line object Setup options based on InputParameters.

Definition at line 411 of file MooseApp.h.

Referenced by MultiApp::createApp(), Moose::Builder::errorCheck(), ConsoleUtils::outputExecutionInformation(), ConsoleUtils::outputFrameworkInformation(), and MooseServer::parseDocumentForDiagnostics().

411 { return _command_line; }
const std::shared_ptr< CommandLine > _command_line
The CommandLine object.
Definition: MooseApp.h:1185

◆ connectControllableParams()

void MooseBase::connectControllableParams ( const std::string &  parameter,
const std::string &  object_type,
const std::string &  object_name,
const std::string &  object_parameter 
) const
inherited

Connect controllable parameter of this action with the controllable parameters of the objects added by this action.

Parameters
parameterName of the controllable parameter of this action
object_typeType of the object added by this action.
object_nameName of the object added by this action.
object_parameterName of the parameter of the object.

Definition at line 74 of file MooseBase.C.

78 {
79  auto & factory = _app.getFactory();
80  auto & ip_warehouse = _app.getInputParameterWarehouse();
81 
82  MooseObjectParameterName primary_name(uniqueName(), parameter);
83  const auto base_type = factory.getValidParams(object_type).getBase();
84  MooseObjectParameterName secondary_name(base_type, object_name, object_parameter);
85  ip_warehouse.addControllableParameterConnection(primary_name, secondary_name);
86 
87  const auto & tags = _pars.get<std::vector<std::string>>("control_tags");
88  for (const auto & tag : tags)
89  {
90  if (!tag.empty())
91  {
92  // Only adds the parameter with the different control tags if the derived class
93  // properly registers the parameter to its own syntax
94  MooseObjectParameterName tagged_name(tag, name(), parameter);
95  ip_warehouse.addControllableParameterConnection(
96  tagged_name, secondary_name, /*error_on_empty=*/false);
97  }
98  }
99 }
const InputParameters & _pars
The object&#39;s parameters.
Definition: MooseBase.h:362
std::vector< std::pair< R1, R2 > > get(const std::string &param1, const std::string &param2) const
Combine two vector parameters into a single vector of pairs.
InputParameterWarehouse & getInputParameterWarehouse()
Get the InputParameterWarehouse for MooseObjects.
Definition: MooseApp.C:2900
MooseObjectName uniqueName() const
Definition: MooseBase.C:66
Factory & getFactory()
Retrieve a writable reference to the Factory associated with this App.
Definition: MooseApp.h:394
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:99
MooseApp & _app
The MOOSE application this is associated with.
Definition: MooseBase.h:353
A class for storing an input parameter name.

◆ constructingMeshGenerators()

bool MooseApp::constructingMeshGenerators ( ) const
virtual

Whether this app is constructing mesh generators.

This is virtual to allow MooseUnitApp to override it so that we can construct MeshGenerators in unit tests

Definition at line 3527 of file MooseApp.C.

Referenced by MeshGenerator::addChildMeshGenerator(), MeshGeneratorSystem::addMeshGenerator(), MeshGenerator::addMeshSubgenerator(), MeshGenerator::addParentMeshGenerator(), MeshGenerator::checkGetMesh(), MeshGeneratorSystem::createMeshGenerator(), MeshGeneratorSystem::createMeshGeneratorOrder(), MeshGenerator::declareMeshProperty(), MeshGenerator::declareNullMeshName(), and MeshGeneratorSystem::getMeshGeneratorOutput().

3528 {
3529  return _action_warehouse.getCurrentTaskName() == "create_added_mesh_generators" ||
3531 }
ActionWarehouse _action_warehouse
Where built actions are stored.
Definition: MooseApp.h:1176
MeshGeneratorSystem _mesh_generator_system
The system that manages the MeshGenerators.
Definition: MooseApp.h:1522
const std::string & getCurrentTaskName() const
bool appendingMeshGenerators() const
Whether or not mesh generators are currently being appended (append_mesh_generator task) ...

◆ copyInputs()

bool MooseApp::copyInputs ( )
private

Handles the copy_inputs input parameter logic: Checks to see whether the passed argument is valid (a readable installed directory) and recursively copies those files into a read/writable location for the user.

Returns
a Boolean value used to indicate whether the application should exit early

Definition at line 2244 of file MooseApp.C.

Referenced by run().

2245 {
2246  if (isParamSetByUser("copy_inputs"))
2247  {
2248  if (comm().size() > 1)
2249  mooseError("The --copy-inputs option should not be ran in parallel");
2250 
2251  // Get command line argument following --copy-inputs on command line
2252  auto dir_to_copy = getParam<std::string>("copy_inputs");
2253 
2254  if (dir_to_copy.empty())
2255  mooseError("Error retrieving directory to copy");
2256  if (dir_to_copy.back() != '/')
2257  dir_to_copy += '/';
2258 
2259  // This binary name is the actual binary. That is, if we called a symlink it'll
2260  // be the name of what the symlink points to
2261  auto binname = appBinaryName();
2262  if (binname == "")
2263  mooseError("could not locate installed tests to run (unresolved binary/app name)");
2264 
2265  auto src_dir = MooseUtils::installedInputsDir(
2266  binname,
2267  dir_to_copy,
2268  "Rerun binary with " + _pars.getCommandLineMetadata("show_inputs").switches[0] +
2269  " to get a list of installable directories.");
2270 
2271  // Use the command line here because if we have a symlink to another binary,
2272  // we want to dump into a directory that is named after the symlink not the true binary
2273  auto dst_dir = _command_line->getExecutableNameBase() + "/" + dir_to_copy;
2274  auto cmdname = _command_line->getExecutableName();
2275  if (cmdname.find_first_of("/") != std::string::npos)
2276  cmdname = cmdname.substr(cmdname.find_first_of("/") + 1, std::string::npos);
2277 
2278  if (MooseUtils::pathExists(dst_dir))
2279  mooseError(
2280  "The directory \"./",
2281  dst_dir,
2282  "\" already exists.\nTo update/recopy the contents of this directory, rename (\"mv ",
2283  dst_dir,
2284  " new_dir_name\") or remove (\"rm -r ",
2285  dst_dir,
2286  "\") the existing directory.\nThen re-run \"",
2287  cmdname,
2288  " --copy-inputs ",
2289  dir_to_copy,
2290  "\".");
2291 
2292  std::string cmd = "mkdir -p " + dst_dir + "; rsync -av " + src_dir + " " + dst_dir;
2293 
2294  TIME_SECTION("copy_inputs", 2, "Copying Inputs");
2295 
2296  mooseAssert(comm().size() == 1, "Should be run in serial");
2297  const auto return_value = system(cmd.c_str());
2298  if (!WIFEXITED(return_value))
2299  mooseError("Process exited unexpectedly");
2300  setExitCode(WEXITSTATUS(return_value));
2301  if (exitCode() == 0)
2302  Moose::out << "Directory successfully copied into ./" << dst_dir << '\n';
2303  return true;
2304  }
2305  return false;
2306 }
const InputParameters & _pars
The object&#39;s parameters.
Definition: MooseBase.h:362
std::string installedInputsDir(const std::string &app_name, const std::string &dir_name, const std::string &extra_error_msg="")
Returns the directory of any installed inputs or the empty string if none are found.
Definition: MooseUtils.C:99
virtual std::string appBinaryName() const
Definition: MooseApp.h:137
const Parallel::Communicator & comm() const
int exitCode() const
Get the shell exit code for the application.
Definition: MooseApp.h:150
const std::shared_ptr< CommandLine > _command_line
The CommandLine object.
Definition: MooseApp.h:1185
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:267
const InputParameters::CommandLineMetadata & getCommandLineMetadata(const std::string &name) const
std::vector< std::string > switches
The switches for the parameter (i.e., [-t, –timing])
bool pathExists(const std::string &path)
Definition: MooseUtils.C:243
void setExitCode(const int exit_code)
Sets the exit code that the application will exit with.
Definition: MooseApp.h:155
bool isParamSetByUser(const std::string &name) const
Test if the supplied parameter is set by a user, as opposed to not set or set to default.
Definition: MooseBase.h:201

◆ createExecutors()

void MooseApp::createExecutors ( )

After adding all of the Executor Params - this function will actually cause all of them to be built.

Definition at line 2052 of file MooseApp.C.

Referenced by AddExecutorAction::act().

2053 {
2054  // Do we have any?
2055  if (_executor_params.empty())
2056  return;
2057 
2058  // Holds the names of Executors that may be the root executor
2059  std::list<std::string> possibly_root;
2060 
2061  // What is already built
2062  std::map<std::string, bool> already_built;
2063 
2064  // The Executors that are currently candidates for being roots
2065  std::list<std::string> possible_roots;
2066 
2067  // The current line of dependencies - used for finding cycles
2068  std::list<std::string> current_branch;
2069 
2070  // Build the NullExecutor
2071  {
2072  auto params = _factory.getValidParams("NullExecutor");
2073  _null_executor = _factory.create<NullExecutor>("NullExecutor", "_null_executor", params);
2074  }
2075 
2076  for (const auto & params_entry : _executor_params)
2077  {
2078  const auto & name = params_entry.first;
2079 
2080  // Did we already make this one?
2081  if (_executors.find(name) != _executors.end())
2082  continue;
2083 
2084  possible_roots.emplace_back(name);
2085 
2086  recursivelyCreateExecutors(name, possible_roots, current_branch);
2087  }
2088 
2089  // If there is more than one possible root - error
2090  if (possible_roots.size() > 1)
2091  {
2092  auto root_string_it = possible_roots.begin();
2093 
2094  std::stringstream roots_string;
2095 
2096  roots_string << *root_string_it++;
2097 
2098  for (; root_string_it != possible_roots.end(); ++root_string_it)
2099  roots_string << ", " << *root_string_it;
2100 
2101  mooseError("Multiple Executor roots found: ", roots_string.str());
2102  }
2103 
2104  // Set the root executor
2105  _executor = _executors[possible_roots.front()];
2106 }
std::unordered_map< std::string, std::pair< std::string, std::unique_ptr< InputParameters > > > _executor_params
Used in building the Executors Maps the name of the Executor block to the <type, params> ...
Definition: MooseApp.h:1223
void recursivelyCreateExecutors(const std::string &current_executor_name, std::list< std::string > &possible_roots, std::list< std::string > &current_branch)
Internal function used to recursively create the executor objects.
Definition: MooseApp.C:2000
std::map< std::string, std::shared_ptr< Executor > > _executors
Pointers to all of the Executors for this run.
Definition: MooseApp.h:1218
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:99
std::shared_ptr< NullExecutor > _null_executor
Used to return an executor that does nothing.
Definition: MooseApp.h:1234
virtual std::unique_ptr< Base > create()=0
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:267
Factory _factory
Definition: MooseApp.h:1250
std::shared_ptr< Executor > _executor
Pointer to the Executor of this run.
Definition: MooseApp.h:1215

◆ createMinimalApp()

void MooseApp::createMinimalApp ( )
private

Method for creating the minimum required actions for an application (no input file)

Mimics the following input file:

[Mesh] type = GeneratedMesh dim = 1 nx = 1 []

[Executioner] type = Transient num_steps = 1 dt = 1 []

[Problem] solve = false []

[Outputs] console = false []

Definition at line 2924 of file MooseApp.C.

Referenced by setupOptions().

2925 {
2926  TIME_SECTION("createMinimalApp", 3, "Creating Minimal App");
2927 
2928  // SetupMeshAction
2929  {
2930  // Build the Action parameters
2931  InputParameters action_params = _action_factory.getValidParams("SetupMeshAction");
2932  action_params.set<std::string>("type") = "GeneratedMesh";
2933 
2934  // Create The Action
2935  std::shared_ptr<MooseObjectAction> action = std::static_pointer_cast<MooseObjectAction>(
2936  _action_factory.create("SetupMeshAction", "Mesh", action_params));
2937 
2938  // Set the object parameters
2939  InputParameters & params = action->getObjectParams();
2940  params.set<MooseEnum>("dim") = "1";
2941  params.set<unsigned int>("nx") = 1;
2942 
2943  // Add Action to the warehouse
2945  }
2946 
2947  // Executioner
2948  {
2949  // Build the Action parameters
2950  InputParameters action_params = _action_factory.getValidParams("CreateExecutionerAction");
2951  action_params.set<std::string>("type") = "Transient";
2952 
2953  // Create the action
2954  std::shared_ptr<MooseObjectAction> action = std::static_pointer_cast<MooseObjectAction>(
2955  _action_factory.create("CreateExecutionerAction", "Executioner", action_params));
2956 
2957  // Set the object parameters
2958  InputParameters & params = action->getObjectParams();
2959  params.set<unsigned int>("num_steps") = 1;
2960  params.set<Real>("dt") = 1;
2961 
2962  // Add Action to the warehouse
2964  }
2965 
2966  // Problem
2967  {
2968  // Build the Action parameters
2969  InputParameters action_params = _action_factory.getValidParams("CreateProblemDefaultAction");
2970  action_params.set<bool>("_solve") = false;
2971 
2972  // Create the action
2973  std::shared_ptr<Action> action = std::static_pointer_cast<Action>(
2974  _action_factory.create("CreateProblemDefaultAction", "Problem", action_params));
2975 
2976  // Add Action to the warehouse
2978  }
2979 
2980  // Outputs
2981  {
2982  // Build the Action parameters
2983  InputParameters action_params = _action_factory.getValidParams("CommonOutputAction");
2984  action_params.set<bool>("console") = false;
2985 
2986  // Create action
2987  std::shared_ptr<Action> action =
2988  _action_factory.create("CommonOutputAction", "Outputs", action_params);
2989 
2990  // Add Action to the warehouse
2992  }
2993 
2995 }
InputParameters getValidParams(const std::string &name)
Definition: ActionFactory.C:94
T & set(const std::string &name, bool quiet_mode=false)
Returns a writable reference to the named parameters.
The main MOOSE class responsible for handling user-defined parameters in almost every MOOSE system...
void addActionBlock(std::shared_ptr< Action > blk)
This method add an Action instance to the warehouse.
ActionWarehouse _action_warehouse
Where built actions are stored.
Definition: MooseApp.h:1176
Base class for actions.
Definition: Action.h:33
std::shared_ptr< Action > create(const std::string &action, const std::string &action_name, InputParameters &parameters)
Definition: ActionFactory.C:40
ActionFactory _action_factory
The Factory responsible for building Actions.
Definition: MooseApp.h:1173
This is a "smart" enum class intended to replace many of the shortcomings in the C++ enum type It sho...
Definition: MooseEnum.h:33
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
void build()
Builds all auto-buildable tasks.

◆ createRecoverablePerfGraph()

PerfGraph & MooseApp::createRecoverablePerfGraph ( )
private

Creates a recoverable PerfGraph.

This is a separate method so that it can be used in the constructor (multiple calls are required to declare it).

Definition at line 3496 of file MooseApp.C.

3497 {
3499 
3500  auto perf_graph =
3501  std::make_unique<RestartableData<PerfGraph>>("perf_graph",
3502  this,
3503  type() + " (" + name() + ')',
3504  *this,
3505  getParam<bool>("perf_graph_live_all"),
3506  !getParam<bool>("disable_perf_graph_live"));
3507 
3508  return dynamic_cast<RestartableData<PerfGraph> &>(
3509  registerRestartableData(std::move(perf_graph), 0, false))
3510  .set();
3511 }
void registerRestartableNameWithFilter(const std::string &name, Moose::RESTARTABLE_FILTER filter)
NOTE: This is an internal function meant for MOOSE use only!
Definition: MooseApp.C:1833
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:99
RestartableDataValue & registerRestartableData(std::unique_ptr< RestartableDataValue > data, THREAD_ID tid, bool read_only, const RestartableDataMapName &metaname="")
Definition: MooseApp.C:2482
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:89
Concrete definition of a parameter value for a specified type.

◆ createRecoverableSolutionInvalidity()

SolutionInvalidity & MooseApp::createRecoverableSolutionInvalidity ( )
private

Creates a recoverable SolutionInvalidity.

This is a separate method so that it can be used in the constructor (multiple calls are required to declare it).

Definition at line 3514 of file MooseApp.C.

3515 {
3517 
3518  auto solution_invalidity =
3519  std::make_unique<RestartableData<SolutionInvalidity>>("solution_invalidity", nullptr, *this);
3520 
3521  return dynamic_cast<RestartableData<SolutionInvalidity> &>(
3522  registerRestartableData(std::move(solution_invalidity), 0, false))
3523  .set();
3524 }
void registerRestartableNameWithFilter(const std::string &name, Moose::RESTARTABLE_FILTER filter)
NOTE: This is an internal function meant for MOOSE use only!
Definition: MooseApp.C:1833
RestartableDataValue & registerRestartableData(std::unique_ptr< RestartableDataValue > data, THREAD_ID tid, bool read_only, const RestartableDataMapName &metaname="")
Definition: MooseApp.C:2482
Concrete definition of a parameter value for a specified type.

◆ createRMFromTemplateAndInit()

RelationshipManager & MooseApp::createRMFromTemplateAndInit ( const RelationshipManager template_rm,
MooseMesh moose_mesh,
MeshBase mesh,
const libMesh::DofMap dof_map = nullptr 
)
private

Take an input relationship manager, clone it, and then initialize it with provided mesh and optional dof_map.

Parameters
template_rmThe relationship manager template from which we will clone
moose_meshThe moose mesh to use for initialization
meshThe mesh to use for initialization
dof_mapAn optional parameter that, if provided, will be used to help init the cloned relationship manager
Returns
a reference to the cloned and initialized relationship manager

Definition at line 3168 of file MooseApp.C.

Referenced by attachRelationshipManagers().

3172 {
3173  auto & mesh_to_clone = _template_to_clones[&template_rm];
3174  auto it = mesh_to_clone.find(&mesh);
3175  if (it != mesh_to_clone.end())
3176  {
3177  // We've already created a clone for this mesh
3178  auto & clone_rm = *it->second;
3179  if (!clone_rm.dofMap() && dof_map)
3180  // We didn't have a DofMap before, but now we do, so we should re-init
3181  clone_rm.init(moose_mesh, mesh, dof_map);
3182  else if (clone_rm.dofMap() && dof_map && (clone_rm.dofMap() != dof_map))
3183  mooseError("Attempting to create and initialize an existing clone with a different DofMap. "
3184  "This should not happen.");
3185 
3186  return clone_rm;
3187  }
3188 
3189  // It's possible that this method is going to get called for multiple different MeshBase
3190  // objects. If that happens, then we *cannot* risk having a MeshBase object with a ghosting
3191  // functor that is init'd with another MeshBase object. So the safe thing to do is to make a
3192  // different RM for every MeshBase object that gets called here. Then the
3193  // RelationshipManagers stored here in MooseApp are serving as a template only
3194  auto pr = mesh_to_clone.emplace(
3195  std::make_pair(&const_cast<const MeshBase &>(mesh),
3196  dynamic_pointer_cast<RelationshipManager>(template_rm.clone())));
3197  mooseAssert(pr.second, "An insertion should have happened");
3198  auto & clone_rm = *pr.first->second;
3199  clone_rm.init(moose_mesh, mesh, dof_map);
3200  return clone_rm;
3201 }
std::map< const RelationshipManager *, std::map< const MeshBase *, std::unique_ptr< RelationshipManager > > > _template_to_clones
Map from a template relationship manager to a map in which the key-value pairs represent the MeshBase...
Definition: MooseApp.h:1554
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:267
virtual std::unique_ptr< GhostingFunctor > clone() const

◆ defaultAutomaticScaling()

bool MooseApp::defaultAutomaticScaling ( ) const
inline

Whether to enable automatic scaling by default.

Definition at line 1002 of file MooseApp.h.

1002 { return _automatic_automatic_scaling; }
const bool _automatic_automatic_scaling
Whether to turn on automatic scaling by default.
Definition: MooseApp.h:1542

◆ determineLibtorchDeviceType()

torch::DeviceType MooseApp::determineLibtorchDeviceType ( const MooseEnum device) const
private

Function to determine the device which should be used by libtorch on this application.

We use this function to decide what is available on different builds.

Parameters
deviceEnum to describe if a cpu or a gpu should be used.

Definition at line 3535 of file MooseApp.C.

3536 {
3537  const auto pname = "--compute-device";
3538  if (device_enum == "cuda")
3539  {
3540 #ifdef __linux__
3541  if (!torch::cuda::is_available())
3542  mooseError(pname, "=cuda: CUDA support is not available in the linked libtorch library");
3543  return torch::kCUDA;
3544 #else
3545  mooseError(pname, "=cuda: CUDA is not supported on your platform");
3546 #endif
3547  }
3548  else if (device_enum == "mps")
3549  {
3550 #ifdef __APPLE__
3551  if (!torch::mps::is_available())
3552  mooseError(pname, "=mps: MPS support is not available in the linked libtorch library");
3553  return torch::kMPS;
3554 #else
3555  mooseError(pname, "=mps: MPS is not supported on your platform");
3556 #endif
3557  }
3558 
3559  else if (device_enum != "cpu")
3560  mooseError("The device '",
3561  device_enum,
3562  "' is not currently supported by the MOOSE libtorch integration.");
3563  return torch::kCPU;
3564 }
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:267

◆ disableCheckUnusedFlag()

void MooseApp::disableCheckUnusedFlag ( )

Removes warnings and error checks for unrecognized variables in the input file.

Definition at line 1954 of file MooseApp.C.

1955 {
1957 }
enum MooseApp::UNUSED_CHECK _enable_unused_check

◆ dynamicAllRegistration()

void MooseApp::dynamicAllRegistration ( const std::string &  app_name,
Factory factory,
ActionFactory action_factory,
Syntax syntax,
std::string  library_path,
const std::string &  library_name 
)

Thes methods are called to register applications or objects on demand.

This method attempts to load a dynamic library and register it when it is needed. Throws an error if no suitable library is found that contains the app_name in question.

Definition at line 2671 of file MooseApp.C.

Referenced by DynamicObjectRegistrationAction::DynamicObjectRegistrationAction().

2677 {
2678 #ifdef LIBMESH_HAVE_DLOPEN
2679  Parameters params;
2680  params.set<std::string>("app_name") = app_name;
2681  params.set<RegistrationType>("reg_type") = REGALL;
2682  params.set<std::string>("registration_method") = app_name + "__registerAll";
2683  params.set<std::string>("library_path") = library_path;
2684  params.set<std::string>("library_name") =
2685  library_name.empty() ? appNameToLibName(app_name) : library_name;
2686 
2687  params.set<Factory *>("factory") = factory;
2688  params.set<Syntax *>("syntax") = syntax;
2689  params.set<ActionFactory *>("action_factory") = action_factory;
2690  params.set<bool>("library_load_dependencies") = false;
2691 
2692  dynamicRegistration(params);
2693 #else
2694  libmesh_ignore(app_name, factory, action_factory, syntax, library_path, library_name);
2695  mooseError("Dynamic Loading is either not supported or was not detected by libMesh configure.");
2696 #endif
2697 }
void dynamicRegistration(const libMesh::Parameters &params)
Helper method for dynamic loading of objects.
Definition: MooseApp.C:2700
Syntax & syntax()
Returns a writable reference to the syntax object.
Definition: MooseApp.h:218
void libmesh_ignore(const Args &...)
Specialized factory for generic Action System objects.
Definition: ActionFactory.h:50
RegistrationType
Enumeration for holding the valid types of dynamic registrations allowed.
Definition: MooseApp.h:1497
T & set(const std::string &)
Holding syntax for parsing input files.
Definition: Syntax.h:21
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:267
std::string appNameToLibName(const std::string &app_name) const
Converts an application name to a library name: Examples: AnimalApp -> libanimal-oprof.la (assuming METHOD=oprof) ThreeWordAnimalApp -> libthree_word_animal-dbg.la (assuming METHOD=dbg)
Definition: MooseApp.C:2454

◆ dynamicAppRegistration()

void MooseApp::dynamicAppRegistration ( const std::string &  app_name,
std::string  library_path,
const std::string &  library_name,
bool  lib_load_deps 
)

Definition at line 2614 of file MooseApp.C.

Referenced by MultiApp::createApps().

2618 {
2619 #ifdef LIBMESH_HAVE_DLOPEN
2620  Parameters params;
2621  params.set<std::string>("app_name") = app_name;
2622  params.set<RegistrationType>("reg_type") = APPLICATION;
2623  params.set<std::string>("registration_method") = app_name + "__registerApps";
2624  params.set<std::string>("library_path") = library_path;
2625 
2626  const auto effective_library_name =
2627  library_name.empty() ? appNameToLibName(app_name) : library_name;
2628  params.set<std::string>("library_name") = effective_library_name;
2629  params.set<bool>("library_load_dependencies") = lib_load_deps;
2630 
2631  const auto paths = getLibrarySearchPaths(library_path);
2632  std::ostringstream oss;
2633 
2634  auto successfully_loaded = false;
2635  if (paths.empty())
2636  oss << '"' << app_name << "\" is not a registered application name.\n"
2637  << "No search paths were set. We made no attempts to locate the corresponding library "
2638  "file.\n";
2639  else
2640  {
2641  dynamicRegistration(params);
2642 
2643  // At this point the application should be registered so check it
2644  if (!AppFactory::instance().isRegistered(app_name))
2645  {
2646  oss << '"' << app_name << "\" is not a registered application name.\n"
2647  << "Unable to locate library archive for \"" << app_name
2648  << "\".\nWe attempted to locate the library archive \"" << effective_library_name
2649  << "\" in the following paths:\n\t";
2650  std::copy(paths.begin(), paths.end(), infix_ostream_iterator<std::string>(oss, "\n\t"));
2651  }
2652  else
2653  successfully_loaded = true;
2654  }
2655 
2656  if (!successfully_loaded)
2657  {
2658  oss << "\nMake sure you have compiled the library and either set the \"library_path\" "
2659  "variable in your input file or exported \"MOOSE_LIBRARY_PATH\".\n";
2660 
2661  mooseError(oss.str());
2662  }
2663 
2664 #else
2665  libmesh_ignore(app_name, library_path, library_name, lib_load_deps);
2666  mooseError("Dynamic Loading is either not supported or was not detected by libMesh configure.");
2667 #endif
2668 }
void dynamicRegistration(const libMesh::Parameters &params)
Helper method for dynamic loading of objects.
Definition: MooseApp.C:2700
void libmesh_ignore(const Args &...)
RegistrationType
Enumeration for holding the valid types of dynamic registrations allowed.
Definition: MooseApp.h:1497
std::set< std::string > getLibrarySearchPaths(const std::string &library_path_from_param) const
Return the paths searched by MOOSE when loading libraries.
Definition: MooseApp.C:2874
static AppFactory & instance()
Get the instance of the AppFactory.
Definition: AppFactory.C:18
T & set(const std::string &)
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:267
std::string appNameToLibName(const std::string &app_name) const
Converts an application name to a library name: Examples: AnimalApp -> libanimal-oprof.la (assuming METHOD=oprof) ThreeWordAnimalApp -> libthree_word_animal-dbg.la (assuming METHOD=dbg)
Definition: MooseApp.C:2454

◆ dynamicRegistration()

void MooseApp::dynamicRegistration ( const libMesh::Parameters params)
protected

Helper method for dynamic loading of objects.

Definition at line 2700 of file MooseApp.C.

Referenced by dynamicAllRegistration(), and dynamicAppRegistration().

2701 {
2702  const auto paths = getLibrarySearchPaths(params.get<std::string>("library_path"));
2703  const auto library_name = params.get<std::string>("library_name");
2704 
2705  // Attempt to dynamically load the library
2706  for (const auto & path : paths)
2707  if (MooseUtils::checkFileReadable(path + '/' + library_name, false, false))
2709  path + '/' + library_name, params, params.get<bool>("library_load_dependencies"));
2710 }
const T & get(std::string_view) const
void loadLibraryAndDependencies(const std::string &library_filename, const libMesh::Parameters &params, bool load_dependencies=true)
Recursively loads libraries and dependencies in the proper order to fully register a MOOSE applicatio...
Definition: MooseApp.C:2713
bool checkFileReadable(const std::string &filename, bool check_line_endings=false, bool throw_on_unreadable=true, bool check_for_git_lfs_pointer=true)
Checks to see if a file is readable (exists and permissions)
Definition: MooseUtils.C:250
std::set< std::string > getLibrarySearchPaths(const std::string &library_path_from_param) const
Return the paths searched by MOOSE when loading libraries.
Definition: MooseApp.C:2874

◆ errorCheck()

void MooseApp::errorCheck ( )
protected

Runs post-initialization error checking that cannot be run correctly unless the simulation has been fully set up and initialized.

Definition at line 1733 of file MooseApp.C.

Referenced by executeExecutioner(), and run().

1734 {
1735  bool warn = _enable_unused_check == WARN_UNUSED;
1737 
1738  _builder.errorCheck(*_comm, warn, err);
1739 
1740  // Return early for mesh only mode, since we want error checking to run even though
1741  // an executor is not created for this case
1742  if (isParamSetByUser("mesh_only"))
1743  return;
1744 
1745  if (!_executor.get() && !_executioner.get())
1746  {
1747  if (!_early_exit_param.empty())
1748  {
1749  mooseAssert(_check_input,
1750  "Something went wrong, we should only get here if _check_input is true.");
1751  mooseError(
1752  "Incompatible command line arguments provided. --check-input cannot be called with ",
1754  ".");
1755  }
1756  // We should never get here
1757  mooseError("The Executor is being called without being initialized. This is likely "
1758  "caused by "
1759  "incompatible command line arguments");
1760  }
1761 
1762  auto apps = feProblem().getMultiAppWarehouse().getObjects();
1763  for (auto app : apps)
1764  for (unsigned int i = 0; i < app->numLocalApps(); i++)
1765  app->localApp(i)->errorCheck();
1766 }
OStreamProxy err
bool _check_input
true if we want to just check the input file
Definition: MooseApp.h:1299
ExecuteMooseObjectWarehouse< MultiApp > & getMultiAppWarehouse()
FEProblemBase & feProblem() const
Definition: MooseApp.C:1960
const std::vector< std::shared_ptr< T > > & getObjects(THREAD_ID tid=0) const
Retrieve complete vector to the all/block/boundary restricted objects for a given thread...
std::shared_ptr< Executioner > _executioner
Pointer to the executioner of this run (typically build by actions)
Definition: MooseApp.h:1212
enum MooseApp::UNUSED_CHECK _enable_unused_check
void errorCheck(const libMesh::Parallel::Communicator &comm, bool warn_unused, bool err_unused)
Definition: Builder.C:379
Moose::Builder _builder
Builder for building app related parser tree.
Definition: MooseApp.h:1191
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:267
const std::shared_ptr< libMesh::Parallel::Communicator > _comm
The MPI communicator this App is going to use.
Definition: MooseApp.h:1142
bool isParamSetByUser(const std::string &name) const
Test if the supplied parameter is set by a user, as opposed to not set or set to default.
Definition: MooseBase.h:201
std::shared_ptr< Executor > _executor
Pointer to the Executor of this run.
Definition: MooseApp.h:1215
std::string _early_exit_param
Indicates if simulation is ready to exit, and keeps track of which param caused it to exit...
Definition: MooseApp.h:1255

◆ errorOnJacobianNonzeroReallocation()

virtual bool MooseApp::errorOnJacobianNonzeroReallocation ( ) const
inlinevirtual

Whether this application should by default error on Jacobian nonzero reallocations.

The application level setting can always be overridden by setting the error_on_jacobian_nonzero_reallocation parameter in the Problem block of the input file

Definition at line 1036 of file MooseApp.h.

1036 { return false; }

◆ errorPrefix()

std::string MooseBase::errorPrefix ( const std::string &  ) const
inlineinherited

Deprecated message prefix; the error type is no longer used.

Definition at line 260 of file MooseBase.h.

260 { return messagePrefix(); }
std::string messagePrefix(const bool hit_prefix=true) const
Definition: MooseBase.h:252

◆ executeExecutioner()

void MooseApp::executeExecutioner ( )
virtual

Execute the Executioner that was built.

Definition at line 1769 of file MooseApp.C.

Referenced by run().

1770 {
1771  TIME_SECTION("executeExecutioner", 3);
1772 
1773  // If ready to exit has been set, then just return
1774  if (_ready_to_exit)
1775  return;
1776 
1777  // run the simulation
1778  if (_use_executor && _executor)
1779  {
1780  LibmeshPetscCall(Moose::PetscSupport::petscSetupOutput(_command_line.get()));
1781  _executor->init();
1782  errorCheck();
1783  auto result = _executor->exec();
1784  if (!result.convergedAll())
1785  mooseError(result.str());
1786  }
1787  else if (_executioner)
1788  {
1789  LibmeshPetscCall(Moose::PetscSupport::petscSetupOutput(_command_line.get()));
1790  _executioner->init();
1791  errorCheck();
1792  _executioner->execute();
1793  if (!_executioner->lastSolveConverged())
1794  setExitCode(1);
1795  }
1796  else
1797  mooseError("No executioner was specified (go fix your input file)");
1798 }
std::shared_ptr< Executioner > _executioner
Pointer to the executioner of this run (typically build by actions)
Definition: MooseApp.h:1212
const std::shared_ptr< CommandLine > _command_line
The CommandLine object.
Definition: MooseApp.h:1185
PetscErrorCode petscSetupOutput(CommandLine *cmd_line)
Definition: PetscSupport.C:251
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:267
void setExitCode(const int exit_code)
Sets the exit code that the application will exit with.
Definition: MooseApp.h:155
bool _ready_to_exit
Definition: MooseApp.h:1256
const bool _use_executor
Indicates whether we are operating in the new/experimental executor mode instead of using the legacy ...
Definition: MooseApp.h:1231
std::shared_ptr< Executor > _executor
Pointer to the Executor of this run.
Definition: MooseApp.h:1215
void errorCheck()
Runs post-initialization error checking that cannot be run correctly unless the simulation has been f...
Definition: MooseApp.C:1733

◆ exitCode()

int MooseApp::exitCode ( ) const
inline

Get the shell exit code for the application.

Returns
The shell exit code

Definition at line 150 of file MooseApp.h.

Referenced by copyInputs().

150 { return _exit_code; }
int _exit_code
The exit code.
Definition: MooseApp.h:1258

◆ feProblem()

FEProblemBase & MooseApp::feProblem ( ) const

Definition at line 1960 of file MooseApp.C.

Referenced by attachRelationshipManagers(), MooseMesh::cacheFaceInfoVariableOwnership(), MooseMesh::cacheFVElementalDoFs(), errorCheck(), AutomaticMortarGeneration::initOutput(), removeRelationshipManager(), and setOutputFileBase().

1961 {
1962  mooseAssert(_executor.get() || _executioner.get(), "No executioner yet, calling too early!");
1963  return _executor.get() ? _executor->feProblem() : _executioner->feProblem();
1964 }
std::shared_ptr< Executioner > _executioner
Pointer to the executioner of this run (typically build by actions)
Definition: MooseApp.h:1212
std::shared_ptr< Executor > _executor
Pointer to the Executor of this run.
Definition: MooseApp.h:1215

◆ finalizeRestore()

std::unique_ptr< Backup > MooseApp::finalizeRestore ( )

Finalizes (closes) the restoration process done in restore().

Returns
The underlying Backup that was used to do the restoration (if any, will be null when backed up from file); can be ignored to destruct it

This releases access to the stream in which the restore was loaded from and makes it no longer possible to restore additional data.

Definition at line 1916 of file MooseApp.C.

Referenced by FEProblemBase::initialSetup().

1917 {
1918  if (!_rd_reader.isRestoring())
1919  mooseError("MooseApp::finalizeRestore(): Not currently restoring");
1920 
1921  // This gives us access to the underlying streams so that we can return it if needed
1922  auto input_streams = _rd_reader.clear();
1923 
1924  std::unique_ptr<Backup> backup;
1925 
1926  // Give them back a backup if this restore started from a Backup, in which case
1927  // the two streams in the Backup are formed into StringInputStreams
1928  if (auto header_string_input = dynamic_cast<StringInputStream *>(input_streams.header.get()))
1929  {
1930  auto data_string_input = dynamic_cast<StringInputStream *>(input_streams.data.get());
1931  mooseAssert(data_string_input, "Should also be a string input");
1932 
1933  auto header_sstream = header_string_input->release();
1934  mooseAssert(header_sstream, "Header not available");
1935 
1936  auto data_sstream = data_string_input->release();
1937  mooseAssert(data_sstream, "Data not available");
1938 
1939  backup = std::make_unique<Backup>();
1940  backup->header = std::move(header_sstream);
1941  backup->data = std::move(data_sstream);
1942  }
1943 
1944  return backup;
1945 }
RestartableDataReader _rd_reader
Definition: MooseApp.h:1527
std::unique_ptr< Backup > backup()
Backs up the application memory in a Backup.
Definition: MooseApp.C:1859
Helper class that hands out input streams to a stringstream.
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:267
InputStreams clear()
Clears the contents of the reader (header stream, data stream, header)

◆ fixedPointConfig()

FixedPointConfig& MooseApp::fixedPointConfig ( )
inline

This info is stored here because we need a "globalish" place to put it in order to allow communication between a multiapp and solver-specific internals (i.e.

relating to fixed-point inner loops like picard, etc.) for handling subapp-specific modifications necessary for those solve processes.

Definition at line 379 of file MooseApp.h.

Referenced by FixedPointSolve::FixedPointSolve().

379 { return _fixed_point_config; }
FixedPointConfig _fixed_point_config
Multiapp-related fixed point algorithm configuration details primarily intended to be passed to and u...
Definition: MooseApp.h:1227

◆ forceRestart()

bool MooseApp::forceRestart ( ) const
inline

Whether or not we are forcefully restarting (allowing the load of potentially incompatibie checkpoints); used within RestartableDataReader.

Definition at line 1061 of file MooseApp.h.

Referenced by possiblyLoadRestartableMetaData().

1061 { return _force_restart; }
const bool _force_restart
Whether or not we are forcefully attempting to load checkpoints (–force-restart) ...
Definition: MooseApp.h:1282

◆ getActionFactory()

ActionFactory& MooseApp::getActionFactory ( )
inline

Retrieve a writable reference to the ActionFactory associated with this App.

Definition at line 399 of file MooseApp.h.

Referenced by Action::Action(), DumpObjectsProblem::DumpObjectsProblem(), and MooseServer::getActionParameters().

399 { return _action_factory; }
ActionFactory _action_factory
The Factory responsible for building Actions.
Definition: MooseApp.h:1173

◆ getBase()

const std::string& MooseBase::getBase ( ) const
inlineinherited
Returns
The registered base for this object (set via InputParameters::registerBase())

Definition at line 143 of file MooseBase.h.

Referenced by Factory::copyConstruct(), and MooseBase::uniqueParameterName().

143 { return _pars.getBase(); }
const InputParameters & _pars
The object&#39;s parameters.
Definition: MooseBase.h:362
const std::string & getBase() const

◆ getChainControlDataSystem()

ChainControlDataSystem& MooseApp::getChainControlDataSystem ( )
inline

Gets the system that manages the ChainControls.

Definition at line 838 of file MooseApp.h.

Referenced by ChainControlSetupAction::act(), FEProblemBase::advanceState(), ChainControl::getChainControlDataSystem(), and ChainControlDataPostprocessor::initialSetup().

838 { return _chain_control_system; }
ChainControlDataSystem _chain_control_system
The system that manages the ChainControls.
Definition: MooseApp.h:1525

◆ getCheckedPointerParam()

template<typename T >
T MooseBase::getCheckedPointerParam ( const std::string &  name,
const std::string &  error_string = "" 
) const
inherited

Verifies that the requested parameter exists and is not NULL and returns it to the caller.

The template parameter must be a pointer or an error will be thrown.

Definition at line 428 of file MooseBase.h.

429 {
430  return _pars.getCheckedPointerParam<T>(name, error_string);
431 }
const InputParameters & _pars
The object&#39;s parameters.
Definition: MooseBase.h:362
T getCheckedPointerParam(const std::string &name, const std::string &error_string="") const
Verifies that the requested parameter exists and is not NULL and returns it to the caller...
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:99

◆ getCheckpointDirectories()

std::list< std::string > MooseApp::getCheckpointDirectories ( ) const

Get all checkpoint directories.

Returns
A Set of checkpoint directories

Definition at line 2390 of file MooseApp.C.

Referenced by getCheckpointFiles().

2391 {
2392  // Storage for the directory names
2393  std::list<std::string> checkpoint_dirs;
2394 
2395  // Add the directories added with Outputs/checkpoint=true input syntax
2396  checkpoint_dirs.push_back(getOutputFileBase() + "_cp");
2397 
2398  // Add the directories from any existing checkpoint output objects
2399  const auto & actions = _action_warehouse.getActionListByName("add_output");
2400  for (const auto & action : actions)
2401  {
2402  // Get the parameters from the MooseObjectAction
2403  MooseObjectAction * moose_object_action = dynamic_cast<MooseObjectAction *>(action);
2404  if (!moose_object_action)
2405  continue;
2406 
2407  const InputParameters & params = moose_object_action->getObjectParams();
2408  if (moose_object_action->getParam<std::string>("type") == "Checkpoint")
2409  {
2410  // Unless file_base was explicitly set by user, we cannot rely on it, as it will be changed
2411  // later
2412  const std::string cp_dir =
2413  _file_base_set_by_user ? params.get<std::string>("file_base")
2414  : (getOutputFileBase(true) + "_" + moose_object_action->name());
2415  checkpoint_dirs.push_back(cp_dir + "_cp");
2416  }
2417  }
2418  return checkpoint_dirs;
2419 }
const T & getParam(const std::string &name) const
Retrieve a parameter for the object.
Definition: MooseBase.h:384
bool _file_base_set_by_user
Whether or not file base is set through input or setOutputFileBase by MultiApp.
Definition: MooseApp.h:1148
std::vector< std::pair< R1, R2 > > get(const std::string &param1, const std::string &param2) const
Combine two vector parameters into a single vector of pairs.
std::string getOutputFileBase(bool for_non_moose_build_output=false) const
Get the output file base name.
Definition: MooseApp.C:1669
The main MOOSE class responsible for handling user-defined parameters in almost every MOOSE system...
ActionWarehouse _action_warehouse
Where built actions are stored.
Definition: MooseApp.h:1176
const std::list< Action * > & getActionListByName(const std::string &task) const
Retrieve a constant list of Action pointers associated with the passed in task.
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:99
InputParameters & getObjectParams()
Retrieve the parameters of the object to be created by this action.

◆ getCheckpointFiles()

std::list< std::string > MooseApp::getCheckpointFiles ( ) const

Extract all possible checkpoint file names.

Returns
A Set of checkpoint filenames

Definition at line 2422 of file MooseApp.C.

Referenced by setRestartRecoverFileBase().

2423 {
2424  auto checkpoint_dirs = getCheckpointDirectories();
2425  return MooseUtils::getFilesInDirs(checkpoint_dirs, false);
2426 }
std::list< std::string > getCheckpointDirectories() const
Get all checkpoint directories.
Definition: MooseApp.C:2390
std::list< std::string > getFilesInDirs(const std::list< std::string > &directory_list, const bool files_only=true)
Retrieves the names of all of the files contained within the list of directories passed into the rout...
Definition: MooseUtils.C:804

◆ getCommunicator()

const std::shared_ptr<libMesh::Parallel::Communicator> MooseApp::getCommunicator ( ) const
inline

Definition at line 1005 of file MooseApp.h.

Referenced by MooseServer::parseDocumentForDiagnostics().

1005 { return _comm; }
const std::shared_ptr< libMesh::Parallel::Communicator > _comm
The MPI communicator this App is going to use.
Definition: MooseApp.h:1142

◆ getComputeDevice()

std::optional<MooseEnum> MooseApp::getComputeDevice ( ) const

Get the device accelerated computations are supposed to be running on.

Referenced by MFEMProblemSolve::MFEMProblemSolve().

◆ getCurrentActionHitNode()

const hit::Node * MooseApp::getCurrentActionHitNode ( ) const
Returns
The hit node that is responsible for creating the current action that is running, if any

Can be used to link objects that are created by an action to the action that created them in input

Definition at line 3095 of file MooseApp.C.

Referenced by ActionFactory::create(), and Factory::initialize().

3096 {
3097  if (const auto action = _action_warehouse.getCurrentAction())
3098  return action->parameters().getHitNode();
3099  return nullptr;
3100 }
const Action * getCurrentAction() const
ActionWarehouse _action_warehouse
Where built actions are stored.
Definition: MooseApp.h:1176

◆ getDistributedMeshOnCommandLine()

bool MooseApp::getDistributedMeshOnCommandLine ( ) const
inline

Returns true if the user specified –distributed-mesh (or –parallel-mesh, for backwards compatibility) on the command line and false otherwise.

Definition at line 453 of file MooseApp.h.

Referenced by MooseMesh::determineUseDistributedMesh().

bool _distributed_mesh_on_command_line
This variable indicates that DistributedMesh should be used for the libMesh mesh underlying MooseMesh...
Definition: MooseApp.h:1267

◆ getExecuteOnEnum()

const ExecFlagEnum& MooseApp::getExecuteOnEnum ( ) const
inline

Return the app level ExecFlagEnum, this contains all the available flags for the app.

Definition at line 987 of file MooseApp.h.

Referenced by FEProblemBase::initialSetup(), and EigenExecutionerBase::normalizeSolution().

987 { return _execute_flags; }
const ExecFlagEnum _execute_flags
Execution flags for this App.
Definition: MooseApp.h:1536

◆ getExecutioner()

Executioner * MooseApp::getExecutioner ( ) const

◆ getExecutor() [1/2]

Executor* MooseApp::getExecutor ( ) const
inline

Definition at line 328 of file MooseApp.h.

Referenced by CheckIntegrityAction::act(), ExecutorInterface::getExecutor(), FEProblemBase::getExecutor(), and ExecutorInterface::getExecutorByName().

328 { return _executor.get(); }
std::shared_ptr< Executor > _executor
Pointer to the Executor of this run.
Definition: MooseApp.h:1215

◆ getExecutor() [2/2]

Executor & MooseApp::getExecutor ( const std::string &  name,
bool  fail_if_not_found = true 
)

Get an Executor.

Parameters
nameThe name of the Executor
fail_if_not_foundWhether or not to fail if the executor doesn't exist. If this is false then this function will return a NullExecutor

Definition at line 2109 of file MooseApp.C.

2110 {
2111  auto it = _executors.find(name);
2112 
2113  if (it != _executors.end())
2114  return *it->second;
2115 
2116  if (fail_if_not_found)
2117  mooseError("Executor not found: ", name);
2118 
2119  return *_null_executor;
2120 }
std::map< std::string, std::shared_ptr< Executor > > _executors
Pointers to all of the Executors for this run.
Definition: MooseApp.h:1218
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:99
std::shared_ptr< NullExecutor > _null_executor
Used to return an executor that does nothing.
Definition: MooseApp.h:1234
if(!dmm->_nl) SETERRQ(PETSC_COMM_WORLD
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:267

◆ getExodusFileRestart()

bool MooseApp::getExodusFileRestart ( ) const
inline

Whether or not we need to use a separate Exodus reader to read the mesh BEFORE we create the mesh.

Definition at line 423 of file MooseApp.h.

Referenced by SetupMeshCompleteAction::act(), FileMesh::buildMesh(), FileMeshGenerator::generate(), and FEProblemBase::initialSetup().

423 { return _initial_from_file; }
bool _initial_from_file
This variable indicates when a request has been made to restart from an Exodus file.
Definition: MooseApp.h:1261

◆ getExReaderForRestart()

libMesh::ExodusII_IO* MooseApp::getExReaderForRestart ( ) const
inline

Get the Exodus reader to restart variables from an Exodus mesh file.

Definition at line 436 of file MooseApp.h.

Referenced by FEProblemBase::checkICRestartError(), and FEProblemBase::initialSetup().

436 { return _ex_reader.get(); }
std::shared_ptr< libMesh::ExodusII_IO > _ex_reader
The Exodus reader when _initial_from_file is set to true.
Definition: MooseApp.h:1264

◆ getFactory()

Factory& MooseApp::getFactory ( )
inline

Retrieve a writable reference to the Factory associated with this App.

Definition at line 394 of file MooseApp.h.

Referenced by AB2PredictorCorrector::AB2PredictorCorrector(), BatchMeshGeneratorAction::addMeshGenerators(), MeshGenerator::addMeshSubgenerator(), MooseServer::addValuesToList(), AStableDirk4::AStableDirk4(), BatchMeshGeneratorAction::BatchMeshGeneratorAction(), SingleRankPartitioner::clone(), RandomPartitioner::clone(), CopyMeshPartitioner::clone(), BlockWeightedPartitioner::clone(), GhostEverything::clone(), GhostLowerDElems::clone(), GhostHigherDLowerDPointNeighbors::clone(), PetscExternalPartitioner::clone(), LibmeshPartitioner::clone(), HierarchicalGridPartitioner::clone(), GridPartitioner::clone(), ElementSideNeighborLayers::clone(), ElementPointNeighborLayers::clone(), GhostBoundary::clone(), RedistributeProperties::clone(), ProxyRelationshipManager::clone(), SampledOutput::cloneMesh(), MooseBase::connectControllableParams(), MeshGeneratorSystem::createMeshGenerator(), ExtraIDIntegralReporter::ExtraIDIntegralReporter(), FunctorSmootherTempl< T >::FunctorSmootherTempl(), MooseServer::gatherDocumentDefinitionLocations(), MooseServer::getHoverDisplayText(), MooseServer::getObjectParameters(), MooseObject::MooseObject(), MultiAppGeneralFieldTransfer::MultiAppGeneralFieldTransfer(), OverlayMeshGenerator::OverlayMeshGenerator(), TiledMesh::safeClone(), FileMesh::safeClone(), ImageMesh::safeClone(), SpiralAnnularMesh::safeClone(), AnnularMesh::safeClone(), RinglebMesh::safeClone(), GeneratedMesh::safeClone(), ConcentricCircleMesh::safeClone(), MeshGeneratorMesh::safeClone(), StitchedMesh::safeClone(), PatternedMesh::safeClone(), MFEMMesh::safeClone(), TransientBase::setupTimeIntegrator(), and SideSetExtruderGenerator::SideSetExtruderGenerator().

394 { return _factory; }
Factory _factory
Definition: MooseApp.h:1250

◆ getFileName()

std::string MooseApp::getFileName ( bool  stripLeadingPath = true) const

Return the primary (first) filename that was parsed Note: When stripLeadingPath is false, this function returns the same name as getInputFileName() method when the input file is not a link.

Definition at line 2436 of file MooseApp.C.

Referenced by ProgressOutput::output().

2437 {
2438  return _builder.getPrimaryFileName(stripLeadingPath);
2439 }
std::string getPrimaryFileName(bool stripLeadingPath=true) const
Return the primary (first) filename that was parsed.
Definition: Builder.C:199
Moose::Builder _builder
Builder for building app related parser tree.
Definition: MooseApp.h:1191

◆ getFPTrapFlag()

bool MooseApp::getFPTrapFlag ( ) const
inline

Returns whether FPE trapping is turned on (either because of debug or user requested)

Definition at line 926 of file MooseApp.h.

926 { return _trap_fpe; }
bool _trap_fpe
Whether or not FPE trapping should be turned on.
Definition: MooseApp.h:1285

◆ getFrameworkVersion()

std::string MooseApp::getFrameworkVersion ( ) const

Returns the framework version.

Definition at line 1217 of file MooseApp.C.

1218 {
1219  return MOOSE_VERSION;
1220 }

◆ getGlobalTimeOffset()

Real MooseApp::getGlobalTimeOffset ( ) const
inline

Each App has it's own local time.

The "global" time of the whole problem might be different. This offset is how far off the local App time is from the global time.

Definition at line 305 of file MooseApp.h.

Referenced by Tecplot::output(), Exodus::outputEmptyTimestep(), Exodus::outputNodalVariables(), and TransientMultiApp::solveStep().

305 { return _global_time_offset; }
Real _global_time_offset
Offset of the local App time to the "global" problem time.
Definition: MooseApp.h:1163

◆ getHitNode()

const hit::Node* MooseBase::getHitNode ( ) const
inlineinherited
Returns
The block-level hit node for this object, if any

Definition at line 132 of file MooseBase.h.

Referenced by FEProblemBase::addAnyRedistributers(), MooseBase::callMooseError(), MooseBase::getHitNode(), and MooseBase::messagePrefix().

132 { return getHitNode(_pars); }
const InputParameters & _pars
The object&#39;s parameters.
Definition: MooseBase.h:362
const hit::Node * getHitNode() const
Definition: MooseBase.h:132

◆ getInputFileNames()

const std::vector< std::string > & MooseApp::getInputFileNames ( ) const
Returns
the input file names set in the Parser

Definition at line 1655 of file MooseApp.C.

Referenced by ConsoleUtils::outputFrameworkInformation(), Console::outputInput(), and setupOptions().

1656 {
1657  mooseAssert(_parser, "Parser is not set");
1658  return _parser->getInputFileNames();
1659 }
const std::shared_ptr< Parser > _parser
Parser for parsing the input file (owns the root hit node)
Definition: MooseApp.h:1182

◆ getInputParameterWarehouse()

InputParameterWarehouse & MooseApp::getInputParameterWarehouse ( )

◆ getInstallableInputs()

std::string MooseApp::getInstallableInputs ( ) const
privatevirtual

Method to retrieve the installable inputs from a given applications <app>Revision.h file.

Definition at line 2238 of file MooseApp.C.

Referenced by showInputs().

2239 {
2240  return "tests";
2241 }

◆ getInterfaceObjects()

template<class T >
const std::vector< T * > & MooseApp::getInterfaceObjects ( ) const

Gets the registered interface objects for a given interface.

For this to work, the interface must register itself using registerInterfaceObject.

Definition at line 1608 of file MooseApp.h.

Referenced by DeclareLateReportersAction::act(), ResolveOptionalMaterialPropertiesAction::act(), Coupleable::checkWritableVar(), PetscOutputInterface::petscLinearOutput(), PetscOutputInterface::petscNonlinearOutput(), and PetscOutput::solveSetup().

1609 {
1610  static_assert(!std::is_base_of<MooseObject, T>::value, "T is not an interface");
1611 
1612  const auto it = _interface_registry.find(typeid(T));
1613  if (it != _interface_registry.end())
1614  return static_cast<InterfaceRegistryObjects<T> *>(it->second.get())->_objects;
1615  const static std::vector<T *> empty;
1616  return empty;
1617 }
std::map< std::type_index, std::unique_ptr< InterfaceRegistryObjectsBase > > _interface_registry
Registration for interface objects.
Definition: MooseApp.h:1557

◆ getLastInputFileName()

const std::string & MooseApp::getLastInputFileName ( ) const
Returns
The last input filename set (if any)

Definition at line 1662 of file MooseApp.C.

Referenced by setupOptions().

1663 {
1664  mooseAssert(_parser, "Parser is not set");
1665  return _parser->getLastInputFileName();
1666 }
const std::shared_ptr< Parser > _parser
Parser for parsing the input file (owns the root hit node)
Definition: MooseApp.h:1182

◆ getLibrarySearchPaths()

std::set< std::string > MooseApp::getLibrarySearchPaths ( const std::string &  library_path_from_param) const

Return the paths searched by MOOSE when loading libraries.

Definition at line 2874 of file MooseApp.C.

Referenced by dynamicAppRegistration(), and dynamicRegistration().

2875 {
2876  std::set<std::string> paths;
2877 
2878  if (!library_path.empty())
2879  {
2880  std::vector<std::string> tmp_paths;
2881  MooseUtils::tokenize(library_path, tmp_paths, 1, ":");
2882 
2883  paths.insert(tmp_paths.begin(), tmp_paths.end());
2884  }
2885 
2886  char * moose_lib_path_env = std::getenv("MOOSE_LIBRARY_PATH");
2887  if (moose_lib_path_env)
2888  {
2889  std::string moose_lib_path(moose_lib_path_env);
2890  std::vector<std::string> tmp_paths;
2891  MooseUtils::tokenize(moose_lib_path, tmp_paths, 1, ":");
2892 
2893  paths.insert(tmp_paths.begin(), tmp_paths.end());
2894  }
2895 
2896  return paths;
2897 }
void tokenize(const std::string &str, std::vector< T > &elements, unsigned int min_len=1, const std::string &delims="/")
This function will split the passed in string on a set of delimiters appending the substrings to the ...

◆ getLibtorchDevice()

torch::DeviceType MooseApp::getLibtorchDevice ( ) const
inline

Get the device torch is supposed to be running on.

Definition at line 104 of file MooseApp.h.

104 { return _libtorch_device; }
const torch::DeviceType _libtorch_device
The libtorch device this app is using (converted from compute_device)
Definition: MooseApp.h:1567

◆ getLoadedLibraryPaths()

std::set< std::string > MooseApp::getLoadedLibraryPaths ( ) const

Return the paths of loaded libraries.

Definition at line 2863 of file MooseApp.C.

Referenced by Factory::reportUnregisteredError().

2864 {
2865  // Return the paths but not the open file handles
2866  std::set<std::string> paths;
2867  for (const auto & it : _lib_handles)
2868  paths.insert(it.first);
2869 
2870  return paths;
2871 }
std::unordered_map< std::string, DynamicLibraryInfo > _lib_handles
The library archive (name only), registration method and the handle to the method.
Definition: MooseApp.h:1323

◆ getMeshGenerator()

const MeshGenerator& MooseApp::getMeshGenerator ( const std::string &  name) const
inline
Returns
The MeshGenerator with the name name.

Definition at line 867 of file MooseApp.h.

Referenced by MeshGenerator::generateInternal().

868  {
870  }
MeshGeneratorSystem _mesh_generator_system
The system that manages the MeshGenerators.
Definition: MooseApp.h:1522
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:99
const MeshGenerator & getMeshGenerator(const std::string &name) const

◆ getMeshGeneratorMesh()

std::unique_ptr<MeshBase> MooseApp::getMeshGeneratorMesh ( )
inline
Returns
The final mesh generated by the mesh generator system

Definition at line 875 of file MooseApp.h.

876  {
878  }
std::unique_ptr< libMesh::MeshBase > getSavedMesh(const std::string &name)
Get the saved mesh by name.
MeshGeneratorSystem _mesh_generator_system
The system that manages the MeshGenerators.
Definition: MooseApp.h:1522
static std::string mainMeshGeneratorName()
The name reserved for the "main" mesh generator which is the one used for the numerical solver downst...

◆ getMeshGeneratorNames()

std::vector<std::string> MooseApp::getMeshGeneratorNames ( ) const
inline
Returns
The names of all mesh generators

See MeshGeneratorSystem::getMeshGeneratorNames()

Definition at line 885 of file MooseApp.h.

Referenced by SetupMeshAction::act().

886  {
888  }
std::vector< std::string > getMeshGeneratorNames() const
Get names of all mesh generators Note: This function should be called after all mesh generators are a...
MeshGeneratorSystem _mesh_generator_system
The system that manages the MeshGenerators.
Definition: MooseApp.h:1522

◆ getMeshGeneratorSystem()

MeshGeneratorSystem& MooseApp::getMeshGeneratorSystem ( )
inline

◆ getMFEMDevice()

std::shared_ptr<mfem::Device> MooseApp::getMFEMDevice ( Moose::PassKey< MultiApp )
inline

Get the MFEM device object.

Definition at line 1079 of file MooseApp.h.

Referenced by MultiApp::createApp().

1079 { return _mfem_device; }
std::shared_ptr< mfem::Device > _mfem_device
The MFEM Device object.
Definition: MooseApp.h:1572

◆ getMFEMDevices()

const std::set< std::string > & MooseApp::getMFEMDevices ( Moose::PassKey< MultiApp ) const
inline

Get the configured MFEM devices.

Definition at line 1621 of file MooseApp.h.

Referenced by MultiApp::createApp().

1622 {
1623  return _mfem_devices;
1624 }
std::set< std::string > _mfem_devices
MFEM supported devices based on user-provided config.
Definition: MooseApp.h:1575

◆ getMooseApp()

MooseApp& MooseBase::getMooseApp ( ) const
inlineinherited

Get the MooseApp this class is associated with.

Definition at line 83 of file MooseBase.h.

Referenced by ChainControlSetupAction::act(), AddDefaultConvergenceAction::addDefaultMultiAppFixedPointConvergence(), AddDefaultConvergenceAction::addDefaultNonlinearConvergence(), AddDefaultConvergenceAction::addDefaultSteadyStateConvergence(), FEProblemBase::advanceState(), ParsedChainControl::buildFunction(), ReporterTransferInterface::checkHasReporterValue(), AddDefaultConvergenceAction::checkUnusedMultiAppFixedPointConvergenceParameters(), AddDefaultConvergenceAction::checkUnusedNonlinearConvergenceParameters(), AddDefaultConvergenceAction::checkUnusedSteadyStateConvergenceParameters(), Coupleable::checkWritableVar(), ComponentPhysicsInterface::ComponentPhysicsInterface(), Coupleable::Coupleable(), MortarData::createMortarInterface(), EigenProblem::doFreeNonlinearPowerIterations(), Terminator::execute(), FEProblemSolve::FEProblemSolve(), SolutionInvalidInterface::flagInvalidSolutionInternal(), ChainControl::getChainControlDataSystem(), DefaultConvergenceBase::getSharedExecutionerParam(), ChainControlDataPostprocessor::initialSetup(), MaterialPropertyInterface::MaterialPropertyInterface(), MooseVariableDataFV< OutputType >::MooseVariableDataFV(), ProgressOutput::output(), PetscOutputInterface::petscLinearOutput(), PetscOutputInterface::petscNonlinearOutput(), PetscOutputInterface::PetscOutputInterface(), PostprocessorInterface::postprocessorsAdded(), MultiApp::preTransfer(), Reporter::Reporter(), ReporterInterface::reportersAdded(), MultiApp::restore(), and VectorPostprocessorInterface::vectorPostprocessorsAdded().

83 { return _app; }
MooseApp & _app
The MOOSE application this is associated with.
Definition: MooseBase.h:353

◆ getNullExecutor()

NullExecutor* MooseApp::getNullExecutor ( ) const
inline

Definition at line 329 of file MooseApp.h.

Referenced by ExecutorInterface::getExecutor().

329 { return _null_executor.get(); }
std::shared_ptr< NullExecutor > _null_executor
Used to return an executor that does nothing.
Definition: MooseApp.h:1234

◆ getOutputFileBase()

std::string MooseApp::getOutputFileBase ( bool  for_non_moose_build_output = false) const

Get the output file base name.

Parameters
for_non_moose_build_outputTrue for getting the file base for outputs generated with Outputs/[outputname] input syntax.
Returns
The file base name used by output objects Note: for_non_moose_build_output does not affect the returned value when this is a subapp. for_non_moose_build_output also does not affect the returned value when Outputs/file_base parameter is available. When for_non_moose_build_output does affect the returned value, i.e. master without Outputs/file_base, the suffix _out is removed.

Definition at line 1669 of file MooseApp.C.

Referenced by getCheckpointDirectories(), OutputWarehouse::resetFileBase(), and MultiApp::setAppOutputFileBase().

1670 {
1671  if (_file_base_set_by_user || for_non_moose_build_output || _multiapp_level)
1672  return _output_file_base;
1673  else
1674  return _output_file_base + "_out";
1675 }
unsigned int _multiapp_level
Level of multiapp, the master is level 0. This used by the Console to indent output.
Definition: MooseApp.h:1507
bool _file_base_set_by_user
Whether or not file base is set through input or setOutputFileBase by MultiApp.
Definition: MooseApp.h:1148
std::string _output_file_base
The output file basename.
Definition: MooseApp.h:1145

◆ getOutputFileNumbers()

const std::map<std::string, unsigned int>& MooseApp::getOutputFileNumbers ( ) const
inline

Store a map of outputter names and file numbers The MultiApp system requires this to get the file numbering to propogate down through the multiapps.

See also
MultiApp TransientMultiApp

Definition at line 539 of file MooseApp.h.

Referenced by TransientMultiApp::setupApp().

540  {
541  return _output_file_numbers;
542  }
std::map< std::string, unsigned int > _output_file_numbers
Map of outputer name and file number (used by MultiApps to propagate file numbers down through the mu...
Definition: MooseApp.h:1296

◆ getOutputPosition()

Point MooseApp::getOutputPosition ( ) const
inline

Get the output position.

Returns
The position offset for the output.

Definition at line 275 of file MooseApp.h.

Referenced by MultiApp::createApp(), Exodus::output(), and MultiApp::parentOutputPositionChanged().

275 { return _output_position; }
Point _output_position
The output position.
Definition: MooseApp.h:1154

◆ getOutputWarehouse() [1/2]

OutputWarehouse & MooseApp::getOutputWarehouse ( )

◆ getOutputWarehouse() [2/2]

const OutputWarehouse & MooseApp::getOutputWarehouse ( ) const

Definition at line 2448 of file MooseApp.C.

2449 {
2450  return _output_warehouse;
2451 }
OutputWarehouse _output_warehouse
OutputWarehouse object for this App.
Definition: MooseApp.h:1179

◆ getParam() [1/2]

template<typename T >
const T & MooseBase::getParam ( const std::string &  name) const
inherited

Retrieve a parameter for the object.

Parameters
nameThe name of the parameter
Returns
The value of the parameter

Definition at line 384 of file MooseBase.h.

Referenced by CreateDisplacedProblemAction::act(), AddPeriodicBCAction::act(), CommonOutputAction::act(), FEProblemBase::addOutput(), DiffusionPhysicsBase::addPostprocessors(), ADNodalKernel::ADNodalKernel(), ArrayParsedAux::ArrayParsedAux(), AddPeriodicBCAction::autoTranslationBoundaries(), BicubicSplineFunction::BicubicSplineFunction(), ComponentPhysicsInterface::ComponentPhysicsInterface(), FunctorAux::computeValue(), Console::Console(), FEProblemBase::createTagSolutions(), CutMeshByLevelSetGenerator::CutMeshByLevelSetGenerator(), DebugResidualAux::DebugResidualAux(), AccumulateReporter::declareLateValues(), DerivativeParsedMaterialTempl< is_ad >::DerivativeParsedMaterialTempl(), DynamicObjectRegistrationAction::DynamicObjectRegistrationAction(), EigenKernel::EigenKernel(), ElementGroupCentroidPositions::ElementGroupCentroidPositions(), FEProblemSolve::FEProblemSolve(), FiniteDifferencePreconditioner::FiniteDifferencePreconditioner(), ParsedSubdomainGeneratorBase::functionInitialize(), FVInterfaceKernel::FVInterfaceKernel(), BoundaryLayerSubdomainGenerator::generate(), ExtraNodesetGenerator::generate(), FileMeshGenerator::generate(), RefineBlockGenerator::generate(), RefineSidesetGenerator::generate(), BlockDeletionGenerator::generate(), BreakMeshByBlockGenerator::generate(), CoarsenBlockGenerator::generate(), GeneratedMeshGenerator::generate(), MeshExtruderGenerator::generate(), GenericConstantRankTwoTensorTempl< is_ad >::GenericConstantRankTwoTensorTempl(), GenericConstantSymmetricRankTwoTensorTempl< is_ad >::GenericConstantSymmetricRankTwoTensorTempl(), getCheckpointDirectories(), DataFileInterface::getDataFileName(), ExecutorInterface::getExecutor(), GhostingUserObject::GhostingUserObject(), FixedPointIterationAdaptiveDT::init(), TimeSequenceStepper::init(), IterationAdaptiveDT::init(), AdvancedOutput::init(), AttribThread::initFrom(), AttribSysNum::initFrom(), AttribResidualObject::initFrom(), AttribDisplaced::initFrom(), BlockRestrictable::initializeBlockRestrictable(), BoundaryRestrictable::initializeBoundaryRestrictable(), Console::initialSetup(), SampledOutput::initSample(), IterationAdaptiveDT::limitDTToPostprocessorValue(), MooseMesh::MooseMesh(), MooseStaticCondensationPreconditioner::MooseStaticCondensationPreconditioner(), MooseVariableBase::MooseVariableBase(), MultiSystemSolveObject::MultiSystemSolveObject(), NEML2ModelExecutor::NEML2ModelExecutor(), NestedDivision::NestedDivision(), PerfGraphOutput::output(), Console::outputSystemInformation(), ParsedCurveGenerator::ParsedCurveGenerator(), ParsedElementDeletionGenerator::ParsedElementDeletionGenerator(), ParsedGenerateNodeset::ParsedGenerateNodeset(), ParsedGenerateSideset::ParsedGenerateSideset(), ParsedMaterialTempl< is_ad >::ParsedMaterialTempl(), ParsedNodeTransformGenerator::ParsedNodeTransformGenerator(), ParsedODEKernel::ParsedODEKernel(), ParsedPostprocessor::ParsedPostprocessor(), PiecewiseByBlockFunctorMaterialTempl< T >::PiecewiseByBlockFunctorMaterialTempl(), PiecewiseConstantByBlockMaterialTempl< is_ad >::PiecewiseConstantByBlockMaterialTempl(), ReferenceResidualInterface::ReferenceResidualInterface(), RenameBlockGenerator::RenameBlockGenerator(), Moose::FV::setInterpolationMethod(), SetupMeshAction::setupMesh(), Output::setWallTimeIntervalFromCommandLineParam(), SingleMatrixPreconditioner::SingleMatrixPreconditioner(), TimePeriod::TimePeriod(), UniqueExtraIDMeshGenerator::UniqueExtraIDMeshGenerator(), FunctorIC::value(), VariableCondensationPreconditioner::VariableCondensationPreconditioner(), and VectorOfPostprocessors::VectorOfPostprocessors().

385 {
386  return InputParameters::getParamHelper<T>(name, _pars);
387 }
const InputParameters & _pars
The object&#39;s parameters.
Definition: MooseBase.h:362
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:99

◆ getParam() [2/2]

template<typename T1 , typename T2 >
std::vector< std::pair< T1, T2 > > MooseBase::getParam ( const std::string &  param1,
const std::string &  param2 
) const
inherited

Retrieve two parameters and provide pair of parameters for the object.

Parameters
param1The name of first parameter
param2The name of second parameter
Returns
Vector of pairs of first and second parameters

Definition at line 421 of file MooseBase.h.

422 {
423  return _pars.get<T1, T2>(param1, param2);
424 }
const InputParameters & _pars
The object&#39;s parameters.
Definition: MooseBase.h:362
std::vector< std::pair< R1, R2 > > get(const std::string &param1, const std::string &param2) const
Combine two vector parameters into a single vector of pairs.

◆ getPrintableName()

virtual std::string MooseApp::getPrintableName ( ) const
inlinevirtual

Get printable name of the application.

Definition at line 135 of file MooseApp.h.

Referenced by getPrintableVersion().

135 { return "Application"; }

◆ getPrintableVersion()

std::string MooseApp::getPrintableVersion ( ) const

Non-virtual method for printing out the version string in a consistent format.

Definition at line 1229 of file MooseApp.C.

Referenced by setupOptions().

1230 {
1231  return getPrintableName() + " Version: " + getVersion();
1232 }
virtual std::string getPrintableName() const
Get printable name of the application.
Definition: MooseApp.h:135
virtual std::string getVersion() const
Returns the current version of the framework or application (default: framework version).
Definition: MooseApp.C:1223

◆ getRecoverableData()

const DataNames& MooseApp::getRecoverableData ( ) const
inline

Return a reference to the recoverable data object.

Returns
A const reference to the recoverable data

Definition at line 714 of file MooseApp.h.

Referenced by restore().

714 { return _recoverable_data_names; }
DataNames _recoverable_data_names
Data names that will only be read from the restart file during RECOVERY.
Definition: MooseApp.h:1200

◆ getRecoverFileBase()

std::string MooseApp::getRecoverFileBase ( ) const
inline

Definition at line 488 of file MooseApp.h.

489  {
490  mooseDeprecated("MooseApp::getRecoverFileBase is deprecated, use "
491  "MooseApp::getRestartRecoverFileBase() instead.");
492  return _restart_recover_base;
493  }
std::string _restart_recover_base
The base name to restart/recover from. If blank then we will find the newest checkpoint file...
Definition: MooseApp.h:1288
void mooseDeprecated(Args &&... args) const
Definition: MooseBase.h:310

◆ getRelationshipManagerInfo()

std::vector< std::pair< std::string, std::string > > MooseApp::getRelationshipManagerInfo ( ) const

Returns the Relationship managers info suitable for printing.

Definition at line 3352 of file MooseApp.C.

Referenced by ConsoleUtils::outputRelationshipManagerInformation().

3353 {
3354  std::vector<std::pair<std::string, std::string>> info_strings;
3355  info_strings.reserve(_relationship_managers.size());
3356 
3357  for (const auto & rm : _relationship_managers)
3358  {
3359  std::stringstream oss;
3360  oss << rm->getInfo();
3361 
3362  auto & for_whom = rm->forWhom();
3363 
3364  if (!for_whom.empty())
3365  {
3366  oss << " for ";
3367 
3368  std::copy(for_whom.begin(), for_whom.end(), infix_ostream_iterator<std::string>(oss, ", "));
3369  }
3370 
3371  info_strings.emplace_back(std::make_pair(Moose::stringify(rm->getType()), oss.str()));
3372  }
3373 
3374  // List the libMesh GhostingFunctors - Not that in libMesh all of the algebraic and coupling
3375  // Ghosting Functors are also attached to the mesh. This should catch them all.
3376  const auto & mesh = _action_warehouse.getMesh();
3377  if (mesh)
3378  {
3379  // Let us use an ordered map to avoid stochastic console behaviors.
3380  // I believe we won't have many RMs, and there is no performance issue.
3381  // Deterministic behaviors are good for setting up regression tests
3382  std::map<std::string, unsigned int> counts;
3383 
3384  for (auto & gf : as_range(mesh->getMesh().ghosting_functors_begin(),
3385  mesh->getMesh().ghosting_functors_end()))
3386  {
3387  const auto * gf_ptr = dynamic_cast<const RelationshipManager *>(gf);
3388  if (!gf_ptr)
3389  // Count how many occurences of the same Ghosting Functor types we are encountering
3390  counts[demangle(typeid(*gf).name())]++;
3391  }
3392 
3393  for (const auto & pair : counts)
3394  info_strings.emplace_back(std::make_pair(
3395  "Default", pair.first + (pair.second > 1 ? " x " + std::to_string(pair.second) : "")));
3396  }
3397 
3398  // List the libMesh GhostingFunctors - Not that in libMesh all of the algebraic and coupling
3399  // Ghosting Functors are also attached to the mesh. This should catch them all.
3400  const auto & d_mesh = _action_warehouse.getDisplacedMesh();
3401  if (d_mesh)
3402  {
3403  // Let us use an ordered map to avoid stochastic console behaviors.
3404  // I believe we won't have many RMs, and there is no performance issue.
3405  // Deterministic behaviors are good for setting up regression tests
3406  std::map<std::string, unsigned int> counts;
3407 
3408  for (auto & gf : as_range(d_mesh->getMesh().ghosting_functors_begin(),
3409  d_mesh->getMesh().ghosting_functors_end()))
3410  {
3411  const auto * gf_ptr = dynamic_cast<const RelationshipManager *>(gf);
3412  if (!gf_ptr)
3413  // Count how many occurences of the same Ghosting Functor types we are encountering
3414  counts[demangle(typeid(*gf).name())]++;
3415  }
3416 
3417  for (const auto & pair : counts)
3418  info_strings.emplace_back(
3419  std::make_pair("Default",
3420  pair.first + (pair.second > 1 ? " x " + std::to_string(pair.second) : "") +
3421  " for DisplacedMesh"));
3422  }
3423 
3424  return info_strings;
3425 }
GhostingFunctorIterator ghosting_functors_begin() const
const std::shared_ptr< MooseMesh > & getMesh() const
MeshBase & mesh
GhostingFunctorIterator ghosting_functors_end() const
ActionWarehouse _action_warehouse
Where built actions are stored.
Definition: MooseApp.h:1176
SimpleRange< IndexType > as_range(const std::pair< IndexType, IndexType > &p)
std::string stringify(const T &t)
conversion to string
Definition: Conversion.h:64
std::string demangle(const char *name)
RelationshipManagers are used for describing what kinds of non-local resources are needed for an obje...
const std::shared_ptr< MooseMesh > & getDisplacedMesh() const
std::set< std::shared_ptr< RelationshipManager > > _relationship_managers
The relationship managers that have been added.
Definition: MooseApp.h:1302

◆ getReleationshipManagers()

const std::vector<std::shared_ptr<RelationshipManager> >& MooseApp::getReleationshipManagers ( )

Retrieve the relationship managers.

◆ getRenamedParam()

template<typename T >
const T & MooseBase::getRenamedParam ( const std::string &  old_name,
const std::string &  new_name 
) const
inherited

Retrieve a renamed parameter for the object.

This helper makes sure we check both names before erroring, and that only one parameter is passed to avoid silent errors

Parameters
old_namethe old name for the parameter
new_namethe new name for the parameter

Definition at line 398 of file MooseBase.h.

399 {
400  // Most important: accept new parameter
401  if (isParamSetByUser(new_name) && !isParamValid(old_name))
402  return getParam<T>(new_name);
403  // Second most: accept old parameter
404  if (isParamValid(old_name) && !isParamSetByUser(new_name))
405  return getParam<T>(old_name);
406  // Third most: accept default for new parameter
407  if (isParamValid(new_name) && !isParamValid(old_name))
408  return getParam<T>(new_name);
409  // Refuse: no default, no value passed
410  if (!isParamValid(old_name) && !isParamValid(new_name))
411  mooseError("parameter '" + new_name +
412  "' is being retrieved without being set.\nDid you misspell it?");
413  // Refuse: both old and new parameters set by user
414  else
415  mooseError("Parameter '" + new_name + "' may not be provided alongside former parameter '" +
416  old_name + "'");
417 }
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:267
bool isParamValid(const std::string &name) const
Test if the supplied parameter is valid.
Definition: MooseBase.h:195
bool isParamSetByUser(const std::string &name) const
Test if the supplied parameter is set by a user, as opposed to not set or set to default.
Definition: MooseBase.h:201

◆ getRestartableData() [1/2]

const std::vector<RestartableDataMap>& MooseApp::getRestartableData ( ) const
inline

Return reference to the restartable data object.

Returns
A reference to the restartable data object

Definition at line 680 of file MooseApp.h.

680 { return _restartable_data; }
std::vector< RestartableDataMap > _restartable_data
Where the restartable data is held (indexed on tid)
Definition: MooseApp.h:1194

◆ getRestartableData() [2/2]

std::vector<RestartableDataMap>& MooseApp::getRestartableData ( )
inline

Definition at line 681 of file MooseApp.h.

681 { return _restartable_data; }
std::vector< RestartableDataMap > _restartable_data
Where the restartable data is held (indexed on tid)
Definition: MooseApp.h:1194

◆ getRestartableDataMap()

RestartableDataMap & MooseApp::getRestartableDataMap ( const RestartableDataMapName name)

Return a reference to restartable data for the specific type flag.

Definition at line 3460 of file MooseApp.C.

Referenced by getRestartableMetaData(), possiblyLoadRestartableMetaData(), and writeRestartableMetaData().

3461 {
3462  auto iter = _restartable_meta_data.find(name);
3463  if (iter == _restartable_meta_data.end())
3464  mooseError("Unable to find RestartableDataMap object for the supplied name '",
3465  name,
3466  "', did you call registerRestartableDataMapName in the application constructor?");
3467  return iter->second.first;
3468 }
std::unordered_map< RestartableDataMapName, std::pair< RestartableDataMap, std::string > > _restartable_meta_data
General storage for custom RestartableData that can be added to from outside applications.
Definition: MooseApp.h:1494
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:99
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:267

◆ getRestartableDataMapBegin()

auto MooseApp::getRestartableDataMapBegin ( )
inline

Iterator based access to the extra RestartableDataMap objects; see Checkpoint.C for use case.

These are MOOSE internal functions and should not be used otherwise.

Definition at line 1026 of file MooseApp.h.

Referenced by SetupDebugAction::act().

1026 { return _restartable_meta_data.begin(); }
std::unordered_map< RestartableDataMapName, std::pair< RestartableDataMap, std::string > > _restartable_meta_data
General storage for custom RestartableData that can be added to from outside applications.
Definition: MooseApp.h:1494

◆ getRestartableDataMapEnd()

auto MooseApp::getRestartableDataMapEnd ( )
inline

Definition at line 1028 of file MooseApp.h.

Referenced by SetupDebugAction::act().

1028 { return _restartable_meta_data.end(); }
std::unordered_map< RestartableDataMapName, std::pair< RestartableDataMap, std::string > > _restartable_meta_data
General storage for custom RestartableData that can be added to from outside applications.
Definition: MooseApp.h:1494

◆ getRestartableDataMapName()

const std::string & MooseApp::getRestartableDataMapName ( const RestartableDataMapName name) const
Returns
The output name for the restartable data with name name

Definition at line 3487 of file MooseApp.C.

Referenced by possiblyLoadRestartableMetaData(), and writeRestartableMetaData().

3488 {
3489  const auto it = _restartable_meta_data.find(name);
3490  if (it == _restartable_meta_data.end())
3491  mooseError("MooseApp::getRestartableDataMapName: The name '", name, "' is not registered");
3492  return it->second.second;
3493 }
std::unordered_map< RestartableDataMapName, std::pair< RestartableDataMap, std::string > > _restartable_meta_data
General storage for custom RestartableData that can be added to from outside applications.
Definition: MooseApp.h:1494
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:99
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:267

◆ getRestartableMetaData()

RestartableDataValue & MooseApp::getRestartableMetaData ( const std::string &  name,
const RestartableDataMapName metaname,
THREAD_ID  tid 
)

Definition at line 2544 of file MooseApp.C.

Referenced by MeshMetaDataInterface::getMeshPropertyInternal(), and MeshGenerator::setMeshPropertyHelper().

2547 {
2548  if (tid != 0)
2549  mooseError(
2550  "The meta data storage for '", metaname, "' is not threaded, so the tid must be zero.");
2551 
2552  // Get metadata reference from RestartableDataMap and return a (non-const) reference to its value
2553  auto & restartable_data_map = getRestartableDataMap(metaname);
2554  RestartableDataValue * const data = restartable_data_map.findData(name);
2555  if (!data)
2556  mooseError("Unable to find RestartableDataValue object with name " + name +
2557  " in RestartableDataMap");
2558 
2559  return *data;
2560 }
RestartableDataMap & getRestartableDataMap(const RestartableDataMapName &name)
Return a reference to restartable data for the specific type flag.
Definition: MooseApp.C:3460
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:99
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:267
Abstract definition of a RestartableData value.

◆ getRestartRecoverFileBase()

std::string MooseApp::getRestartRecoverFileBase ( ) const
inline

The file_base for the recovery file.

Definition at line 487 of file MooseApp.h.

Referenced by SetupRecoverFileBaseAction::act(), MooseMesh::init(), and FEProblemBase::initialSetup().

487 { return _restart_recover_base; }
std::string _restart_recover_base
The base name to restart/recover from. If blank then we will find the newest checkpoint file...
Definition: MooseApp.h:1288

◆ getRMClone()

RelationshipManager & MooseApp::getRMClone ( const RelationshipManager template_rm,
const MeshBase mesh 
) const
private

Return the relationship manager clone originally created from the provided template relationship manager and mesh.

Definition at line 3111 of file MooseApp.C.

Referenced by removeRelationshipManager().

3112 {
3113  auto outer_it = _template_to_clones.find(&template_rm);
3114  if (outer_it == _template_to_clones.end())
3115  mooseError("The template rm does not exist in our _template_to_clones map");
3116 
3117  auto & mesh_to_clone_map = outer_it->second;
3118  auto inner_it = mesh_to_clone_map.find(&mesh);
3119  if (inner_it == mesh_to_clone_map.end())
3120  mooseError("We should have the mesh key in our mesh");
3121 
3122  return *inner_it->second;
3123 }
std::map< const RelationshipManager *, std::map< const MeshBase *, std::unique_ptr< RelationshipManager > > > _template_to_clones
Map from a template relationship manager to a map in which the key-value pairs represent the MeshBase...
Definition: MooseApp.h:1554
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:267

◆ getStartTime()

Real MooseApp::getStartTime ( ) const
inline
Returns
The start time

Definition at line 293 of file MooseApp.h.

Referenced by FEProblemBase::initialSetup(), and TransientBase::TransientBase().

293 { return _start_time; }
Real _start_time
The time at which to start the simulation.
Definition: MooseApp.h:1160

◆ getSystemInfo()

const SystemInfo& MooseApp::getSystemInfo ( ) const
inline

Get SystemInfo object.

Returns
A pointer to the SystemInformation object

Definition at line 554 of file MooseApp.h.

Referenced by ConsoleUtils::outputFrameworkInformation(), and to_json().

554 { return _sys_info; }
SystemInfo _sys_info
System Information.
Definition: MooseApp.h:1188

◆ getVersion()

std::string MooseApp::getVersion ( ) const
virtual

Returns the current version of the framework or application (default: framework version).

Definition at line 1223 of file MooseApp.C.

Referenced by getPrintableVersion().

1224 {
1225  return MOOSE_VERSION;
1226 }

◆ hasBase()

bool MooseBase::hasBase ( ) const
inlineinherited
Returns
Whether or not this object has a registered base (set via InputParameters::registerBase())

Definition at line 138 of file MooseBase.h.

138 { return _pars.hasBase(); }
const InputParameters & _pars
The object&#39;s parameters.
Definition: MooseBase.h:362
bool hasBase() const

◆ hasInitialBackup()

bool MooseApp::hasInitialBackup ( ) const
inline
Returns
Whether or not this app currently has an "initial" backup

See _initial_backup and restoreFromInitialBackup() for more info.

Definition at line 994 of file MooseApp.h.

Referenced by FEProblemBase::initialSetup(), and restoreFromInitialBackup().

995  {
996  return _initial_backup != nullptr && *_initial_backup != nullptr;
997  }
std::unique_ptr< Backup > *const _initial_backup
The backup for use in initial setup; this will get set from the _initial_backup input parameter that ...
Definition: MooseApp.h:1563

◆ hasMeshGenerator()

bool MooseApp::hasMeshGenerator ( const MeshGeneratorName &  name) const
inline
Returns
Whether or not a mesh generator exists with the name name.

Definition at line 859 of file MooseApp.h.

860  {
862  }
MeshGeneratorSystem _mesh_generator_system
The system that manages the MeshGenerators.
Definition: MooseApp.h:1522
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:99
bool hasMeshGenerator(const MeshGeneratorName &name) const

◆ hasOutputPosition()

bool MooseApp::hasOutputPosition ( ) const
inline

Whether or not an output position has been set.

Returns
True if it has

Definition at line 269 of file MooseApp.h.

Referenced by Exodus::output().

269 { return _output_position_set; }
bool _output_position_set
Whether or not an output position has been set for this app.
Definition: MooseApp.h:1151

◆ hasRecoverFileBase()

bool MooseApp::hasRecoverFileBase ( ) const

Definition at line 1825 of file MooseApp.C.

1826 {
1827  mooseDeprecated("MooseApp::hasRecoverFileBase is deprecated, use "
1828  "MooseApp::hasRestartRecoverFileBase() instead.");
1829  return !_restart_recover_base.empty();
1830 }
std::string _restart_recover_base
The base name to restart/recover from. If blank then we will find the newest checkpoint file...
Definition: MooseApp.h:1288
void mooseDeprecated(Args &&... args) const
Definition: MooseBase.h:310

◆ hasRelationshipManager()

bool MooseApp::hasRelationshipManager ( const std::string &  name) const

Returns a Boolean indicating whether a RelationshipManater exists with the same name.

Definition at line 2998 of file MooseApp.C.

2999 {
3000  return std::find_if(_relationship_managers.begin(),
3001  _relationship_managers.end(),
3002  [&name](const std::shared_ptr<RelationshipManager> & rm)
3003  { return rm->name() == name; }) != _relationship_managers.end();
3004 }
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:99
std::set< std::shared_ptr< RelationshipManager > > _relationship_managers
The relationship managers that have been added.
Definition: MooseApp.h:1302

◆ hasRestartableDataMap()

bool MooseApp::hasRestartableDataMap ( const RestartableDataMapName name) const
Returns
Whether or not the restartable data has the given name registered.

Definition at line 3471 of file MooseApp.C.

3472 {
3473  return _restartable_meta_data.count(name);
3474 }
std::unordered_map< RestartableDataMapName, std::pair< RestartableDataMap, std::string > > _restartable_meta_data
General storage for custom RestartableData that can be added to from outside applications.
Definition: MooseApp.h:1494
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:99

◆ hasRestartableMetaData()

bool MooseApp::hasRestartableMetaData ( const std::string &  name,
const RestartableDataMapName metaname 
) const

Definition at line 2534 of file MooseApp.C.

Referenced by MeshMetaDataInterface::hasMeshProperty().

2536 {
2537  auto it = _restartable_meta_data.find(metaname);
2538  if (it == _restartable_meta_data.end())
2539  return false;
2540  return it->second.first.hasData(name);
2541 }
std::unordered_map< RestartableDataMapName, std::pair< RestartableDataMap, std::string > > _restartable_meta_data
General storage for custom RestartableData that can be added to from outside applications.
Definition: MooseApp.h:1494
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:99

◆ hasRestartRecoverFileBase()

bool MooseApp::hasRestartRecoverFileBase ( ) const

Return true if the recovery file base is set.

Definition at line 1819 of file MooseApp.C.

1820 {
1821  return !_restart_recover_base.empty();
1822 }
std::string _restart_recover_base
The base name to restart/recover from. If blank then we will find the newest checkpoint file...
Definition: MooseApp.h:1288

◆ hasRMClone()

bool MooseApp::hasRMClone ( const RelationshipManager template_rm,
const MeshBase mesh 
) const
private
Returns
whether we have created any clones for the provided template relationship manager and mesh yet. This may be false for instance when we are in the initial add relationship manager stage and haven't attempted attaching any relationship managers to the mesh or dof map yet (which is when we generate the clones). It's also maybe possible that we've created a clone of a given template_rm but not for the provided mesh so we return false in that case as well

Definition at line 3103 of file MooseApp.C.

Referenced by removeRelationshipManager().

3104 {
3105  auto it = _template_to_clones.find(&template_rm);
3106  // C++ does short circuiting so we're safe here
3107  return (it != _template_to_clones.end()) && (it->second.find(&mesh) != it->second.end());
3108 }
std::map< const RelationshipManager *, std::map< const MeshBase *, std::unique_ptr< RelationshipManager > > > _template_to_clones
Map from a template relationship manager to a map in which the key-value pairs represent the MeshBase...
Definition: MooseApp.h:1554

◆ hasStartTime()

bool MooseApp::hasStartTime ( ) const
inline
Returns
Whether or not a start time has been programmatically set using setStartTime()

Definition at line 288 of file MooseApp.h.

Referenced by FEProblemBase::initialSetup(), and TransientBase::TransientBase().

288 { return _start_time_set; }
bool _start_time_set
Whether or not an start time has been set.
Definition: MooseApp.h:1157

◆ header()

std::string MooseApp::header ( ) const
virtual

Returns a string to be printed at the beginning of a simulation.

Definition at line 2906 of file MooseApp.C.

Referenced by restore(), and setupOptions().

2907 {
2908  return std::string("");
2909 }

◆ isParamSetByUser()

bool MooseBase::isParamSetByUser ( const std::string &  name) const
inlineinherited

Test if the supplied parameter is set by a user, as opposed to not set or set to default.

Parameters
nameThe name of the parameter to test

Definition at line 201 of file MooseBase.h.

Referenced by SetupDebugAction::act(), ADConservativeAdvectionBC::ADConservativeAdvectionBC(), DiffusionCG::addFEBCs(), DiffusionPhysicsBase::addInitialConditions(), MFEMMesh::buildMesh(), LibtorchNeuralNetControl::conditionalParameterError(), copyInputs(), DiffusionPhysicsBase::DiffusionPhysicsBase(), ElementSubdomainModifierBase::ElementSubdomainModifierBase(), errorCheck(), MooseBase::getRenamedParam(), DefaultConvergenceBase::getSharedExecutionerParam(), AddVariableAction::init(), PhysicsBase::initializePhysics(), ElementSubdomainModifierBase::initialSetup(), MatrixSymmetryCheck::MatrixSymmetryCheck(), MeshDiagnosticsGenerator::MeshDiagnosticsGenerator(), MultiAppGeneralFieldTransfer::MultiAppGeneralFieldTransfer(), SolutionInvalidityOutput::output(), Output::Output(), MultiAppGeneralFieldTransfer::outputValueConflicts(), PetscExternalPartitioner::partition(), PiecewiseTabularBase::PiecewiseTabularBase(), MooseMesh::prepare(), SolutionUserObjectBase::readXda(), PhysicsBase::reportPotentiallyMissedParameters(), runInputFile(), runInputs(), MFEMSolverBase::setPreconditioner(), SetupMeshAction::setupMesh(), setupOptions(), SideSetsFromBoundingBoxGenerator::SideSetsFromBoundingBoxGenerator(), TimedSubdomainModifier::TimedSubdomainModifier(), and XYDelaunayGenerator::XYDelaunayGenerator().

202  {
203  return _pars.isParamSetByUser(name);
204  }
const InputParameters & _pars
The object&#39;s parameters.
Definition: MooseBase.h:362
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:99
bool isParamSetByUser(const std::string &name) const
Method returns true if the parameter was set by the user.

◆ isParamValid()

bool MooseBase::isParamValid ( const std::string &  name) const
inlineinherited

Test if the supplied parameter is valid.

Parameters
nameThe name of the parameter to test

Definition at line 195 of file MooseBase.h.

Referenced by HierarchicalGridPartitioner::_do_partition(), GridPartitioner::_do_partition(), CopyNodalVarsAction::act(), SetupMeshAction::act(), SetupDebugAction::act(), ComposeTimeStepperAction::act(), AddVariableAction::act(), CreateDisplacedProblemAction::act(), SetAdaptivityOptionsAction::act(), CommonOutputAction::act(), ADConservativeAdvectionBC::ADConservativeAdvectionBC(), DiffusionCG::addFEKernels(), DiffusionFV::addFVBCs(), DiffusionFV::addFVKernels(), DiffusionPhysicsBase::addInitialConditions(), CylinderComponent::addMeshGenerators(), AddPeriodicBCAction::AddPeriodicBCAction(), DiffusionPhysicsBase::addPostprocessors(), AdvectiveFluxAux::AdvectiveFluxAux(), ArrayHFEMDirichletBC::ArrayHFEMDirichletBC(), ArrayVarReductionAux::ArrayVarReductionAux(), AddPeriodicBCAction::autoTranslationBoundaries(), BicubicSplineFunction::BicubicSplineFunction(), BlockDeletionGenerator::BlockDeletionGenerator(), TimedSubdomainModifier::buildFromFile(), PiecewiseTabularBase::buildFromFile(), PiecewiseTabularBase::buildFromJSON(), ParsedChainControl::buildFunction(), GeneratedMesh::buildMesh(), MooseMesh::buildTypedMesh(), CartesianGridDivision::CartesianGridDivision(), CartesianMeshGenerator::CartesianMeshGenerator(), MultiAppTransfer::checkParentAppUserObjectExecuteOn(), LibmeshPartitioner::clone(), SampledOutput::cloneMesh(), CombinerGenerator::CombinerGenerator(), FunctorAux::computeValue(), ConservativeAdvectionTempl< is_ad >::ConservativeAdvectionTempl(), FEProblemSolve::convergenceSetup(), CopyMeshPartitioner::CopyMeshPartitioner(), CSVReaderVectorPostprocessor::CSVReaderVectorPostprocessor(), CutMeshByLevelSetGeneratorBase::CutMeshByLevelSetGeneratorBase(), ConstantReporter::declareConstantReporterValue(), ConstantReporter::declareConstantReporterValues(), DGKernelBase::DGKernelBase(), DiffusionFluxAux::DiffusionFluxAux(), DomainUserObject::DomainUserObject(), DynamicObjectRegistrationAction::DynamicObjectRegistrationAction(), Eigenvalue::Eigenvalue(), ElementGroupCentroidPositions::ElementGroupCentroidPositions(), PIDTransientControl::execute(), MultiAppNearestNodeTransfer::execute(), MultiAppUserObjectTransfer::execute(), Exodus::Exodus(), ExtraIDIntegralReporter::ExtraIDIntegralReporter(), ExtraIDIntegralVectorPostprocessor::ExtraIDIntegralVectorPostprocessor(), FEProblemBase::FEProblemBase(), FEProblemSolve::FEProblemSolve(), FileOutput::FileOutput(), SpatialUserObjectVectorPostprocessor::fillPoints(), CombinerGenerator::fillPositions(), MultiApp::fillPositions(), FiniteDifferencePreconditioner::FiniteDifferencePreconditioner(), FixedPointSolve::FixedPointSolve(), FunctionDT::FunctionDT(), FunctionValuePostprocessor::FunctionValuePostprocessor(), FVInterfaceKernel::FVInterfaceKernel(), FVMassMatrix::FVMassMatrix(), FileMeshGenerator::generate(), AddMetaDataGenerator::generate(), BreakBoundaryOnSubdomainGenerator::generate(), ElementGenerator::generate(), ExtraNodesetGenerator::generate(), LowerDBlockFromSidesetGenerator::generate(), SubdomainPerElementGenerator::generate(), BlockDeletionGenerator::generate(), GeneratedMeshGenerator::generate(), ParsedSubdomainGeneratorBase::generate(), MeshExtruderGenerator::generate(), ParsedExtraElementIDGenerator::generate(), XYZDelaunayGenerator::generate(), XYDelaunayGenerator::generate(), XYMeshLineCutter::generate(), SubdomainBoundingBoxGenerator::generate(), DistributedRectilinearMeshGenerator::generate(), PropertyReadFile::getFileNames(), MultiAppNearestNodeTransfer::getLocalEntitiesAndComponents(), MeshGenerator::getMeshGeneratorNameFromParam(), MeshGenerator::getMeshGeneratorNamesFromParam(), MooseBase::getRenamedParam(), MultiAppNearestNodeTransfer::getTargetLocalNodes(), Terminator::handleMessage(), HFEMDirichletBC::HFEMDirichletBC(), EigenExecutionerBase::init(), IterationAdaptiveDT::init(), Eigenvalue::init(), AdvancedOutput::initExecutionTypes(), BlockRestrictable::initializeBlockRestrictable(), BoundaryRestrictable::initializeBoundaryRestrictable(), MultiAppCloneReporterTransfer::initialSetup(), SolutionIC::initialSetup(), MultiAppVariableValueSampleTransfer::initialSetup(), PiecewiseTabularBase::initialSetup(), ParsedConvergence::initialSetup(), SolutionScalarAux::initialSetup(), SolutionAux::initialSetup(), Console::initialSetup(), MooseParsedVectorFunction::initialSetup(), MultiAppGeneralFieldTransfer::initialSetup(), MooseParsedGradFunction::initialSetup(), MooseParsedFunction::initialSetup(), SampledOutput::initSample(), IterationAdaptiveDT::IterationAdaptiveDT(), LeastSquaresFit::LeastSquaresFit(), LibmeshPartitioner::LibmeshPartitioner(), LibtorchNeuralNetControl::LibtorchNeuralNetControl(), MassMatrix::MassMatrix(), MatCoupledForce::MatCoupledForce(), MatDiffusionBase< Real >::MatDiffusionBase(), MeshGeneratorComponent::MeshGeneratorComponent(), MFEMProblemSolve::MFEMProblemSolve(), MooseMesh::MooseMesh(), MoosePreconditioner::MoosePreconditioner(), MooseStaticCondensationPreconditioner::MooseStaticCondensationPreconditioner(), MooseVariableBase::MooseVariableBase(), MooseVariableFV< Real >::MooseVariableFV(), MortarConstraintBase::MortarConstraintBase(), MoveNodeGenerator::MoveNodeGenerator(), MultiApp::MultiApp(), MultiAppCloneReporterTransfer::MultiAppCloneReporterTransfer(), MultiAppGeneralFieldNearestLocationTransfer::MultiAppGeneralFieldNearestLocationTransfer(), MultiAppGeneralFieldShapeEvaluationTransfer::MultiAppGeneralFieldShapeEvaluationTransfer(), MultiAppGeneralFieldTransfer::MultiAppGeneralFieldTransfer(), MultiAppGeneralFieldUserObjectTransfer::MultiAppGeneralFieldUserObjectTransfer(), MultiAppPostprocessorInterpolationTransfer::MultiAppPostprocessorInterpolationTransfer(), MultiAppPostprocessorTransfer::MultiAppPostprocessorTransfer(), MultiAppReporterTransfer::MultiAppReporterTransfer(), MultiAppTransfer::MultiAppTransfer(), MultiAppUserObjectTransfer::MultiAppUserObjectTransfer(), MultiAppVariableValueSampleTransfer::MultiAppVariableValueSampleTransfer(), MultiSystemSolveObject::MultiSystemSolveObject(), NodeSetsGeneratorBase::NodeSetsGeneratorBase(), EigenExecutionerBase::normalizeSolution(), Output::Output(), MultiAppGeneralFieldTransfer::outputValueConflicts(), ParsedCurveGenerator::ParsedCurveGenerator(), PetscOutput::PetscOutput(), PhysicsBasedPreconditioner::PhysicsBasedPreconditioner(), PIDTransientControl::PIDTransientControl(), PiecewiseTabularBase::PiecewiseTabularBase(), PlaneIDMeshGenerator::PlaneIDMeshGenerator(), MooseMesh::prepare(), MooseBase::queryParam(), MultiApp::readCommandLineArguments(), SolutionUserObjectBase::readExodusII(), ReferenceResidualInterface::ReferenceResidualInterface(), RenameBlockGenerator::RenameBlockGenerator(), ReporterPointSource::ReporterPointSource(), PhysicsBase::reportPotentiallyMissedParameters(), ParsedSubdomainMeshGenerator::setBlockName(), MooseMesh::setCoordSystem(), FileOutput::setFileBase(), FileOutput::setFileBaseInternal(), Split::setup(), SideSetsGeneratorBase::setup(), SetupMeshAction::setupMesh(), setupOptions(), Output::setWallTimeIntervalFromCommandLineParam(), SideDiffusiveFluxIntegralTempl< is_ad, Real >::SideDiffusiveFluxIntegralTempl(), SideSetsGeneratorBase::SideSetsGeneratorBase(), SolutionUserObjectBase::SolutionUserObjectBase(), WebServerControl::startServer(), Terminator::Terminator(), TimeIntervalTimes::TimeIntervalTimes(), TimePeriod::TimePeriod(), MultiAppDofCopyTransfer::transfer(), TransformGenerator::TransformGenerator(), TransientBase::TransientBase(), FunctorIC::value(), VariableCondensationPreconditioner::VariableCondensationPreconditioner(), VectorMagnitudeFunctorMaterialTempl< is_ad >::VectorMagnitudeFunctorMaterialTempl(), WebServerControl::WebServerControl(), XYDelaunayGenerator::XYDelaunayGenerator(), and XYZDelaunayGenerator::XYZDelaunayGenerator().

195 { return _pars.isParamValid(name); }
const InputParameters & _pars
The object&#39;s parameters.
Definition: MooseBase.h:362
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:99
bool isParamValid(const std::string &name) const
This method returns parameters that have been initialized in one fashion or another, i.e.

◆ isRecovering()

bool MooseApp::isRecovering ( ) const

◆ isRestarting()

bool MooseApp::isRestarting ( ) const

Whether or not this is a "restart" calculation.

More specifically whether this has been restarted using the Problem/restart_file_base parameter. Note that this will only return true when doing checkpoint restart. This will be false if doing exodus restart. Finally this will never return true when isRecovering is true

Definition at line 1807 of file MooseApp.C.

Referenced by SetupMeshAction::act(), FEProblemBase::checkICRestartError(), MultiApp::createApp(), EigenProblem::execute(), FileOutput::FileOutput(), FullSolveMultiApp::FullSolveMultiApp(), Eigenvalue::init(), FEProblemBase::initialSetup(), TransientBase::preExecute(), TimeSequenceStepperBase::setupSequence(), PhysicsBase::shouldCreateIC(), and TransientMultiApp::solveStep().

1808 {
1809  return _restart;
1810 }
bool _restart
Whether or not this is a restart run.
Definition: MooseApp.h:1273

◆ isSplitMesh()

bool MooseApp::isSplitMesh ( ) const

Whether or not this is a split mesh operation.

Definition at line 1813 of file MooseApp.C.

Referenced by MooseMesh::init().

1814 {
1815  return _split_mesh;
1816 }
bool _split_mesh
Whether or not we are performing a split mesh operation (–split-mesh)
Definition: MooseApp.h:1276

◆ isUltimateMaster()

bool MooseApp::isUltimateMaster ( ) const
inline

◆ libNameToAppName()

std::string MooseApp::libNameToAppName ( const std::string &  library_name) const

Converts a library name to an application name:

Definition at line 2470 of file MooseApp.C.

2471 {
2472  std::string app_name(library_name);
2473 
2474  // Strip off the leading "lib" and trailing ".la"
2475  if (pcrecpp::RE("lib(.+?)(?:-\\w+)?\\.la").Replace("\\1", &app_name) == 0)
2476  mooseError("Invalid library name: ", app_name);
2477 
2478  return MooseUtils::underscoreToCamelCase(app_name, true);
2479 }
std::string underscoreToCamelCase(const std::string &underscore_name, bool leading_upper_case)
Function for converting an underscore name to a camel case name.
Definition: MooseUtils.C:576
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:267

◆ loadLibraryAndDependencies()

void MooseApp::loadLibraryAndDependencies ( const std::string &  library_filename,
const libMesh::Parameters params,
bool  load_dependencies = true 
)
protected

Recursively loads libraries and dependencies in the proper order to fully register a MOOSE application that may have several dependencies.

REQUIRES: dynamic linking loader support.

Definition at line 2713 of file MooseApp.C.

Referenced by dynamicRegistration().

2716 {
2717  std::string line;
2718  std::string dl_lib_filename;
2719 
2720  // This RE looks for absolute path libtool filenames (i.e. begins with a slash and ends with a
2721  // .la)
2722  pcrecpp::RE re_deps("(/\\S*\\.la)");
2723 
2724  std::ifstream la_handle(library_filename.c_str());
2725  if (la_handle.is_open())
2726  {
2727  while (std::getline(la_handle, line))
2728  {
2729  // Look for the system dependent dynamic library filename to open
2730  if (line.find("dlname=") != std::string::npos)
2731  // Magic numbers are computed from length of this string "dlname=' and line minus that
2732  // string plus quotes"
2733  dl_lib_filename = line.substr(8, line.size() - 9);
2734 
2735  if (line.find("dependency_libs=") != std::string::npos)
2736  {
2737  if (load_dependencies)
2738  {
2739  pcrecpp::StringPiece input(line);
2740  pcrecpp::StringPiece depend_library;
2741  while (re_deps.FindAndConsume(&input, &depend_library))
2742  // Recurse here to load dependent libraries in depth-first order
2743  loadLibraryAndDependencies(depend_library.as_string(), params, load_dependencies);
2744  }
2745 
2746  // There's only one line in the .la file containing the dependency libs so break after
2747  // finding it
2748  break;
2749  }
2750  }
2751  la_handle.close();
2752  }
2753 
2754  // This should only occur if we have static linkage.
2755  if (dl_lib_filename.empty())
2756  return;
2757 
2758  const auto & [dir, file_name] = MooseUtils::splitFileName(library_filename);
2759 
2760  // Time to load the library, First see if we've already loaded this particular dynamic library
2761  // 1) make sure we haven't already loaded this library
2762  // AND 2) make sure we have a library name (we won't for static linkage)
2763  // Note: Here was are going to assume uniqueness based on the filename alone. This has significant
2764  // implications for applications that have "diamond" inheritance of libraries (usually
2765  // modules). We will only load one of those libraries, versions be damned.
2766  auto dyn_lib_it = _lib_handles.find(file_name);
2767  if (dyn_lib_it == _lib_handles.end())
2768  {
2769  // Assemble the actual filename using the base path of the *.la file and the dl_lib_filename
2770  const auto dl_lib_full_path = MooseUtils::pathjoin(dir, dl_lib_filename);
2771 
2772  MooseUtils::checkFileReadable(dl_lib_full_path, false, /*throw_on_unreadable=*/true);
2773 
2774 #ifdef LIBMESH_HAVE_DLOPEN
2775  void * const lib_handle = dlopen(dl_lib_full_path.c_str(), RTLD_LAZY);
2776 #else
2777  void * const lib_handle = nullptr;
2778 #endif
2779 
2780  if (!lib_handle)
2781  mooseError("The library file \"",
2782  dl_lib_full_path,
2783  "\" exists and has proper permissions, but cannot by dynamically loaded.\nThis "
2784  "generally means that the loader was unable to load one or more of the "
2785  "dependencies listed in the supplied library (see otool or ldd).\n",
2786  dlerror());
2787 
2788  DynamicLibraryInfo lib_info;
2789  lib_info.library_handle = lib_handle;
2790  lib_info.full_path = library_filename;
2791 
2792  auto insert_ret = _lib_handles.insert(std::make_pair(file_name, lib_info));
2793  mooseAssert(insert_ret.second == true, "Error inserting into lib_handles map");
2794 
2795  dyn_lib_it = insert_ret.first;
2796  }
2797 
2798  // Library has been loaded, check to see if we've called the requested registration method
2799  const auto registration_method = params.get<std::string>("registration_method");
2800  auto & entry_sym_from_curr_lib = dyn_lib_it->second.entry_symbols;
2801 
2802  if (entry_sym_from_curr_lib.find(registration_method) == entry_sym_from_curr_lib.end())
2803  {
2804  // get the pointer to the method in the library. The dlsym()
2805  // function returns a null pointer if the symbol cannot be found,
2806  // we also explicitly set the pointer to NULL if dlsym is not
2807  // available.
2808 #ifdef LIBMESH_HAVE_DLOPEN
2809  void * registration_handle =
2810  dlsym(dyn_lib_it->second.library_handle, registration_method.c_str());
2811 #else
2812  void * registration_handle = nullptr;
2813 #endif
2814 
2815  if (registration_handle)
2816  {
2817  switch (params.get<RegistrationType>("reg_type"))
2818  {
2819  case APPLICATION:
2820  {
2821  using register_app_t = void (*)();
2822  register_app_t * const reg_ptr = reinterpret_cast<register_app_t *>(&registration_handle);
2823  (*reg_ptr)();
2824  break;
2825  }
2826  case REGALL:
2827  {
2828  using register_app_t = void (*)(Factory *, ActionFactory *, Syntax *);
2829  register_app_t * const reg_ptr = reinterpret_cast<register_app_t *>(&registration_handle);
2830  (*reg_ptr)(params.get<Factory *>("factory"),
2831  params.get<ActionFactory *>("action_factory"),
2832  params.get<Syntax *>("syntax"));
2833  break;
2834  }
2835  default:
2836  mooseError("Unhandled RegistrationType");
2837  }
2838 
2839  entry_sym_from_curr_lib.insert(registration_method);
2840  }
2841  else
2842  {
2843 
2844 #if defined(DEBUG) && defined(LIBMESH_HAVE_DLOPEN)
2845  // We found a dynamic library that doesn't have a dynamic
2846  // registration method in it. This shouldn't be an error, so
2847  // we'll just move on.
2848  if (!registration_handle)
2849  mooseWarning("Unable to find extern \"C\" method \"",
2850  registration_method,
2851  "\" in library: ",
2852  dyn_lib_it->first,
2853  ".\n",
2854  "This doesn't necessarily indicate an error condition unless you believe that "
2855  "the method should exist in that library.\n",
2856  dlerror());
2857 #endif
2858  }
2859  }
2860 }
std::pair< std::filesystem::path, std::filesystem::path > splitFileName(const T &full_file)
Function for splitting path and filename.
Definition: MooseUtils.h:261
const T & get(std::string_view) const
void loadLibraryAndDependencies(const std::string &library_filename, const libMesh::Parameters &params, bool load_dependencies=true)
Recursively loads libraries and dependencies in the proper order to fully register a MOOSE applicatio...
Definition: MooseApp.C:2713
Specialized factory for generic Action System objects.
Definition: ActionFactory.h:50
bool checkFileReadable(const std::string &filename, bool check_line_endings=false, bool throw_on_unreadable=true, bool check_for_git_lfs_pointer=true)
Checks to see if a file is readable (exists and permissions)
Definition: MooseUtils.C:250
RegistrationType
Enumeration for holding the valid types of dynamic registrations allowed.
Definition: MooseApp.h:1497
std::unordered_map< std::string, DynamicLibraryInfo > _lib_handles
The library archive (name only), registration method and the handle to the method.
Definition: MooseApp.h:1323
std::filesystem::path pathjoin(const std::filesystem::path &p)
Definition: MooseUtils.C:59
void mooseWarning(Args &&... args) const
Emits a warning prefixed with object name and type.
Definition: MooseBase.h:295
Holding syntax for parsing input files.
Definition: Syntax.h:21
class infix_ostream_iterator if void
Definition: InfixIterator.h:26
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:267

◆ loadRestartableMetaData()

void MooseApp::loadRestartableMetaData ( const std::filesystem::path &  folder_base)

Loads all available restartable meta data if it is available with the folder base folder_base.

Definition at line 2578 of file MooseApp.C.

Referenced by SetupRecoverFileBaseAction::act().

2579 {
2580  for (const auto & name_map_pair : _restartable_meta_data)
2581  possiblyLoadRestartableMetaData(name_map_pair.first, folder_base);
2582 }
std::unordered_map< RestartableDataMapName, std::pair< RestartableDataMap, std::string > > _restartable_meta_data
General storage for custom RestartableData that can be added to from outside applications.
Definition: MooseApp.h:1494
void possiblyLoadRestartableMetaData(const RestartableDataMapName &name, const std::filesystem::path &folder_base)
Loads the restartable meta data for name if it is available with the folder base folder_base.
Definition: MooseApp.C:2563

◆ masterDisplacedMesh()

const MooseMesh* MooseApp::masterDisplacedMesh ( ) const
inline

Returns a pointer to the master displaced mesh.

Definition at line 828 of file MooseApp.h.

Referenced by SetupMeshAction::act().

828 { return _master_displaced_mesh; }
const MooseMesh *const _master_displaced_mesh
The displaced mesh from master app.
Definition: MooseApp.h:1519

◆ masterMesh()

const MooseMesh* MooseApp::masterMesh ( ) const
inline

Returns a pointer to the master mesh.

Definition at line 823 of file MooseApp.h.

Referenced by SetupMeshAction::act(), and CopyMeshPartitioner::CopyMeshPartitioner().

823 { return _master_mesh; }
const MooseMesh *const _master_mesh
The mesh from master app.
Definition: MooseApp.h:1516

◆ messagePrefix()

std::string MooseBase::messagePrefix ( const bool  hit_prefix = true) const
inlineinherited
Returns
A prefix to be used in messages that contain the input file location associated with this object (if any) and the name and type of the object.

Definition at line 252 of file MooseBase.h.

Referenced by MooseBase::callMooseError(), MooseBase::errorPrefix(), MooseBase::mooseDeprecated(), MooseBase::mooseInfo(), and MooseBase::mooseWarning().

253  {
254  return messagePrefix(_pars, hit_prefix);
255  }
const InputParameters & _pars
The object&#39;s parameters.
Definition: MooseBase.h:362
std::string messagePrefix(const bool hit_prefix=true) const
Definition: MooseBase.h:252

◆ metaDataFolderBase()

std::filesystem::path MooseApp::metaDataFolderBase ( const std::filesystem::path &  folder_base,
const std::string &  map_suffix 
)
static

The file suffix for meta data (header and data)

Definition at line 3079 of file MooseApp.C.

Referenced by possiblyLoadRestartableMetaData(), and writeRestartableMetaData().

3081 {
3082  return RestartableDataIO::restartableDataFolder(folder_base /
3083  std::filesystem::path("meta_data" + map_suffix));
3084 }
static std::filesystem::path restartableDataFolder(const std::filesystem::path &folder_base)

◆ mooseDeprecated()

template<typename... Args>
void MooseBase::mooseDeprecated ( Args &&...  args) const
inlineinherited

Definition at line 310 of file MooseBase.h.

Referenced by FEProblemBase::addAuxArrayVariable(), FEProblemBase::addAuxScalarVariable(), FEProblemBase::addAuxVariable(), FEProblemBase::advanceMultiApps(), MultiApp::appProblem(), MooseMesh::buildSideList(), ChangeOverTimestepPostprocessor::ChangeOverTimestepPostprocessor(), AddVariableAction::determineType(), EigenProblem::EigenProblem(), Eigenvalue::Eigenvalue(), MooseMesh::elem(), UserForcingFunction::f(), FaceFaceConstraint::FaceFaceConstraint(), FunctionDT::FunctionDT(), RandomICBase::generateRandom(), MooseMesh::getBoundariesToElems(), DataFileInterface::getDataFileName(), DataFileInterface::getDataFileNameByName(), Control::getExecuteOptions(), FEProblemBase::getNonlinearSystem(), getRecoverFileBase(), FEProblemBase::getUserObjects(), FEProblemBase::hasPostprocessor(), hasRecoverFileBase(), MatDiffusionBase< Real >::MatDiffusionBase(), MultiAppNearestNodeTransfer::MultiAppNearestNodeTransfer(), MultiAppShapeEvaluationTransfer::MultiAppShapeEvaluationTransfer(), MultiAppUserObjectTransfer::MultiAppUserObjectTransfer(), NodalScalarKernel::NodalScalarKernel(), MooseMesh::node(), FixedPointSolve::numPicardIts(), RelationshipManager::operator>=(), PercentChangePostprocessor::PercentChangePostprocessor(), ReferenceResidualConvergence::ReferenceResidualConvergence(), Residual::Residual(), MooseMesh::setBoundaryToNormalMap(), Exodus::setOutputDimension(), setupOptions(), UserForcingFunction::UserForcingFunction(), and VariableResidual::VariableResidual().

311  {
313  _console, false, true, messagePrefix(true), std::forward<Args>(args)...);
314  }
void mooseDeprecatedStream(S &oss, const bool expired, const bool print_title, Args &&... args)
Definition: MooseError.h:275
const ConsoleStream _console
An instance of helper class to write streams to the Console objects.
std::string messagePrefix(const bool hit_prefix=true) const
Definition: MooseBase.h:252

◆ mooseDocumentedError()

template<typename... Args>
void MooseBase::mooseDocumentedError ( const std::string &  repo_name,
const unsigned int  issue_num,
Args &&...  args 
) const
inlineinherited

Definition at line 273 of file MooseBase.h.

Referenced by ArrayDGLowerDKernel::ArrayDGLowerDKernel(), ArrayHFEMDirichletBC::ArrayHFEMDirichletBC(), ArrayLowerDIntegratedBC::ArrayLowerDIntegratedBC(), DGLowerDKernel::DGLowerDKernel(), HFEMDirichletBC::HFEMDirichletBC(), and LowerDIntegratedBC::LowerDIntegratedBC().

276  {
278  repo_name, issue_num, argumentsToString(std::forward<Args>(args)...)),
279  /* with_prefix = */ true);
280  }
void callMooseError(std::string msg, const bool with_prefix, const hit::Node *node=nullptr) const
External method for calling moose error with added object context.
Definition: MooseBase.C:102
std::string formatMooseDocumentedError(const std::string &repo_name, const unsigned int issue_num, const std::string &msg)
Formats a documented error.
Definition: MooseError.C:105

◆ mooseError()

template<typename... Args>
void MooseBase::mooseError ( Args &&...  args) const
inlineinherited

Emits an error prefixed with object name and type and optionally a file path to the top-level block parameter if available.

Definition at line 267 of file MooseBase.h.

Referenced by CopyMeshPartitioner::_do_partition(), HierarchicalGridPartitioner::_do_partition(), GridPartitioner::_do_partition(), PetscExternalPartitioner::_do_partition(), MultiAppGeneralFieldTransfer::acceptPointInOriginMesh(), AddBoundsVectorsAction::act(), CheckIntegrityAction::act(), AddVectorPostprocessorAction::act(), AutoCheckpointAction::act(), CheckFVBCAction::act(), InitProblemAction::act(), SetupMeshCompleteAction::act(), CreateExecutionerAction::act(), AddFVICAction::act(), AddICAction::act(), AddMeshGeneratorAction::act(), CreateProblemDefaultAction::act(), CreateProblemAction::act(), CombineComponentsMeshes::act(), SetupMeshAction::act(), SplitMeshAction::act(), AdaptivityAction::act(), AddTimeStepperAction::act(), ChainControlSetupAction::act(), DeprecatedBlockAction::act(), SetupPredictorAction::act(), SetupTimeStepperAction::act(), CreateDisplacedProblemAction::act(), MaterialDerivativeTestAction::act(), SetAdaptivityOptionsAction::act(), MaterialOutputAction::act(), AddMFEMSubMeshAction::act(), AddPeriodicBCAction::act(), CommonOutputAction::act(), Action::Action(), FEProblemBase::adaptMesh(), ADConservativeAdvectionBC::ADConservativeAdvectionBC(), MooseVariableFV< Real >::adCurlSln(), MooseVariableFV< Real >::adCurlSlnNeighbor(), AddActionComponentAction::AddActionComponentAction(), MFEMProblem::addBoundaryCondition(), FEProblemBase::addBoundaryCondition(), DiffusionCG::addBoundaryConditionsFromComponents(), PhysicsComponentInterface::addBoundaryConditionsFromComponents(), FEProblemBase::addConstraint(), FEProblemBase::addDamper(), FEProblemBase::addDGKernel(), FEProblemBase::addDiracKernel(), DistributedRectilinearMeshGenerator::addElement(), addExecutor(), FEProblemBase::addFunction(), SubProblem::addFunctor(), FEProblemBase::addFVInitialCondition(), ADDGKernel::ADDGKernel(), FEProblemBase::addHDGKernel(), FEProblemBase::addInitialCondition(), PhysicsComponentInterface::addInitialConditionsFromComponents(), FEProblemBase::addInterfaceKernel(), MFEMProblem::addKernel(), FEProblemBase::addKernel(), FEProblem::addLineSearch(), FEProblemBase::addLineSearch(), MFEMProblem::addMaterial(), MeshGenerator::addMeshSubgenerator(), MFEMProblem::addMFEMFESpaceFromMOOSEVariable(), FEProblemBase::addOutput(), SubProblem::addPiecewiseByBlockLambdaFunctor(), DiracKernelBase::addPoint(), DistributedRectilinearMeshGenerator::addPoint(), DiracKernelBase::addPointWithValidId(), FEProblemBase::addPostprocessor(), FEProblemBase::addPredictor(), CreateDisplacedProblemAction::addProxyRelationshipManagers(), MooseMesh::addQuadratureNode(), Action::addRelationshipManager(), FEProblemBase::addReporter(), FEProblemBase::addScalarKernel(), AddVariableAction::addVariable(), FEProblemBase::addVectorPostprocessor(), SubProblem::addVectorTag(), MooseLinearVariableFV< Real >::adError(), ADInterfaceKernelTempl< T >::ADInterfaceKernelTempl(), ADPiecewiseLinearInterpolationMaterial::ADPiecewiseLinearInterpolationMaterial(), MooseVariableScalar::adUDot(), Output::advancedExecuteOn(), AdvectiveFluxAux::AdvectiveFluxAux(), MooseVariableBase::allDofIndices(), NEML2ModelExecutor::applyPredictor(), appNameToLibName(), MultiApp::appPostprocessorValue(), MultiApp::appProblem(), MultiApp::appProblemBase(), MultiApp::appUserObjectBase(), ArrayConstantIC::ArrayConstantIC(), ArrayDGKernel::ArrayDGKernel(), ArrayDiffusion::ArrayDiffusion(), ArrayFunctionIC::ArrayFunctionIC(), ArrayReaction::ArrayReaction(), ArrayTimeDerivative::ArrayTimeDerivative(), attachRelationshipManagers(), AddPeriodicBCAction::autoTranslationBoundaries(), AuxKernelTempl< Real >::AuxKernelTempl(), Function::average(), Axisymmetric2D3DSolutionFunction::Axisymmetric2D3DSolutionFunction(), BatchMeshGeneratorAction::BatchMeshGeneratorAction(), BicubicSplineFunction::BicubicSplineFunction(), BlockDeletionGenerator::BlockDeletionGenerator(), BoundingValueElementDamper::BoundingValueElementDamper(), BoundingValueNodalDamper::BoundingValueNodalDamper(), BreakMeshByBlockGeneratorBase::BreakMeshByBlockGeneratorBase(), MooseMesh::buildCoarseningMap(), MultiApp::buildComm(), DistributedRectilinearMeshGenerator::buildCube(), TimedSubdomainModifier::buildFromFile(), PiecewiseTabularBase::buildFromFile(), PiecewiseTabularBase::buildFromJSON(), TimedSubdomainModifier::buildFromParameters(), PiecewiseTabularBase::buildFromXY(), PiecewiseLinearBase::buildInterpolation(), MooseMesh::buildLowerDMesh(), TiledMesh::buildMesh(), GeneratedMesh::buildMesh(), SpiralAnnularMesh::buildMesh(), MeshGeneratorMesh::buildMesh(), ImageMeshGenerator::buildMesh3D(), ImageMesh::buildMesh3D(), MooseMesh::buildRefinementMap(), MaterialBase::buildRequiredMaterials(), MooseMesh::buildSideList(), MooseMesh::buildTypedMesh(), MooseMesh::cacheFaceInfoVariableOwnership(), CartesianGridDivision::CartesianGridDivision(), CartesianMeshGenerator::CartesianMeshGenerator(), ChangeOverFixedPointPostprocessor::ChangeOverFixedPointPostprocessor(), ChangeOverTimePostprocessor::ChangeOverTimePostprocessor(), EigenExecutionerBase::chebyshev(), SubProblem::checkBlockMatProps(), PhysicsBase::checkBlockRestrictionIdentical(), ComponentBoundaryConditionInterface::checkBoundaryConditionsAllRequested(), SubProblem::checkBoundaryMatProps(), PhysicsBase::checkComponentType(), IterationCountConvergence::checkConvergence(), MooseMesh::checkCoordinateSystems(), DiffusionLHDGAssemblyHelper::checkCoupling(), FEProblemBase::checkDependMaterialsHelper(), FEProblemBase::checkDisplacementOrders(), FEProblemBase::checkDuplicatePostprocessorVariableNames(), DefaultConvergenceBase::checkDuplicateSetSharedExecutionerParams(), MooseMesh::checkDuplicateSubdomainNames(), FEProblemBase::checkExceptionAndStopSolve(), NEML2ModelExecutor::checkExecutionStage(), MaterialBase::checkExecutionStage(), MeshGenerator::checkGetMesh(), ReporterTransferInterface::checkHasReporterValue(), FEProblemBase::checkICRestartError(), Steady::checkIntegrity(), EigenExecutionerBase::checkIntegrity(), Eigenvalue::checkIntegrity(), DefaultMultiAppFixedPointConvergence::checkIterationType(), DefaultNonlinearConvergence::checkIterationType(), DefaultSteadyStateConvergence::checkIterationType(), ExplicitTimeIntegrator::checkLinearConvergence(), checkMetaDataIntegrity(), MeshDiagnosticsGenerator::checkNonConformalMeshFromAdaptivity(), MeshDiagnosticsGenerator::checkNonMatchingEdges(), PostprocessorInterface::checkParam(), FEProblemBase::checkProblemIntegrity(), Sampler::checkReinitStatus(), checkReservedCapability(), MultiAppGeneralFieldNearestLocationTransfer::checkRestrictionsForSource(), MultiAppPostprocessorToAuxScalarTransfer::checkSiblingsTransferSupported(), MultiAppScalarToAuxScalarTransfer::checkSiblingsTransferSupported(), MultiAppPostprocessorTransfer::checkSiblingsTransferSupported(), MultiAppReporterTransfer::checkSiblingsTransferSupported(), MultiAppMFEMCopyTransfer::checkSiblingsTransferSupported(), MultiAppCopyTransfer::checkSiblingsTransferSupported(), MultiAppTransfer::checkSiblingsTransferSupported(), MaterialBase::checkStatefulSanity(), AddDefaultConvergenceAction::checkUnusedMultiAppFixedPointConvergenceParameters(), AddDefaultConvergenceAction::checkUnusedNonlinearConvergenceParameters(), AddDefaultConvergenceAction::checkUnusedSteadyStateConvergenceParameters(), FEProblemBase::checkUserObjects(), Moose::PetscSupport::checkUserProvidedPetscOption(), DomainUserObject::checkVariable(), MultiAppTransfer::checkVariable(), MeshDiagnosticsGenerator::checkWatertightNodesets(), MeshDiagnosticsGenerator::checkWatertightSidesets(), LibmeshPartitioner::clone(), MooseMesh::clone(), CombinerGenerator::CombinerGenerator(), ComparisonPostprocessor::comparisonIsTrue(), MooseVariableFieldBase::componentName(), CompositeFunction::CompositeFunction(), ElementH1ErrorFunctionAux::compute(), NodalPatchRecovery::compute(), FEProblemBase::computeBounds(), VariableCondensationPreconditioner::computeDInverseDiag(), CompositionDT::computeDT(), ArrayDGKernel::computeElemNeighJacobian(), ArrayDGKernel::computeElemNeighResidual(), InternalSideIntegralPostprocessor::computeFaceInfoIntegral(), SideIntegralPostprocessor::computeFaceInfoIntegral(), MooseVariableFieldBase::computeFaceValues(), TimeSequenceStepperBase::computeFailedDT(), IterationAdaptiveDT::computeFailedDT(), TimeStepper::computeFailedDT(), MooseMesh::computeFiniteVolumeCoords(), HistogramVectorPostprocessor::computeHistogram(), ArrayKernel::computeJacobian(), ArrayIntegratedBC::computeJacobian(), FVFluxKernel::computeJacobian(), NodalConstraint::computeJacobian(), FEProblemBase::computeJacobianTags(), LowerDIntegratedBC::computeLowerDOffDiagJacobian(), ArrayLowerDIntegratedBC::computeLowerDOffDiagJacobian(), EigenProblem::computeMatricesTags(), ArrayDGKernel::computeOffDiagElemNeighJacobian(), ArrayKernel::computeOffDiagJacobian(), ArrayIntegratedBC::computeOffDiagJacobian(), FVElementalKernel::computeOffDiagJacobian(), MortarScalarBase::computeOffDiagJacobianScalar(), DGLowerDKernel::computeOffDiagLowerDJacobian(), ArrayDGLowerDKernel::computeOffDiagLowerDJacobian(), MaterialBase::computeProperties(), SideFVFluxBCIntegral::computeQpIntegral(), ScalarKernel::computeQpJacobian(), CoupledTiedValueConstraint::computeQpJacobian(), TiedValueConstraint::computeQpJacobian(), NodalEqualValueConstraint::computeQpJacobian(), LinearNodalConstraint::computeQpJacobian(), EqualValueBoundaryConstraint::computeQpJacobian(), NodeElemConstraint::computeQpJacobian(), CoupledTiedValueConstraint::computeQpOffDiagJacobian(), ScalarKernel::computeQpResidual(), MassMatrix::computeQpResidual(), HDGKernel::computeQpResidual(), DiffusionLHDGDirichletBC::computeQpResidual(), NodalEqualValueConstraint::computeQpResidual(), DiffusionLHDGPrescribedGradientBC::computeQpResidual(), IPHDGBC::computeQpResidual(), KernelValue::computeQpResidual(), TorchScriptMaterial::computeQpValues(), InterfaceQpValueUserObject::computeRealValue(), ArrayKernel::computeResidual(), ArrayIntegratedBC::computeResidual(), FVFluxBC::computeResidual(), FVFluxKernel::computeResidual(), NodalConstraint::computeResidual(), FVFluxKernel::computeResidualAndJacobian(), ResidualObject::computeResidualAndJacobian(), FEProblemBase::computeResidualAndJacobian(), HDGKernel::computeResidualAndJacobianOnSide(), FEProblemBase::computeResidualInternal(), FEProblemBase::computeResidualTag(), FEProblemBase::computeResidualTags(), FEProblemBase::computeResidualType(), KernelScalarBase::computeScalarOffDiagJacobian(), ADKernelScalarBase::computeScalarQpResidual(), ADMortarScalarBase::computeScalarQpResidual(), MortarScalarBase::computeScalarQpResidual(), KernelScalarBase::computeScalarQpResidual(), TimeStepper::computeStep(), ActuallyExplicitEuler::computeTimeDerivatives(), ExplicitEuler::computeTimeDerivatives(), ImplicitEuler::computeTimeDerivatives(), BDF2::computeTimeDerivatives(), NewmarkBeta::computeTimeDerivatives(), CentralDifference::computeTimeDerivatives(), CrankNicolson::computeTimeDerivatives(), LStableDirk2::computeTimeDerivatives(), LStableDirk3::computeTimeDerivatives(), ImplicitMidpoint::computeTimeDerivatives(), ExplicitTVDRK2::computeTimeDerivatives(), AStableDirk4::computeTimeDerivatives(), LStableDirk4::computeTimeDerivatives(), ExplicitRK2::computeTimeDerivatives(), MultiAppGeometricInterpolationTransfer::computeTransformation(), BuildArrayVariableAux::computeValue(), TagVectorArrayVariableAux::computeValue(), NearestNodeValueAux::computeValue(), ProjectionAux::computeValue(), PenetrationAux::computeValue(), ConcentricCircleMesh::ConcentricCircleMesh(), ConditionalEnableControl::ConditionalEnableControl(), TimeStepper::constrainStep(), LibtorchNeuralNetControl::controlNeuralNet(), TransientBase::convergedToSteadyState(), ParsedConvergence::convertRealToBool(), copyInputs(), CopyMeshPartitioner::CopyMeshPartitioner(), CoupledForceNodalKernel::CoupledForceNodalKernel(), MultiApp::createApp(), createExecutors(), AddVariableAction::createInitialConditionAction(), createRMFromTemplateAndInit(), Function::curl(), MooseVariableFV< Real >::curlPhi(), CutMeshByPlaneGenerator::CutMeshByPlaneGenerator(), SidesetInfoVectorPostprocessor::dataHelper(), ReporterTransferInterface::declareClone(), MeshGenerator::declareMeshProperty(), ReporterTransferInterface::declareVectorClone(), DefaultSteadyStateConvergence::DefaultSteadyStateConvergence(), FunctorRelationshipManager::delete_remote_elements(), MooseMesh::deleteRemoteElements(), BicubicSplineFunction::derivative(), DerivativeSumMaterialTempl< is_ad >::DerivativeSumMaterialTempl(), MooseMesh::detectPairedSidesets(), determineLibtorchDeviceType(), FEProblemBase::determineSolverSystem(), DGKernel::DGKernel(), MeshDiagnosticsGenerator::diagnosticsLog(), DistributedPositions::DistributedPositions(), Function::div(), FunctorBinnedValuesDivision::divisionIndex(), MooseVariableFV< Real >::divPhi(), FunctorRelationshipManager::dofmap_reinit(), EigenProblem::doFreeNonlinearPowerIterations(), FEProblemBase::duplicateVariableCheck(), dynamicAllRegistration(), dynamicAppRegistration(), EigenProblem::EigenProblem(), Eigenvalue::Eigenvalue(), Eigenvalues::Eigenvalues(), ElementalVariableValue::ElementalVariableValue(), ElementGroupCentroidPositions::ElementGroupCentroidPositions(), ElementIntegerAux::ElementIntegerAux(), ElementMaterialSampler::ElementMaterialSampler(), ElementQualityAux::ElementQualityAux(), ElementSubdomainModifierBase::ElementSubdomainModifierBase(), ElementUOAux::ElementUOAux(), ExtraIDIntegralVectorPostprocessor::elementValue(), DistributedRectilinearMeshGenerator::elemId(), ProjectionAux::elemOnNodeVariableIsDefinedOn(), EigenKernel::enabled(), errorCheck(), MooseMesh::errorIfDistributedMesh(), MultiAppTransfer::errorIfObjectExecutesOnTransferInSourceApp(), SideIntegralPostprocessor::errorNoFaceInfo(), SideIntegralFunctorPostprocessorTempl< false >::errorNoFaceInfo(), SolutionUserObjectBase::evalMeshFunction(), SolutionUserObjectBase::evalMeshFunctionGradient(), SolutionUserObjectBase::evalMultiValuedMeshFunction(), SolutionUserObjectBase::evalMultiValuedMeshFunctionGradient(), FixedPointSolve::examineFixedPointConvergence(), MultiAppGeneralFieldTransfer::examineReceivedValueConflicts(), RealToBoolChainControl::execute(), RestartableDataReporter::execute(), DiscreteElementUserObject::execute(), MultiAppPostprocessorToAuxScalarTransfer::execute(), MultiAppScalarToAuxScalarTransfer::execute(), NodalValueSampler::execute(), PositionsFunctorValueSampler::execute(), MultiAppPostprocessorInterpolationTransfer::execute(), MultiAppPostprocessorTransfer::execute(), ElementQualityChecker::execute(), MultiAppVariableValueSampleTransfer::execute(), GreaterThanLessThanPostprocessor::execute(), PointValue::execute(), MultiAppVariableValueSamplePostprocessorTransfer::execute(), FindValueOnLine::execute(), MultiAppNearestNodeTransfer::execute(), MultiAppMFEMCopyTransfer::execute(), MultiAppCopyTransfer::execute(), MultiAppGeometricInterpolationTransfer::execute(), MultiAppUserObjectTransfer::execute(), InterfaceQpUserObjectBase::execute(), WebServerControl::execute(), TransientBase::execute(), LeastSquaresFit::execute(), VectorPostprocessorComparison::execute(), LeastSquaresFitHistory::execute(), Eigenvalue::execute(), TimeExtremeValue::execute(), DomainUserObject::execute(), FEProblemBase::execute(), FEProblemBase::executeControls(), executeExecutioner(), MultiAppVectorPostprocessorTransfer::executeFromMultiapp(), MultiAppVectorPostprocessorTransfer::executeToMultiapp(), Exodus::Exodus(), ExplicitSSPRungeKutta::ExplicitSSPRungeKutta(), MultiAppGeneralFieldTransfer::extractOutgoingPoints(), NEML2ModelExecutor::extractOutputs(), ExtraIDIntegralVectorPostprocessor::ExtraIDIntegralVectorPostprocessor(), FEProblemSolve::FEProblemSolve(), FileOutput::FileOutput(), NEML2ModelExecutor::fillInputs(), QuadraturePointMultiApp::fillPositions(), CentroidMultiApp::fillPositions(), MultiApp::fillPositions(), MultiAppGeometricInterpolationTransfer::fillSourceInterpolationPoints(), VerifyNodalUniqueID::finalize(), VerifyElementUniqueID::finalize(), DiscreteElementUserObject::finalize(), ElementQualityChecker::finalize(), MemoryUsage::finalize(), PointSamplerBase::finalize(), DiscreteVariableResidualNorm::finalize(), NearestPointAverage::finalize(), NearestPointIntegralVariablePostprocessor::finalize(), finalizeRestore(), Transfer::find_sys(), BreakMeshByBlockGeneratorBase::findFreeBoundaryId(), FunctionDT::FunctionDT(), FunctionMaterialBase< is_ad >::FunctionMaterialBase(), FunctionScalarAux::FunctionScalarAux(), FunctionScalarIC::FunctionScalarIC(), FunctorSmootherTempl< T >::FunctorSmootherTempl(), FVInitialConditionTempl< T >::FVInitialConditionTempl(), FVMassMatrix::FVMassMatrix(), FVMatAdvection::FVMatAdvection(), FVScalarLagrangeMultiplierInterface::FVScalarLagrangeMultiplierInterface(), GapValueAux::GapValueAux(), WorkBalance::gather(), ElementOrderConversionGenerator::generate(), SideSetsFromNormalsGenerator::generate(), SmoothMeshGenerator::generate(), SubdomainPerElementGenerator::generate(), TiledMeshGenerator::generate(), BlockToMeshConverterGenerator::generate(), ExtraNodesetGenerator::generate(), FileMeshGenerator::generate(), LowerDBlockFromSidesetGenerator::generate(), MoveNodeGenerator::generate(), PlaneIDMeshGenerator::generate(), RenameBlockGenerator::generate(), RenameBoundaryGenerator::generate(), SideSetsFromPointsGenerator::generate(), StitchMeshGenerator::generate(), GeneratedMeshGenerator::generate(), FlipSidesetGenerator::generate(), BreakMeshByBlockGenerator::generate(), CoarsenBlockGenerator::generate(), MeshDiagnosticsGenerator::generate(), MeshRepairGenerator::generate(), SideSetsFromBoundingBoxGenerator::generate(), StackGenerator::generate(), XYZDelaunayGenerator::generate(), CombinerGenerator::generate(), MeshCollectionGenerator::generate(), AdvancedExtruderGenerator::generate(), AllSideSetsByNormalsGenerator::generate(), MeshExtruderGenerator::generate(), ParsedGenerateNodeset::generate(), SpiralAnnularMeshGenerator::generate(), XYDelaunayGenerator::generate(), XYMeshLineCutter::generate(), CutMeshByLevelSetGeneratorBase::generate(), SubdomainBoundingBoxGenerator::generate(), PatternedMeshGenerator::generate(), DistributedRectilinearMeshGenerator::generate(), BoundingBoxNodeSetGenerator::generate(), MeshGenerator::generateData(), GeneratedMesh::GeneratedMesh(), GeneratedMeshGenerator::GeneratedMeshGenerator(), MeshGenerator::generateInternal(), CircularBoundaryCorrectionGenerator::generateRadialCorrectionFactor(), RandomICBase::generateRandom(), GenericConstantMaterialTempl< is_ad >::GenericConstantMaterialTempl(), GenericConstantVectorMaterialTempl< is_ad >::GenericConstantVectorMaterialTempl(), GenericFunctionMaterialTempl< is_ad >::GenericFunctionMaterialTempl(), GenericFunctionVectorMaterialTempl< is_ad >::GenericFunctionVectorMaterialTempl(), GenericFunctorGradientMaterialTempl< is_ad >::GenericFunctorGradientMaterialTempl(), GenericFunctorMaterialTempl< is_ad >::GenericFunctorMaterialTempl(), GenericFunctorTimeDerivativeMaterialTempl< is_ad >::GenericFunctorTimeDerivativeMaterialTempl(), GenericVectorFunctorMaterialTempl< is_ad >::GenericVectorFunctorMaterialTempl(), DisplacedProblem::getActualFieldVariable(), FEProblemBase::getActualFieldVariable(), DisplacedProblem::getArrayVariable(), FEProblemBase::getArrayVariable(), MooseMesh::getAxisymmetricRadialCoord(), MFEMFESpace::getBasis(), NEML2BatchIndexGenerator::getBatchIndex(), MooseMesh::getBlockConnectedBlocks(), VariableOldValueBounds::getBound(), MooseMesh::getBoundaryID(), MultiApp::getBoundingBox(), ChainControl::getChainControlDataByName(), MooseMesh::getCoarseningMap(), MultiApp::getCommandLineArgs(), MooseVariableBase::getContinuity(), Control::getControllableParameterByName(), FEProblemBase::getConvergence(), MooseMesh::getCoordSystem(), PhysicsBase::getCoupledPhysics(), PropertyReadFile::getData(), DataFileInterface::getDataFilePath(), TransfiniteMeshGenerator::getDiscreteEdge(), FEProblemBase::getDistribution(), MooseVariableBase::getDofIndices(), VariableCondensationPreconditioner::getDofToCondense(), TransfiniteMeshGenerator::getEdge(), GhostingUserObject::getElementalValue(), ElementUOProvider::getElementalValueLong(), ElementUOProvider::getElementalValueReal(), PropertyReadFile::getElementData(), MooseMesh::getElementIDIndex(), Material::getElementIDNeighbor(), Material::getElementIDNeighborByName(), MooseMesh::getElemIDMapping(), MooseMesh::getElemIDsOnBlocks(), MultiAppFieldTransfer::getEquationSystem(), MultiApp::getExecutioner(), getExecutor(), MFEMVectorFESpace::getFECName(), MultiAppTransfer::getFromMultiApp(), MultiAppTransfer::getFromMultiAppInfo(), FEProblemBase::getFunction(), SubProblem::getFunctor(), FEProblemBase::getFVMatsAndDependencies(), MooseMesh::getGeneralAxisymmetricCoordAxis(), DistributedRectilinearMeshGenerator::getGhostNeighbors(), DistributedRectilinearMeshGenerator::getIndices(), FEProblemBase::getLinearConvergenceNames(), SolutionUserObjectBase::getLocalVarIndex(), Material::getMaterialByName(), FEProblemBase::getMaterialData(), SubProblem::getMatrixTagID(), AnnularMesh::getMaxInDimension(), GeneratedMesh::getMaxInDimension(), FEProblemBase::getMaxQps(), FEProblemBase::getMeshDivision(), MeshGenerator::getMeshGeneratorNameFromParam(), MeshGenerator::getMeshGeneratorNamesFromParam(), AnnularMesh::getMinInDimension(), GeneratedMesh::getMinInDimension(), MultiAppTransfer::getMultiApp(), FEProblemBase::getMultiAppFixedPointConvergenceName(), DistributedRectilinearMeshGenerator::getNeighbors(), Times::getNextTime(), MooseMesh::getNodeBlockIds(), PropertyReadFile::getNodeData(), MooseMesh::getNodeList(), FEProblemBase::getNonlinearConvergenceNames(), EigenProblem::getNonlinearEigenSystem(), FEProblemBase::getNonlinearSystem(), NEML2ModelExecutor::getOutput(), NEML2ModelExecutor::getOutputDerivative(), NEML2ModelExecutor::getOutputParameterDerivative(), MooseMesh::getPairedBoundaryMapping(), MaterialOutputAction::getParams(), ImageMeshGenerator::GetPixelInfo(), ImageMesh::GetPixelInfo(), PlaneIDMeshGenerator::getPlaneID(), Positions::getPosition(), Positions::getPositions(), FEProblemBase::getPositionsObject(), Positions::getPositionsVector2D(), Positions::getPositionsVector3D(), Positions::getPositionsVector4D(), PostprocessorInterface::getPostprocessorValueByNameInternal(), Times::getPreviousTime(), ComponentMaterialPropertyInterface::getPropertyValue(), InterfaceQpUserObjectBase::getQpValue(), MooseMesh::getRefinementMap(), MooseBase::getRenamedParam(), ReporterInterface::getReporterContextBaseByName(), ReporterInterface::getReporterName(), Reporter::getReporterValueName(), getRestartableDataMap(), getRestartableDataMapName(), getRestartableMetaData(), getRMClone(), FEProblemBase::getSampler(), WebServerControl::getScalarJSONValue(), DisplacedProblem::getScalarVariable(), FEProblemBase::getScalarVariable(), MooseObject::getSharedPtr(), InterfaceQpUserObjectBase::getSideAverageValue(), PhysicsBase::getSolverSystem(), DisplacedProblem::getStandardVariable(), FEProblemBase::getStandardVariable(), FEProblemBase::getSteadyStateConvergenceName(), MooseMesh::getSubdomainBoundaryIds(), TimedSubdomainModifier::getSubdomainIDAndCheck(), DisplacedProblem::getSystem(), FEProblemBase::getSystem(), Times::getTimeAtIndex(), FEProblemBase::getTimeFromStateArg(), TransientBase::getTimeIntegratorNames(), Times::getTimes(), MultiAppTransfer::getToMultiApp(), MultiAppTransfer::getToMultiAppInfo(), MooseMesh::getUniqueCoordSystem(), FEProblemBase::getUserObject(), FEProblemBase::getUserObjectBase(), UserObjectInterface::getUserObjectBaseByName(), UserObjectInterface::getUserObjectName(), VectorPostprocessorComponent::getValue(), NumRelationshipManagers::getValue(), Residual::getValue(), SideAverageValue::getValue(), JSONFileReader::getValue(), LineValueSampler::getValue(), FindValueOnLine::getValueAtPoint(), SubProblem::getVariableHelper(), JSONFileReader::getVector(), VectorPostprocessorInterface::getVectorPostprocessorName(), SubProblem::getVectorTag(), SubProblem::getVectorTagID(), DisplacedProblem::getVectorVariable(), FEProblemBase::getVectorVariable(), GhostingFromUOAux::GhostingFromUOAux(), MultiApp::globalAppToLocal(), MooseParsedVectorFunction::gradient(), Function::gradient(), FEProblemBase::handleException(), Terminator::handleMessage(), MooseVariableBase::hasDoFsOnNodes(), PostprocessorInterface::hasPostprocessor(), PostprocessorInterface::hasPostprocessorByName(), ReporterInterface::hasReporterValue(), ReporterInterface::hasReporterValueByName(), VectorPostprocessorInterface::hasVectorPostprocessor(), VectorPostprocessorInterface::hasVectorPostprocessorByName(), HDGKernel::HDGKernel(), TransientBase::incrementStepOrReject(), FixedPointIterationAdaptiveDT::init(), CrankNicolson::init(), CSVTimeSequenceStepper::init(), EigenExecutionerBase::init(), ExplicitTimeIntegrator::init(), TransientBase::init(), FEProblem::init(), AddAuxVariableAction::init(), IterationAdaptiveDT::init(), Eigenvalue::init(), AddVariableAction::init(), MooseMesh::init(), Sampler::init(), FEProblemBase::init(), MultiApp::init(), FEProblemBase::initialAdaptMesh(), NestedDivision::initialize(), DistributedPositions::initialize(), ReporterPositions::initialize(), TransformedPositions::initialize(), ReporterTimes::initialize(), ElementGroupCentroidPositions::initialize(), FunctorPositions::initialize(), FunctorTimes::initialize(), ParsedDownSelectionPositions::initialize(), ParsedConvergence::initializeConstantSymbol(), PhysicsBase::initializePhysics(), SteffensenSolve::initialSetup(), MultiAppCloneReporterTransfer::initialSetup(), SolutionIC::initialSetup(), ChainControlDataPostprocessor::initialSetup(), IntegralPreservingFunctionIC::initialSetup(), PiecewiseLinearBase::initialSetup(), MultiAppConservativeTransfer::initialSetup(), FullSolveMultiApp::initialSetup(), PiecewiseLinear::initialSetup(), CoarsenedPiecewiseLinear::initialSetup(), MultiAppDofCopyTransfer::initialSetup(), LinearFVAdvection::initialSetup(), MultiAppGeneralFieldNearestLocationTransfer::initialSetup(), LinearFVAnisotropicDiffusion::initialSetup(), SolutionScalarAux::initialSetup(), LinearFVDiffusion::initialSetup(), ExplicitTimeIntegrator::initialSetup(), SolutionAux::initialSetup(), ReferenceResidualConvergence::initialSetup(), NodalVariableValue::initialSetup(), Axisymmetric2D3DSolutionFunction::initialSetup(), Exodus::initialSetup(), CSV::initialSetup(), MooseParsedFunction::initialSetup(), SolutionUserObjectBase::initialSetup(), FEProblemBase::initialSetup(), SubProblem::initialSetup(), AdvancedOutput::initOutputList(), AdvancedOutput::initShowHideLists(), Function::integral(), InterfaceDiffusiveFluxIntegralTempl< is_ad >::InterfaceDiffusiveFluxIntegralTempl(), InterfaceIntegralVariableValuePostprocessor::InterfaceIntegralVariableValuePostprocessor(), InterfaceKernelTempl< T >::InterfaceKernelTempl(), InterfaceTimeKernel::InterfaceTimeKernel(), InternalSideIndicatorBase::InternalSideIndicatorBase(), MultiAppGeometricInterpolationTransfer::interpolateTargetPoints(), EigenExecutionerBase::inversePowerIteration(), InversePowerMethod::InversePowerMethod(), Sampler::isAdaptiveSamplingCompleted(), MooseMesh::isBoundaryFullyExternalToSubdomains(), MooseVariableBase::isNodal(), IterationAdaptiveDT::IterationAdaptiveDT(), IterationCountConvergence::IterationCountConvergence(), LeastSquaresFit::LeastSquaresFit(), LibmeshPartitioner::LibmeshPartitioner(), libNameToAppName(), LibtorchNeuralNetControl::LibtorchNeuralNetControl(), LinearCombinationPostprocessor::LinearCombinationPostprocessor(), LinearNodalConstraint::LinearNodalConstraint(), LineMaterialSamplerBase< Real >::LineMaterialSamplerBase(), LineSearch::lineSearch(), LineValueSampler::LineValueSampler(), loadLibraryAndDependencies(), MultiAppGeneralFieldTransfer::locatePointReceivers(), LowerBoundNodalKernel::LowerBoundNodalKernel(), MooseLinearVariableFV< Real >::lowerDError(), PNGOutput::makePNG(), ReporterPointMarker::markerSetup(), SubProblem::markFamilyPRefinement(), MassMatrix::MassMatrix(), Material::Material(), MaterialRealTensorValueAuxTempl< is_ad >::MaterialRealTensorValueAuxTempl(), MaterialRealVectorValueAuxTempl< T, is_ad, is_functor >::MaterialRealVectorValueAuxTempl(), MaterialStdVectorRealGradientAux::MaterialStdVectorRealGradientAux(), Distribution::median(), FunctorRelationshipManager::mesh_reinit(), MeshDiagnosticsGenerator::MeshDiagnosticsGenerator(), MeshExtruderGenerator::MeshExtruderGenerator(), MeshRepairGenerator::MeshRepairGenerator(), SetupMeshAction::modifyParamsForUseSplit(), MeshMetaDataInterface::mooseErrorInternal(), MooseLinearVariableFV< Real >::MooseLinearVariableFV(), MooseMesh::MooseMesh(), MooseObject::MooseObject(), UserObjectInterface::mooseObjectError(), MooseStaticCondensationPreconditioner::MooseStaticCondensationPreconditioner(), MooseVariableBase::MooseVariableBase(), MooseVariableConstMonomial::MooseVariableConstMonomial(), MoveNodeGenerator::MoveNodeGenerator(), MultiApp::MultiApp(), MultiAppMFEMCopyTransfer::MultiAppMFEMCopyTransfer(), MultiAppPostprocessorTransfer::MultiAppPostprocessorTransfer(), MultiAppTransfer::MultiAppTransfer(), MultiAppUserObjectTransfer::MultiAppUserObjectTransfer(), MultiAppVariableValueSamplePostprocessorTransfer::MultiAppVariableValueSamplePostprocessorTransfer(), NearestNodeDistanceAux::NearestNodeDistanceAux(), FEProblemBase::needsPreviousNewtonIteration(), NewmarkBeta::NewmarkBeta(), NodalConstraint::NodalConstraint(), MooseVariableFV< Real >::nodalDofIndex(), MooseVariableFV< Real >::nodalDofIndexNeighbor(), MooseLinearVariableFV< Real >::nodalError(), MooseVariableFV< Real >::nodalMatrixTagValue(), NodalPatchRecoveryBase::nodalPatchRecovery(), NodalPatchRecoveryAuxBase::NodalPatchRecoveryAuxBase(), NodalScalarKernel::NodalScalarKernel(), MooseVariableFV< Real >::nodalValueArray(), MooseVariableFV< Real >::nodalValueOldArray(), MooseVariableFV< Real >::nodalValueOlderArray(), NodalVariableValue::NodalVariableValue(), MooseVariableFV< Real >::nodalVectorTagValue(), DistributedRectilinearMeshGenerator::nodeId(), MooseVariableFV< Real >::numberOfDofsNeighbor(), NumDOFs::NumDOFs(), NumFailedTimeSteps::NumFailedTimeSteps(), DistributedRectilinearMeshGenerator::numNeighbors(), NumNonlinearIterations::NumNonlinearIterations(), NumVars::NumVars(), Output::onInterval(), FunctorRelationshipManager::operator()(), RelationshipManager::operator==(), ActionComponent::outerSurfaceArea(), ActionComponent::outerSurfaceBoundaries(), XDA::output(), SolutionHistory::output(), Exodus::output(), Output::Output(), AdvancedOutput::outputElementalVariables(), AdvancedOutput::outputInput(), outputMachineReadableData(), AdvancedOutput::outputNodalVariables(), AdvancedOutput::outputPostprocessors(), AdvancedOutput::outputReporters(), AdvancedOutput::outputScalarVariables(), Exodus::outputSetup(), AdvancedOutput::outputSystemInformation(), Console::outputVectorPostprocessors(), AdvancedOutput::outputVectorPostprocessors(), DistributedRectilinearMeshGenerator::paritionSquarely(), PiecewiseBilinear::parse(), ParsedConvergence::ParsedConvergence(), ParsedCurveGenerator::ParsedCurveGenerator(), ParsedODEKernel::ParsedODEKernel(), MultiAppConservativeTransfer::performAdjustment(), ExplicitTimeIntegrator::performExplicitSolve(), PetscExternalPartitioner::PetscExternalPartitioner(), MooseVariableFV< Real >::phiLowerSize(), PhysicsBasedPreconditioner::PhysicsBasedPreconditioner(), PIDTransientControl::PIDTransientControl(), PiecewiseBilinear::PiecewiseBilinear(), PiecewiseLinearInterpolationMaterial::PiecewiseLinearInterpolationMaterial(), PiecewiseMulticonstant::PiecewiseMulticonstant(), PiecewiseMultiInterpolation::PiecewiseMultiInterpolation(), PiecewiseTabularBase::PiecewiseTabularBase(), CutMeshByLevelSetGeneratorBase::pointPairLevelSetInterception(), SolutionUserObjectBase::pointValueGradientWrapper(), SolutionUserObjectBase::pointValueWrapper(), ReporterInterface::possiblyCheckHasReporter(), VectorPostprocessorInterface::possiblyCheckHasVectorPostprocessorByName(), LStableDirk2::postResidual(), LStableDirk3::postResidual(), ImplicitMidpoint::postResidual(), ExplicitTVDRK2::postResidual(), LStableDirk4::postResidual(), AStableDirk4::postResidual(), ExplicitRK2::postResidual(), EigenProblem::postScaleEigenVector(), VariableCondensationPreconditioner::preallocateCondensedJacobian(), ADKernelValueTempl< T >::precomputeQpJacobian(), Predictor::Predictor(), TransientBase::preExecute(), MooseMesh::prepare(), MooseMesh::prepared(), FixedPointSolve::printFixedPointConvergenceReason(), PseudoTimestep::PseudoTimestep(), MultiApp::readCommandLineArguments(), PropertyReadFile::readData(), SolutionUserObjectBase::readExodusII(), SolutionUserObjectBase::readXda(), CoarsenBlockGenerator::recursiveCoarsen(), recursivelyCreateExecutors(), FunctorRelationshipManager::redistribute(), ReferenceResidualConvergence::ReferenceResidualConvergence(), registerRestartableData(), registerRestartableNameWithFilter(), Sampler::reinit(), RelativeSolutionDifferenceNorm::RelativeSolutionDifferenceNorm(), MFEMTransient::relativeSolutionDifferenceNorm(), removeRelationshipManager(), PhysicsBase::reportPotentiallyMissedParameters(), restore(), RinglebMesh::RinglebMesh(), RinglebMeshGenerator::RinglebMeshGenerator(), run(), runInputs(), PiecewiseMultiInterpolation::sample(), ScalarComponentIC::ScalarComponentIC(), MortarScalarBase::scalarVariable(), DistributedRectilinearMeshGenerator::scaleNodalPositions(), BicubicSplineFunction::secondDerivative(), MooseVariableFV< Real >::secondPhi(), MooseVariableFV< Real >::secondPhiFace(), MooseVariableFV< Real >::secondPhiFaceNeighbor(), MooseVariableFV< Real >::secondPhiNeighbor(), FunctorRelationshipManager::set_mesh(), MooseVariableBase::setActiveTags(), DistributedRectilinearMeshGenerator::setBoundaryNames(), MooseMesh::setCoordSystem(), FEProblemBase::setCoupling(), PiecewiseBase::setData(), FileOutput::setFileBaseInternal(), MooseMesh::setGeneralAxisymmetricCoordAxes(), FEProblemSolve::setInnerSolve(), MeshGenerator::setMeshProperty(), setMFEMDevice(), FVPointValueConstraint::setMyElem(), FEProblemBase::setNonlocalCouplingMatrix(), Sampler::setNumberOfCols(), Sampler::setNumberOfRandomSeeds(), Sampler::setNumberOfRows(), Exodus::setOutputDimensionInExodusWriter(), AddPeriodicBCAction::setPeriodicVars(), MFEMSolverBase::setPreconditioner(), MultiAppGeneralFieldTransfer::setSolutionVectorValues(), Split::setup(), TransientMultiApp::setupApp(), SetupMeshAction::setupMesh(), setupOptions(), TimeSequenceStepperBase::setupSequence(), TransientBase::setupTimeIntegrator(), TimePeriodBase::setupTimes(), IntegratedBCBase::shouldApply(), PhysicsBase::shouldCreateIC(), PhysicsBase::shouldCreateTimeDerivative(), PhysicsBase::shouldCreateVariable(), SideAdvectiveFluxIntegralTempl< is_ad >::SideAdvectiveFluxIntegralTempl(), SideDiffusiveFluxIntegralTempl< is_ad, Real >::SideDiffusiveFluxIntegralTempl(), SideSetsFromNormalsGenerator::SideSetsFromNormalsGenerator(), SideSetsFromPointsGenerator::SideSetsFromPointsGenerator(), SingleMatrixPreconditioner::SingleMatrixPreconditioner(), MooseVariableBase::sizeMatrixTagData(), SolutionTimeAdaptiveDT::SolutionTimeAdaptiveDT(), SolutionUserObjectBase::SolutionUserObjectBase(), ExplicitTVDRK2::solve(), ExplicitRK2::solve(), TimeIntegrator::solve(), FEProblemBase::solverSysNum(), FullSolveMultiApp::solveStep(), SpatialAverageBase::SpatialAverageBase(), UserObject::spatialPoints(), NearestPointIntegralVariablePostprocessor::spatialValue(), NearestPointAverage::spatialValue(), MeshDivisionFunctorReductionVectorPostprocessor::spatialValue(), UserObject::spatialValue(), SpiralAnnularMesh::SpiralAnnularMesh(), SpiralAnnularMeshGenerator::SpiralAnnularMeshGenerator(), WebServerControl::startServer(), StitchedMesh::StitchedMesh(), WebServerControl::stringifyJSONType(), MultiAppGeometricInterpolationTransfer::subdomainIDsNode(), Constraint::subdomainSetup(), NodalUserObject::subdomainSetup(), GeneralUserObject::subdomainSetup(), MaterialBase::subdomainSetup(), FEProblemBase::swapBackMaterialsNeighbor(), DisplacedProblem::systemBaseLinear(), Console::systemInfoFlags(), FEProblemBase::systemNumForVariable(), TerminateChainControl::terminate(), Terminator::Terminator(), CutMeshByLevelSetGeneratorBase::tet4ElemCutter(), ThreadedGeneralUserObject::threadJoin(), DiscreteElementUserObject::threadJoin(), GeneralUserObject::threadJoin(), Function::timeDerivative(), TimedSubdomainModifier::TimedSubdomainModifier(), TimeExtremeValue::TimeExtremeValue(), Function::timeIntegral(), MooseLinearVariableFV< Real >::timeIntegratorError(), TimeIntervalTimes::TimeIntervalTimes(), TimePeriodBase::TimePeriodBase(), VectorPostprocessorVisualizationAux::timestepSetup(), WebServerControl::toMiniJson(), MultiAppDofCopyTransfer::transfer(), MultiAppMFEMCopyTransfer::transfer(), MultiAppShapeEvaluationTransfer::transferVariable(), TransformedPositions::TransformedPositions(), FEProblemBase::trustUserCouplingMatrix(), MooseVariableScalar::uDot(), MooseVariableScalar::uDotDot(), MooseVariableScalar::uDotDotOld(), FEProblemBase::uDotDotOldRequested(), MooseVariableScalar::uDotOld(), FEProblemBase::uDotOldRequested(), MooseBase::uniqueName(), Positions::unrollMultiDPositions(), ScalarKernelBase::uOld(), AuxScalarKernel::uOld(), Checkpoint::updateCheckpointFiles(), EqualValueBoundaryConstraint::updateConstrainedNodes(), SolutionUserObjectBase::updateExodusBracketingTimeIndices(), FEProblemBase::updateMaxQps(), MFEMHypreADS::updateSolver(), MFEMHypreAMS::updateSolver(), MFEMHypreBoomerAMG::updateSolver(), MFEMOperatorJacobiSmoother::updateSolver(), MFEMHypreFGMRES::updateSolver(), MFEMCGSolver::updateSolver(), MFEMHyprePCG::updateSolver(), MFEMGMRESSolver::updateSolver(), MFEMHypreGMRES::updateSolver(), MFEMSuperLU::updateSolver(), UpperBoundNodalKernel::UpperBoundNodalKernel(), NearestPointIntegralVariablePostprocessor::userObjectValue(), NearestPointAverage::userObjectValue(), BoundingBoxIC::value(), PiecewiseConstantFromCSV::value(), IntegralPreservingFunctionIC::value(), Axisymmetric2D3DSolutionFunction::value(), Function::value(), ValueRangeMarker::ValueRangeMarker(), ValueThresholdMarker::ValueThresholdMarker(), VariableCondensationPreconditioner::VariableCondensationPreconditioner(), PhysicsBase::variableExists(), MultiAppTransfer::variableIntegrityCheck(), VariableTimeIntegrationAux::VariableTimeIntegrationAux(), AddVariableAction::variableType(), VariableValueVolumeHistogram::VariableValueVolumeHistogram(), VectorMagnitudeFunctorMaterialTempl< is_ad >::VectorMagnitudeFunctorMaterialTempl(), VectorNodalBC::VectorNodalBC(), SubProblem::vectorTagName(), SubProblem::vectorTagType(), MooseParsedGradFunction::vectorValue(), MooseParsedFunction::vectorValue(), Function::vectorValue(), SubProblem::verifyVectorTags(), ActionComponent::volume(), VTKOutput::VTKOutput(), WebServerControl::WebServerControl(), writeRestartableMetaData(), DOFMapOutput::writeStreamToFile(), and Console::writeStreamToFile().

268  {
269  callMooseError(argumentsToString(std::forward<Args>(args)...), /* with_prefix = */ true);
270  }
void callMooseError(std::string msg, const bool with_prefix, const hit::Node *node=nullptr) const
External method for calling moose error with added object context.
Definition: MooseBase.C:102

◆ mooseErrorNonPrefixed()

template<typename... Args>
void MooseBase::mooseErrorNonPrefixed ( Args &&...  args) const
inlineinherited

Emits an error without the prefixing included in mooseError().

Definition at line 286 of file MooseBase.h.

287  {
288  callMooseError(argumentsToString(std::forward<Args>(args)...), /* with_prefix = */ false);
289  }
void callMooseError(std::string msg, const bool with_prefix, const hit::Node *node=nullptr) const
External method for calling moose error with added object context.
Definition: MooseBase.C:102

◆ mooseInfo()

template<typename... Args>
void MooseBase::mooseInfo ( Args &&...  args) const
inlineinherited

Definition at line 317 of file MooseBase.h.

Referenced by SetupRecoverFileBaseAction::act(), AStableDirk4::AStableDirk4(), MeshDiagnosticsGenerator::checkNonConformalMeshFromAdaptivity(), MultiAppGeneralFieldNearestLocationTransfer::evaluateInterpValuesNearestNode(), PIDTransientControl::execute(), Executioner::Executioner(), ExplicitRK2::ExplicitRK2(), ExplicitTVDRK2::ExplicitTVDRK2(), DataFileInterface::getDataFilePath(), MFEMScalarFESpace::getFECName(), MultiAppTransfer::getPointInTargetAppFrame(), ImplicitMidpoint::ImplicitMidpoint(), ParsedDownSelectionPositions::initialize(), PropertyReadFile::initialize(), MultiAppGeneralFieldTransfer::initialSetup(), InversePowerMethod::InversePowerMethod(), LStableDirk2::LStableDirk2(), LStableDirk3::LStableDirk3(), LStableDirk4::LStableDirk4(), PNGOutput::makeMeshFunc(), NonlinearEigen::NonlinearEigen(), SolutionInvalidityOutput::output(), MultiAppGeneralFieldTransfer::outputValueConflicts(), MooseBase::paramInfo(), ProjectionAux::ProjectionAux(), ReferenceResidualConvergence::ReferenceResidualConvergence(), MFEMDataCollection::registerFields(), FEProblemBase::setRestartFile(), setupOptions(), SolutionUserObjectBase::SolutionUserObjectBase(), SymmetryTransformGenerator::SymmetryTransformGenerator(), TransientBase::takeStep(), and TransientBase::TransientBase().

318  {
319  moose::internal::mooseInfoStream(_console, messagePrefix(true), std::forward<Args>(args)...);
320  }
void mooseInfoStream(S &oss, Args &&... args)
Definition: MooseError.h:268
const ConsoleStream _console
An instance of helper class to write streams to the Console objects.
std::string messagePrefix(const bool hit_prefix=true) const
Definition: MooseBase.h:252

◆ mooseWarning()

template<typename... Args>
void MooseBase::mooseWarning ( Args &&...  args) const
inlineinherited

Emits a warning prefixed with object name and type.

Definition at line 295 of file MooseBase.h.

Referenced by CopyMeshPartitioner::_do_partition(), AddKernelAction::act(), MeshOnlyAction::act(), AddFunctionAction::act(), MaterialOutputAction::act(), CommonOutputAction::act(), MFEMProblem::addFunction(), MooseMesh::addPeriodicVariable(), DiracKernelBase::addPoint(), BoundaryMarker::BoundaryMarker(), DistributedRectilinearMeshGenerator::buildCube(), MultiAppVariableValueSamplePostprocessorTransfer::cacheElemToPostprocessorData(), CartesianMeshGenerator::CartesianMeshGenerator(), CheckOutputAction::checkConsoleOutput(), MultiAppTransfer::checkMultiAppExecuteOn(), MeshDiagnosticsGenerator::checkNonMatchingEdges(), ActionComponent::checkRequiredTasks(), PhysicsBase::checkRequiredTasks(), SampledOutput::cloneMesh(), MultiAppGeneralFieldTransfer::closestToPosition(), VariableValueElementSubdomainModifier::computeSubdomainID(), GapValueAux::computeValue(), MultiApp::createApp(), DebugResidualAux::DebugResidualAux(), MeshDiagnosticsGenerator::diagnosticsLog(), CartesianGridDivision::divisionIndex(), CylindricalGridDivision::divisionIndex(), SphericalGridDivision::divisionIndex(), ElementMaterialSampler::ElementMaterialSampler(), Postprocessor::evaluateDotWarning(), MeshDivisionFunctorReductionVectorPostprocessor::execute(), ElementQualityChecker::finalize(), FiniteDifferencePreconditioner::FiniteDifferencePreconditioner(), FixedPointSolve::FixedPointSolve(), SubdomainPerElementGenerator::generate(), StitchMeshGenerator::generate(), ParsedGenerateSideset::generate(), MultiAppTransfer::getAppInfo(), FunctorBinnedValuesDivision::getBinIndex(), DataFileInterface::getDataFilePath(), PointSamplerBase::getLocalElemContainingPoint(), FEProblemBase::getMaterial(), LineValueSampler::getValue(), Terminator::handleMessage(), IndicatorMarker::IndicatorMarker(), CartesianGridDivision::initialize(), CylindricalGridDivision::initialize(), SphericalGridDivision::initialize(), ElementGroupCentroidPositions::initialize(), MultiAppGeneralFieldNearestLocationTransfer::initialSetup(), BoundsBase::initialSetup(), ReferenceResidualConvergence::initialSetup(), MultiAppGeneralFieldTransfer::initialSetup(), FEProblemBase::initialSetup(), AdvancedOutput::initPostprocessorOrVectorPostprocessorLists(), MaterialBase::initStatefulProperties(), LeastSquaresFit::LeastSquaresFit(), IterationAdaptiveDT::limitDTToPostprocessorValue(), loadLibraryAndDependencies(), FEProblemBase::mesh(), MultiAppGeneralFieldTransfer::MultiAppGeneralFieldTransfer(), NewmarkBeta::NewmarkBeta(), NodalPatchRecovery::NodalPatchRecovery(), NonlocalIntegratedBC::NonlocalIntegratedBC(), NonlocalKernel::NonlocalKernel(), Output::Output(), MultiAppGeneralFieldTransfer::outputValueConflicts(), MooseBase::paramWarning(), PiecewiseConstantFromCSV::PiecewiseConstantFromCSV(), Executioner::problem(), PropertyReadFile::readData(), TestSourceStepper::rejectStep(), PhysicsBase::reportPotentiallyMissedParameters(), MaterialBase::resetQpProperties(), SecondTimeDerivativeAux::SecondTimeDerivativeAux(), MooseMesh::setCoordSystem(), SidesetAroundSubdomainUpdater::SidesetAroundSubdomainUpdater(), FEProblemBase::sizeZeroes(), TransientMultiApp::solveStep(), Tecplot::Tecplot(), TimeDerivativeAux::TimeDerivativeAux(), Checkpoint::updateCheckpointFiles(), SampledOutput::updateSample(), PiecewiseConstantFromCSV::value(), and VariableCondensationPreconditioner::VariableCondensationPreconditioner().

296  {
297  moose::internal::mooseWarningStream(_console, messagePrefix(true), std::forward<Args>(args)...);
298  }
void mooseWarningStream(S &oss, Args &&... args)
Definition: MooseError.h:220
const ConsoleStream _console
An instance of helper class to write streams to the Console objects.
std::string messagePrefix(const bool hit_prefix=true) const
Definition: MooseBase.h:252

◆ mooseWarningNonPrefixed()

template<typename... Args>
void MooseBase::mooseWarningNonPrefixed ( Args &&...  args) const
inlineinherited

Emits a warning without the prefixing included in mooseWarning().

Definition at line 304 of file MooseBase.h.

305  {
306  moose::internal::mooseWarningStream(_console, std::forward<Args>(args)...);
307  }
void mooseWarningStream(S &oss, Args &&... args)
Definition: MooseError.h:220
const ConsoleStream _console
An instance of helper class to write streams to the Console objects.

◆ multiAppLevel()

unsigned int MooseApp::multiAppLevel ( ) const
inline

The MultiApp Level.

Returns
The current number of levels from the master app

Definition at line 802 of file MooseApp.h.

Referenced by DefaultNonlinearConvergence::checkConvergence(), MultiApp::createApp(), OutputWarehouse::mooseConsole(), ConsoleUtils::outputFrameworkInformation(), and Console::write().

802 { return _multiapp_level; }
unsigned int _multiapp_level
Level of multiapp, the master is level 0. This used by the Console to indent output.
Definition: MooseApp.h:1507

◆ multiAppNumber()

unsigned int MooseApp::multiAppNumber ( ) const
inline

The MultiApp number.

Returns
The numbering in all the sub-apps on the same level

Definition at line 808 of file MooseApp.h.

Referenced by FileOutput::FileOutput(), and Console::outputSystemInformation().

808 { return _multiapp_number; }
unsigned int _multiapp_number
Numbering in all the sub-apps on the same level.
Definition: MooseApp.h:1510

◆ name()

const std::string& MooseBase::name ( ) const
inlineinherited

Get the name of the class.

Returns
The name of the class

Definition at line 99 of file MooseBase.h.

Referenced by AddElementalFieldAction::act(), CopyNodalVarsAction::act(), AdaptivityAction::act(), AddTimeStepperAction::act(), DeprecatedBlockAction::act(), SetupTimeIntegratorAction::act(), AddActionComponentAction::act(), SetupResidualDebugAction::act(), DisplayGhostingAction::act(), MaterialOutputAction::act(), AddPeriodicBCAction::act(), FEProblemBase::addAnyRedistributers(), Executioner::addAttributeReporter(), MFEMProblem::addAuxKernel(), FEProblemBase::addAuxKernel(), FEProblemBase::addAuxScalarKernel(), DisplacedProblem::addAuxVariable(), MFEMProblem::addBoundaryCondition(), FEProblemBase::addBoundaryCondition(), PhysicsComponentInterface::addComponent(), FEProblemBase::addConstraint(), FEProblemBase::addConvergence(), FEProblemBase::addDamper(), Registry::addDataFilePath(), FEProblemBase::addDGKernel(), FEProblemBase::addDiracKernel(), FEProblemBase::addDistribution(), addExecutor(), addExecutorParams(), MFEMProblem::addFESpace(), MFEMProblem::addFunction(), FEProblemBase::addFunction(), SubProblem::addFunctor(), MFEMProblem::addFunctorMaterial(), FEProblemBase::addFunctorMaterial(), FunctorMaterial::addFunctorProperty(), FunctorMaterial::addFunctorPropertyByBlocks(), FEProblemBase::addFVBC(), FEProblemBase::addFVInitialCondition(), FEProblemBase::addFVInterfaceKernel(), FEProblemBase::addFVKernel(), ADDGKernel::ADDGKernel(), FEProblemBase::addHDGKernel(), FEProblemBase::addIndicator(), MFEMProblem::addInitialCondition(), FEProblemBase::addInitialCondition(), FEProblemBase::addInterfaceKernel(), FEProblemBase::addInterfaceMaterial(), DiffusionLHDGKernel::additionalROVariables(), IPHDGAssemblyHelper::additionalROVariables(), MFEMProblem::addKernel(), FEProblemBase::addKernel(), FEProblemBase::addLinearFVBC(), FEProblemBase::addLinearFVKernel(), FEProblemBase::addMarker(), FEProblemBase::addMaterial(), FEProblemBase::addMaterialHelper(), ComponentMaterialPropertyInterface::addMaterials(), FEProblemBase::addMeshDivision(), addMeshGenerator(), ComponentMeshTransformHelper::addMeshGenerators(), CylinderComponent::addMeshGenerators(), MeshGenerator::addMeshSubgenerator(), MFEMProblem::addMFEMPreconditioner(), MFEMProblem::addMFEMSolver(), FEProblemBase::addMultiApp(), FEProblemBase::addNodalKernel(), InitialConditionWarehouse::addObject(), FEProblemBase::addObject(), ComponentPhysicsInterface::addPhysics(), SubProblem::addPiecewiseByBlockLambdaFunctor(), MFEMProblem::addPostprocessor(), FEProblemBase::addPostprocessor(), InitialConditionBase::addPostprocessorDependencyHelper(), UserObject::addPostprocessorDependencyHelper(), FEProblemBase::addPredictor(), CreateDisplacedProblemAction::addProxyRelationshipManagers(), Action::addRelationshipManager(), FEProblemBase::addReporter(), FEProblemBase::addSampler(), FEProblemBase::addScalarKernel(), FEProblemBase::addTimeIntegrator(), MFEMProblem::addTransfer(), FEProblemBase::addTransfer(), FEProblemBase::addUserObject(), InitialConditionBase::addUserObjectDependencyHelper(), UserObject::addUserObjectDependencyHelper(), AuxKernelTempl< Real >::addUserObjectDependencyHelper(), DisplacedProblem::addVariable(), FEProblemBase::addVectorPostprocessor(), UserObject::addVectorPostprocessorDependencyHelper(), MooseLinearVariableFV< Real >::adError(), Output::advancedExecuteOn(), AdvancedExtruderGenerator::AdvancedExtruderGenerator(), MooseVariableBase::allDofIndices(), appBinaryName(), appendMeshGenerator(), Registry::appNameFromAppPath(), MultiApp::appPostprocessorValue(), MultiApp::appProblem(), MultiApp::appProblemBase(), MultiApp::appUserObjectBase(), ArrayDGKernel::ArrayDGKernel(), ArrayParsedAux::ArrayParsedAux(), PhysicsBase::assignBlocks(), AStableDirk4::AStableDirk4(), AuxKernelTempl< Real >::AuxKernelTempl(), Function::average(), MultiApp::backup(), CoarsenedPiecewiseLinear::buildCoarsenedGrid(), MFEMFESpace::buildFEC(), PiecewiseTabularBase::buildFromFile(), MultiAppVariableValueSamplePostprocessorTransfer::cacheElemToPostprocessorData(), MooseBase::callMooseError(), ChangeOverFixedPointPostprocessor::ChangeOverFixedPointPostprocessor(), ChangeOverTimePostprocessor::ChangeOverTimePostprocessor(), PhysicsBase::checkBlockRestrictionIdentical(), PhysicsBase::checkComponentType(), ParsedConvergence::checkConvergence(), DefaultNonlinearConvergence::checkConvergence(), FEProblemBase::checkDependMaterialsHelper(), SamplerBase::checkForStandardFieldVariableType(), ReporterTransferInterface::checkHasReporterValue(), FEProblemBase::checkICRestartError(), Material::checkMaterialProperty(), checkMetaDataIntegrity(), Damper::checkMinDamping(), MultiAppTransfer::checkParentAppUserObjectExecuteOn(), Checkpoint::checkpointInfo(), DomainUserObject::checkVariable(), BlockRestrictable::checkVariable(), Coupleable::checkWritableVar(), MooseVariableFieldBase::componentName(), CompositeFunction::CompositeFunction(), MaterialBase::computeProperties(), FEProblemBase::computeUserObjectByName(), VectorPostprocessorVisualizationAux::computeValue(), MooseBase::connectControllableParams(), ConstantPostprocessor::ConstantPostprocessor(), Coupleable::coupledName(), CommonOutputAction::create(), MultiApp::createApp(), createExecutors(), MeshGeneratorSystem::createMeshGeneratorOrder(), createRecoverablePerfGraph(), CutMeshByPlaneGenerator::CutMeshByPlaneGenerator(), DebugResidualAux::DebugResidualAux(), MaterialBase::declareADProperty(), MeshGenerator::declareMeshesForSubByName(), MeshGenerator::declareNullMeshName(), MaterialBase::declareProperty(), DOFMapOutput::demangle(), DerivativeSumMaterialTempl< is_ad >::DerivativeSumMaterialTempl(), Registry::determineDataFilePath(), DGKernel::DGKernel(), DGKernelBase::DGKernelBase(), DomainUserObject::DomainUserObject(), DumpObjectsProblem::dumpObjectHelper(), ElementGroupCentroidPositions::ElementGroupCentroidPositions(), ElementMaterialSampler::ElementMaterialSampler(), ElementValueSampler::ElementValueSampler(), EigenKernel::enabled(), MooseMesh::errorIfDistributedMesh(), SolutionUserObjectBase::evalMeshFunction(), SolutionUserObjectBase::evalMeshFunctionGradient(), SolutionUserObjectBase::evalMultiValuedMeshFunction(), SolutionUserObjectBase::evalMultiValuedMeshFunctionGradient(), SideValueSampler::execute(), RestartableDataReporter::execute(), GreaterThanLessThanPostprocessor::execute(), PointValue::execute(), MultiAppNearestNodeTransfer::execute(), MultiAppProjectionTransfer::execute(), MultiAppUserObjectTransfer::execute(), WebServerControl::execute(), MultiAppGeneralFieldTransfer::execute(), ActionWarehouse::executeActionsWithAction(), Exodus::Exodus(), ExtraIDIntegralVectorPostprocessor::ExtraIDIntegralVectorPostprocessor(), FEProblemBase::FEProblemBase(), MultiApp::fillPositions(), MultiAppGeometricInterpolationTransfer::fillSourceInterpolationPoints(), PointSamplerBase::finalize(), ChainControl::fullControlDataName(), FunctionArrayAux::FunctionArrayAux(), FunctionDT::FunctionDT(), FunctionIC::functionName(), FVFunctionIC::functionName(), FunctorPositions::FunctorPositions(), FunctorSmootherTempl< T >::FunctorSmootherTempl(), FVInitialConditionTempl< T >::FVInitialConditionTempl(), FVOneVarDiffusionInterface::FVOneVarDiffusionInterface(), GapValueAux::GapValueAux(), MooseServer::gatherDocumentSymbols(), BoundaryDeletionGenerator::generate(), UniqueExtraIDMeshGenerator::generate(), RenameBlockGenerator::generate(), RenameBoundaryGenerator::generate(), GeneratedMeshGenerator::generate(), ParsedSubdomainGeneratorBase::generate(), StitchBoundaryMeshGenerator::generate(), StitchMeshGenerator::generate(), BreakMeshByBlockGenerator::generate(), ParsedExtraElementIDGenerator::generate(), XYDelaunayGenerator::generate(), SubdomainBoundingBoxGenerator::generate(), MeshGenerator::generateInternal(), InterfaceMaterial::getADMaterialProperty(), Material::getADMaterialProperty(), MultiAppTransfer::getAppInfo(), MultiApp::getBoundingBox(), MooseBase::getCheckedPointerParam(), getCheckpointDirectories(), Control::getControllableParameterByName(), Control::getControllableValue(), Control::getControllableValueByName(), FEProblemBase::getConvergence(), Registry::getDataFilePath(), UserObject::getDependObjects(), DistributionInterface::getDistribution(), FEProblemBase::getDistribution(), DistributionInterface::getDistributionByName(), ElementUOProvider::getElementalValueLong(), ElementUOProvider::getElementalValueReal(), MultiApp::getExecutioner(), getExecutor(), FEProblemBase::getExecutor(), OutputWarehouse::getFileNumbers(), FEProblemBase::getFunction(), SubProblem::getFunctor(), NodalPatchRecovery::getGenericMaterialProperty(), InterfaceMaterial::getGenericMaterialProperty(), Material::getGenericMaterialProperty(), AuxKernelTempl< Real >::getGenericMaterialProperty(), InterfaceMaterial::getGenericNeighborMaterialProperty(), InterfaceMaterial::getGenericNeighborMaterialPropertyByName(), Material::getGenericOptionalMaterialProperty(), MaterialBase::getGenericZeroMaterialProperty(), MFEMProblem::getGridFunction(), SolutionUserObjectBase::getLocalVarIndex(), Marker::getMarkerValue(), Material::getMaterial(), FEProblemBase::getMaterial(), Material::getMaterialByName(), NodalPatchRecovery::getMaterialProperty(), InterfaceMaterial::getMaterialProperty(), Material::getMaterialProperty(), AuxKernelTempl< Real >::getMaterialProperty(), SubProblem::getMaterialPropertyBlockNames(), SubProblem::getMaterialPropertyBoundaryNames(), NodalPatchRecovery::getMaterialPropertyOld(), InterfaceMaterial::getMaterialPropertyOld(), Material::getMaterialPropertyOld(), AuxKernelTempl< Real >::getMaterialPropertyOld(), NodalPatchRecovery::getMaterialPropertyOlder(), InterfaceMaterial::getMaterialPropertyOlder(), Material::getMaterialPropertyOlder(), AuxKernelTempl< Real >::getMaterialPropertyOlder(), MFEMGeneralUserObject::getMatrixCoefficient(), MFEMGeneralUserObject::getMatrixCoefficientByName(), MeshGenerator::getMesh(), FEProblemBase::getMeshDivision(), MeshGenerator::getMeshesByName(), getMeshGenerator(), MeshGenerator::getMeshGeneratorNameFromParam(), MeshGenerator::getMeshGeneratorNamesFromParam(), ActionWarehouse::getMooseAppName(), MultiAppTransfer::getMultiApp(), InterfaceMaterial::getNeighborADMaterialProperty(), InterfaceMaterial::getNeighborMaterialProperty(), InterfaceMaterial::getNeighborMaterialPropertyOld(), InterfaceMaterial::getNeighborMaterialPropertyOlder(), MooseServer::getObjectParameters(), Material::getOptionalADMaterialProperty(), Material::getOptionalMaterialProperty(), Material::getOptionalMaterialPropertyOld(), Material::getOptionalMaterialPropertyOlder(), OutputWarehouse::getOutput(), MooseBase::getParam(), FEProblemBase::getPositionsObject(), FEProblemBase::getPostprocessorValueByName(), ComponentMaterialPropertyInterface::getPropertyValue(), ReporterData::getReporterInfo(), getRestartableDataMap(), getRestartableDataMapName(), getRestartableMetaData(), FEProblemBase::getSampler(), MFEMGeneralUserObject::getScalarCoefficient(), MFEMGeneralUserObject::getScalarCoefficientByName(), TransientBase::getTimeStepperName(), ProjectedStatefulMaterialStorageAction::getTypeEnum(), FEProblemBase::getUserObject(), FEProblemBase::getUserObjectBase(), MFEMGeneralUserObject::getVectorCoefficient(), MFEMGeneralUserObject::getVectorCoefficientByName(), Terminator::handleMessage(), Control::hasControllableParameterByName(), FEProblemBase::hasConvergence(), FEProblemBase::hasFunction(), SubProblem::hasFunctor(), SubProblem::hasFunctorWithType(), hasMeshGenerator(), AdvancedOutput::hasOutputHelper(), FEProblemBase::hasPostprocessor(), FEProblemBase::hasPostprocessorValueByName(), hasRelationshipManager(), hasRestartableDataMap(), hasRestartableMetaData(), FEProblemBase::hasUserObject(), IterationAdaptiveDT::init(), AddVariableAction::init(), AdvancedOutput::init(), AdvancedOutput::initExecutionTypes(), AttribName::initFrom(), NestedDivision::initialize(), TransformedPositions::initialize(), BoundaryRestrictable::initializeBoundaryRestrictable(), JSONOutput::initialSetup(), SideFVFluxBCIntegral::initialSetup(), SolutionScalarAux::initialSetup(), MultiAppProjectionTransfer::initialSetup(), NodalVariableValue::initialSetup(), Console::initialSetup(), SolutionUserObjectBase::initialSetup(), AdvancedOutput::initOutputList(), AdvancedOutput::initPostprocessorOrVectorPostprocessorLists(), MaterialBase::initStatefulProperties(), Function::integral(), InterfaceKernelTempl< T >::InterfaceKernelTempl(), MultiAppGeometricInterpolationTransfer::interpolateTargetPoints(), MeshGenerator::isChildMeshGenerator(), DerivativeMaterialInterface< MortarScalarBase >::isNotObjectVariable(), MeshGenerator::isNullMeshName(), MooseBase::isParamSetByUser(), MooseBase::isParamValid(), MeshGenerator::isParentMeshGenerator(), LinearCombinationFunction::LinearCombinationFunction(), FEProblemBase::logAdd(), MooseLinearVariableFV< Real >::lowerDError(), Marker::Marker(), MaterialBase::markMatPropRequested(), MatDiffusionBase< Real >::MatDiffusionBase(), Material::Material(), MaterialDerivativeTestKernelBase< Real >::MaterialDerivativeTestKernelBase(), Distribution::median(), MemoryUsageReporter::MemoryUsageReporter(), MeshGenerator::meshPropertyPrefix(), MooseBase::messagePrefix(), OutputWarehouse::mooseConsole(), MooseVariableBase::MooseVariableBase(), MooseVariableInterface< Real >::MooseVariableInterface(), MultiAppGeneralFieldTransfer::MultiAppGeneralFieldTransfer(), MultiAppUserObjectTransfer::MultiAppUserObjectTransfer(), MooseLinearVariableFV< Real >::nodalError(), NodalPatchRecoveryAuxBase::NodalPatchRecoveryAuxBase(), NodalValueSampler::NodalValueSampler(), Registry::objData(), MeshGenerator::Comparator::operator()(), ProgressOutput::output(), DOFMapOutput::output(), Output::Output(), AdvancedOutput::outputElementalVariables(), ConsoleUtils::outputExecutionInformation(), MaterialOutputAction::outputHelper(), AdvancedOutput::outputInput(), AdvancedOutput::outputNodalVariables(), Exodus::outputPostprocessors(), AdvancedOutput::outputPostprocessors(), TableOutput::outputReporter(), AdvancedOutput::outputReporters(), AdvancedOutput::outputScalarVariables(), AdvancedOutput::outputSystemInformation(), AdvancedOutput::outputVectorPostprocessors(), ParsedCurveGenerator::ParsedCurveGenerator(), ParsedODEKernel::ParsedODEKernel(), ComponentPhysicsInterface::physicsExists(), PiecewiseBilinear::PiecewiseBilinear(), PiecewiseByBlockFunctorMaterialTempl< T >::PiecewiseByBlockFunctorMaterialTempl(), possiblyLoadRestartableMetaData(), PhysicsBase::prefix(), MooseMesh::prepare(), BlockRestrictionDebugOutput::printBlockRestrictionMap(), PerfGraphLivePrint::printStats(), MooseBase::queryParam(), MultiApp::readCommandLineArguments(), Receiver::Receiver(), Executor::Result::record(), AppFactory::reg(), Registry::registerObjectsTo(), FEProblemBase::registerRandomInterface(), registerRestartableDataMapName(), registerRestartableNameWithFilter(), GlobalParamsAction::remove(), MaterialBase::resetQpProperties(), MultiApp::restore(), ScalarComponentIC::ScalarComponentIC(), MultiApp::setAppOutputFileBase(), MooseMesh::setBoundaryName(), Control::setControllableValue(), Control::setControllableValueByName(), GlobalParamsAction::setDoubleIndexParam(), OutputWarehouse::setFileNumbers(), GlobalParamsAction::setParam(), FEProblemBase::setPostprocessorValueByName(), FEProblemBase::setResidualObjectParamsAndLog(), GlobalParamsAction::setScalarParam(), MooseMesh::setSubdomainName(), GlobalParamsAction::setTripleIndexParam(), NodeSetsGeneratorBase::setup(), Split::setup(), SideSetsGeneratorBase::setup(), TransientMultiApp::setupApp(), GlobalParamsAction::setVectorParam(), FullSolveMultiApp::showStatusMessage(), SideSetExtruderGenerator::SideSetExtruderGenerator(), TransientMultiApp::solveStep(), UserObject::spatialValue(), WebServerControl::startServer(), StitchedMesh::StitchedMesh(), SubProblem::storeBoundaryDelayedCheckMatProp(), SubProblem::storeBoundaryMatPropName(), MaterialBase::storeBoundaryZeroMatProp(), SubProblem::storeBoundaryZeroMatProp(), SubProblem::storeSubdomainDelayedCheckMatProp(), SubProblem::storeSubdomainMatPropName(), MaterialBase::storeSubdomainZeroMatProp(), SubProblem::storeSubdomainZeroMatProp(), ConstraintWarehouse::subdomainsCovered(), MaterialBase::subdomainSetup(), TaggingInterface::TaggingInterface(), MooseLinearVariableFV< Real >::timeIntegratorError(), VectorPostprocessorVisualizationAux::timestepSetup(), to_json(), MultiAppDofCopyTransfer::transfer(), MultiAppShapeEvaluationTransfer::transferVariable(), TransientMultiApp::TransientMultiApp(), MooseServer::traverseParseTreeAndFillSymbols(), MooseBase::typeAndName(), MooseBase::uniqueParameterName(), FVFluxBC::uOnGhost(), FVFluxBC::uOnUSub(), UserObject::UserObject(), UserObjectInterface::userObjectName(), ParsedAux::validateGenericVectorNames(), PhysicsBase::variableExists(), MultiAppTransfer::variableIntegrityCheck(), VectorMagnitudeFunctorMaterialTempl< is_ad >::VectorMagnitudeFunctorMaterialTempl(), Convergence::verboseOutput(), AdvancedOutput::wantOutput(), Coupleable::writableCoupledValue(), Coupleable::writableVariable(), Console::write(), and writeRestartableMetaData().

100  {
101  mooseAssert(_name.size(), "Empty name");
102  return _name;
103  }
const std::string & _name
The name of this class.
Definition: MooseBase.h:359

◆ outputMachineReadableData()

void MooseApp::outputMachineReadableData ( const std::string &  param,
const std::string &  start_marker,
const std::string &  end_marker,
const std::string &  data 
) const
protected

Outputs machine readable data (JSON, YAML, etc.) either to the screen (if no filename was provided as an argument to the parameter param) or to a file (if a filename was provided).

Definition at line 3568 of file MooseApp.C.

Referenced by runInputFile(), and setupOptions().

3572 {
3573  // Bool parameter, just to screen
3574  if (_pars.have_parameter<bool>(param))
3575  {
3576  Moose::out << start_marker << data << end_marker << std::endl;
3577  return;
3578  }
3579 
3580  // String parameter, to file
3581  const auto & filename = getParam<std::string>(param);
3582  // write to file
3583  std::ofstream out(filename.c_str());
3584  if (out.is_open())
3585  {
3586  std::ofstream out(filename.c_str());
3587  out << data << std::flush;
3588  out.close();
3589  }
3590  else
3591  mooseError("Unable to open file `", filename, "` for writing ", param, " data to it.");
3592 }
const InputParameters & _pars
The object&#39;s parameters.
Definition: MooseBase.h:362
bool have_parameter(std::string_view name) const
A wrapper around the Parameters base class method.
OStreamProxy out
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:267

◆ paramError()

template<typename... Args>
void MooseBase::paramError ( const std::string &  param,
Args...  args 
) const
inherited

Emits an error prefixed with the file and line number of the given param (from the input file) along with the full parameter path+name followed by the given args as the message.

If this object's parameters were not created directly by the Parser, then this function falls back to the normal behavior of mooseError - only printing a message using the given args.

Definition at line 435 of file MooseBase.h.

Referenced by HierarchicalGridPartitioner::_do_partition(), AutoCheckpointAction::act(), SetupDebugAction::act(), CommonOutputAction::act(), AddPeriodicBCAction::act(), ADConservativeAdvectionBC::ADConservativeAdvectionBC(), DiffusionCG::addFEKernels(), DiffusionFV::addFVKernels(), NEML2ModelExecutor::addGatheredParameter(), NEML2ModelExecutor::addGatheredVariable(), ADDGKernel::ADDGKernel(), CylinderComponent::addMeshGenerators(), AddPeriodicBCAction::AddPeriodicBCAction(), ReporterPointSource::addPoints(), ADIntegratedBCTempl< T >::ADIntegratedBCTempl(), ADKernelTempl< T >::ADKernelTempl(), ADNodalKernel::ADNodalKernel(), ADPenaltyPeriodicSegmentalConstraint::ADPenaltyPeriodicSegmentalConstraint(), ADPeriodicSegmentalConstraint::ADPeriodicSegmentalConstraint(), AdvancedExtruderGenerator::AdvancedExtruderGenerator(), AdvectiveFluxAux::AdvectiveFluxAux(), ADVectorFunctionDirichletBC::ADVectorFunctionDirichletBC(), AnnularMesh::AnnularMesh(), AnnularMeshGenerator::AnnularMeshGenerator(), ArrayBodyForce::ArrayBodyForce(), ArrayDGKernel::ArrayDGKernel(), ArrayDGLowerDKernel::ArrayDGLowerDKernel(), ArrayDirichletBC::ArrayDirichletBC(), ArrayHFEMDirichletBC::ArrayHFEMDirichletBC(), ArrayIntegratedBC::ArrayIntegratedBC(), ArrayKernel::ArrayKernel(), ArrayLowerDIntegratedBC::ArrayLowerDIntegratedBC(), ArrayParsedAux::ArrayParsedAux(), ArrayPenaltyDirichletBC::ArrayPenaltyDirichletBC(), ArrayVacuumBC::ArrayVacuumBC(), ArrayVarReductionAux::ArrayVarReductionAux(), ParsedSubdomainIDsGenerator::assignElemSubdomainID(), AuxKernelTempl< Real >::AuxKernelTempl(), BatchMeshGeneratorAction::BatchMeshGeneratorAction(), BlockDeletionGenerator::BlockDeletionGenerator(), BlockWeightedPartitioner::BlockWeightedPartitioner(), BoundsBase::BoundsBase(), BreakMeshByBlockGenerator::BreakMeshByBlockGenerator(), BuildArrayVariableAux::BuildArrayVariableAux(), PiecewiseTabularBase::buildFromFile(), MFEMMesh::buildMesh(), CartesianGridDivision::CartesianGridDivision(), checkComponent(), MeshGenerator::checkGetMesh(), ComponentInitialConditionInterface::checkInitialConditionsAllRequested(), BatchMeshGeneratorAction::checkInputParameterType(), PhysicsBase::checkIntegrityEarly(), PostprocessorInterface::checkParam(), FEProblemBase::checkProblemIntegrity(), MultiAppReporterTransfer::checkSiblingsTransferSupported(), Coupleable::checkVar(), MultiAppTransfer::checkVariable(), CircularBoundaryCorrectionGenerator::CircularBoundaryCorrectionGenerator(), CircularBoundaryCorrectionGenerator::circularCenterCalculator(), MultiAppGeneralFieldTransfer::closestToPosition(), CoarsenBlockGenerator::CoarsenBlockGenerator(), CombinerGenerator::CombinerGenerator(), ComponentInitialConditionInterface::ComponentInitialConditionInterface(), ComponentMaterialPropertyInterface::ComponentMaterialPropertyInterface(), CompositionDT::CompositionDT(), FunctorAux::computeValue(), ConcentricCircleMeshGenerator::ConcentricCircleMeshGenerator(), LibtorchNeuralNetControl::conditionalParameterError(), ConservativeAdvectionTempl< is_ad >::ConservativeAdvectionTempl(), ConstantVectorPostprocessor::ConstantVectorPostprocessor(), ContainsPointAux::ContainsPointAux(), CopyValueAux::CopyValueAux(), Coupleable::Coupleable(), CoupledForceTempl< is_ad >::CoupledForceTempl(), CoupledValueFunctionMaterialTempl< is_ad >::CoupledValueFunctionMaterialTempl(), MultiApp::createApp(), MeshGeneratorSystem::createMeshGenerator(), CylindricalGridDivision::CylindricalGridDivision(), DebugResidualAux::DebugResidualAux(), ConstantReporter::declareConstantReporterValue(), ConstantReporter::declareConstantReporterValues(), AccumulateReporter::declareLateValues(), DefaultMultiAppFixedPointConvergence::DefaultMultiAppFixedPointConvergence(), DGKernel::DGKernel(), DGKernelBase::DGKernelBase(), DGLowerDKernel::DGLowerDKernel(), DiffusionFluxAux::DiffusionFluxAux(), DomainUserObject::DomainUserObject(), EigenProblem::EigenProblem(), Eigenvalue::Eigenvalue(), ElementGroupCentroidPositions::ElementGroupCentroidPositions(), ElementLengthAux::ElementLengthAux(), ElementLpNormAux::ElementLpNormAux(), ExtraIDIntegralVectorPostprocessor::elementValue(), ElementValueSampler::ElementValueSampler(), ElementVectorL2Error::ElementVectorL2Error(), EqualValueEmbeddedConstraintTempl< is_ad >::EqualValueEmbeddedConstraintTempl(), ReporterPointSource::errorCheck(), StitchMeshGeneratorBase::errorMissingBoundary(), ExamplePatchMeshGenerator::ExamplePatchMeshGenerator(), MultiAppNearestNodeTransfer::execute(), MultiAppUserObjectTransfer::execute(), ExtraElementIDAux::ExtraElementIDAux(), ExtraElementIntegerDivision::ExtraElementIntegerDivision(), ExtraIDIntegralVectorPostprocessor::ExtraIDIntegralVectorPostprocessor(), FEProblemBase::FEProblemBase(), FEProblemSolve::FEProblemSolve(), FileMeshGenerator::FileMeshGenerator(), FillBetweenCurvesGenerator::FillBetweenCurvesGenerator(), FillBetweenSidesetsGenerator::FillBetweenSidesetsGenerator(), ReporterPointSource::fillPoint(), SpatialUserObjectVectorPostprocessor::fillPoints(), CombinerGenerator::fillPositions(), MultiApp::fillPositions(), InternalSideIndicatorBase::finalize(), ForcingFunctionAux::ForcingFunctionAux(), FullSolveMultiApp::FullSolveMultiApp(), FunctionArrayAux::FunctionArrayAux(), FunctionValuePostprocessor::FunctionValuePostprocessor(), FunctorADConverterTempl< T >::FunctorADConverterTempl(), FunctorAux::FunctorAux(), FunctorBinnedValuesDivision::FunctorBinnedValuesDivision(), FunctorCoordinatesFunctionAux::FunctorCoordinatesFunctionAux(), FunctorElementalGradientAuxTempl< is_ad >::FunctorElementalGradientAuxTempl(), FunctorExtremaPositions::FunctorExtremaPositions(), FunctorIC::FunctorIC(), FunctorPositions::FunctorPositions(), FunctorVectorElementalAuxTempl< is_ad >::FunctorVectorElementalAuxTempl(), FVAdvection::FVAdvection(), FVFluxBC::FVFluxBC(), FVInterfaceKernel::FVInterfaceKernel(), FVOneVarDiffusionInterface::FVOneVarDiffusionInterface(), FVTwoVarContinuityConstraint::FVTwoVarContinuityConstraint(), BoundaryDeletionGenerator::generate(), UniqueExtraIDMeshGenerator::generate(), ExtraNodesetGenerator::generate(), AddMetaDataGenerator::generate(), ElementsToTetrahedronsConverter::generate(), BlockToMeshConverterGenerator::generate(), BreakBoundaryOnSubdomainGenerator::generate(), FillBetweenCurvesGenerator::generate(), FillBetweenSidesetsGenerator::generate(), LowerDBlockFromSidesetGenerator::generate(), PlaneIDMeshGenerator::generate(), RenameBlockGenerator::generate(), RenameBoundaryGenerator::generate(), BlockDeletionGenerator::generate(), BreakMeshByBlockGenerator::generate(), CoarsenBlockGenerator::generate(), FlipSidesetGenerator::generate(), GeneratedMeshGenerator::generate(), ParsedSubdomainGeneratorBase::generate(), RefineBlockGenerator::generate(), RefineSidesetGenerator::generate(), AdvancedExtruderGenerator::generate(), CircularBoundaryCorrectionGenerator::generate(), CombinerGenerator::generate(), MeshCollectionGenerator::generate(), MeshExtruderGenerator::generate(), ParsedCurveGenerator::generate(), ParsedExtraElementIDGenerator::generate(), StackGenerator::generate(), XYZDelaunayGenerator::generate(), BreakMeshByElementGenerator::generate(), CutMeshByLevelSetGeneratorBase::generate(), XYDelaunayGenerator::generate(), XYMeshLineCutter::generate(), PatternedMeshGenerator::generate(), SubdomainBoundingBoxGenerator::generate(), GeneratedMeshGenerator::GeneratedMeshGenerator(), GenericFunctorGradientMaterialTempl< is_ad >::GenericFunctorGradientMaterialTempl(), GenericFunctorMaterialTempl< is_ad >::GenericFunctorMaterialTempl(), GenericFunctorTimeDerivativeMaterialTempl< is_ad >::GenericFunctorTimeDerivativeMaterialTempl(), GenericVectorFunctorMaterialTempl< is_ad >::GenericVectorFunctorMaterialTempl(), PropertyReadFile::getBlockData(), ComponentBoundaryConditionInterface::getBoundaryCondition(), MultiApp::getCommandLineArgs(), PropertyReadFile::getData(), PropertyReadFile::getFileNames(), Sampler::getGlobalSamples(), ComponentInitialConditionInterface::getInitialCondition(), NEML2Action::getInputParameterMapping(), MultiAppNearestNodeTransfer::getLocalEntitiesAndComponents(), Sampler::getLocalSamples(), MeshGenerator::getMeshGeneratorNameFromParam(), MeshGenerator::getMeshGeneratorNamesFromParam(), Sampler::getNextLocalRow(), FEProblemSolve::getParamFromNonlinearSystemVectorParam(), PostprocessorInterface::getPostprocessorNameInternal(), PostprocessorInterface::getPostprocessorValueInternal(), MultiAppNearestNodeTransfer::getTargetLocalNodes(), UserObjectInterface::getUserObjectBase(), UserObjectInterface::getUserObjectName(), HFEMDirichletBC::HFEMDirichletBC(), AddVariableAction::init(), MultiApp::init(), DistributedPositions::initialize(), BlockWeightedPartitioner::initialize(), BlockRestrictable::initializeBlockRestrictable(), BoundaryRestrictable::initializeBoundaryRestrictable(), PhysicsBase::initializePhysics(), JSONOutput::initialSetup(), MultiAppCloneReporterTransfer::initialSetup(), SolutionIC::initialSetup(), SideFVFluxBCIntegral::initialSetup(), ElementSubdomainModifierBase::initialSetup(), MultiAppVariableValueSamplePostprocessorTransfer::initialSetup(), MultiAppDofCopyTransfer::initialSetup(), MultiAppGeneralFieldNearestLocationTransfer::initialSetup(), HistogramVectorPostprocessor::initialSetup(), ReferenceResidualConvergence::initialSetup(), PiecewiseConstantFromCSV::initialSetup(), LibtorchControlValuePostprocessor::initialSetup(), MultiAppGeneralFieldTransfer::initialSetup(), SampledOutput::initSample(), AddMetaDataGenerator::inputChecker(), IntegratedBC::IntegratedBC(), InterfaceDiffusiveFluxIntegralTempl< is_ad >::InterfaceDiffusiveFluxIntegralTempl(), InterfaceValueUserObjectAux::InterfaceValueUserObjectAux(), InternalSideIndicatorBase::InternalSideIndicatorBase(), InterpolatedStatefulMaterialTempl< T >::InterpolatedStatefulMaterialTempl(), InversePowerMethod::InversePowerMethod(), IterationAdaptiveDT::IterationAdaptiveDT(), MultiApp::keepSolutionDuringRestore(), Kernel::Kernel(), LibtorchNeuralNetControl::LibtorchNeuralNetControl(), LinearCombinationFunction::LinearCombinationFunction(), LinearFVAdvectionDiffusionFunctorRobinBC::LinearFVAdvectionDiffusionFunctorRobinBC(), LowerDIntegratedBC::LowerDIntegratedBC(), PNGOutput::makeMeshFunc(), MatCoupledForce::MatCoupledForce(), MaterialADConverterTempl< T >::MaterialADConverterTempl(), MaterialFunctorConverterTempl< T >::MaterialFunctorConverterTempl(), MatrixSymmetryCheck::MatrixSymmetryCheck(), PatternedMeshGenerator::mergeSubdomainNameMaps(), MeshCollectionGenerator::MeshCollectionGenerator(), MeshDiagnosticsGenerator::MeshDiagnosticsGenerator(), MeshDivisionAux::MeshDivisionAux(), MeshGenerator::MeshGenerator(), MeshGeneratorComponent::MeshGeneratorComponent(), MFEMGenericFunctorMaterial::MFEMGenericFunctorMaterial(), MFEMGenericFunctorVectorMaterial::MFEMGenericFunctorVectorMaterial(), MooseLinearVariableFV< Real >::MooseLinearVariableFV(), UserObjectInterface::mooseObjectError(), MoosePreconditioner::MoosePreconditioner(), MooseStaticCondensationPreconditioner::MooseStaticCondensationPreconditioner(), MooseVariableBase::MooseVariableBase(), MortarConstraintBase::MortarConstraintBase(), MortarNodalAuxKernelTempl< ComputeValueType >::MortarNodalAuxKernelTempl(), MultiApp::moveApp(), MoveNodeGenerator::MoveNodeGenerator(), MultiApp::MultiApp(), MultiAppCloneReporterTransfer::MultiAppCloneReporterTransfer(), MultiAppGeneralFieldNearestLocationTransfer::MultiAppGeneralFieldNearestLocationTransfer(), MultiAppGeneralFieldShapeEvaluationTransfer::MultiAppGeneralFieldShapeEvaluationTransfer(), MultiAppGeneralFieldTransfer::MultiAppGeneralFieldTransfer(), MultiAppGeneralFieldUserObjectTransfer::MultiAppGeneralFieldUserObjectTransfer(), MultiAppGeometricInterpolationTransfer::MultiAppGeometricInterpolationTransfer(), MultiAppNearestNodeTransfer::MultiAppNearestNodeTransfer(), MultiAppPostprocessorInterpolationTransfer::MultiAppPostprocessorInterpolationTransfer(), MultiAppPostprocessorToAuxScalarTransfer::MultiAppPostprocessorToAuxScalarTransfer(), MultiAppPostprocessorTransfer::MultiAppPostprocessorTransfer(), MultiAppProjectionTransfer::MultiAppProjectionTransfer(), MultiAppReporterTransfer::MultiAppReporterTransfer(), MultiAppScalarToAuxScalarTransfer::MultiAppScalarToAuxScalarTransfer(), MultiAppShapeEvaluationTransfer::MultiAppShapeEvaluationTransfer(), MultiAppTransfer::MultiAppTransfer(), MultiAppUserObjectTransfer::MultiAppUserObjectTransfer(), MultiAppVariableValueSamplePostprocessorTransfer::MultiAppVariableValueSamplePostprocessorTransfer(), MultiAppVariableValueSampleTransfer::MultiAppVariableValueSampleTransfer(), MultiAppVectorPostprocessorTransfer::MultiAppVectorPostprocessorTransfer(), MultiSystemSolveObject::MultiSystemSolveObject(), NearestNodeValueAux::NearestNodeValueAux(), NEML2Action::NEML2Action(), NestedDivision::NestedDivision(), NodalBC::NodalBC(), NodalEqualValueConstraint::NodalEqualValueConstraint(), NodalKernel::NodalKernel(), NodalPatchRecoveryAux::NodalPatchRecoveryAux(), NodalValueSampler::NodalValueSampler(), Output::Output(), ParsedCurveGenerator::ParsedCurveGenerator(), ParsedFunctorMaterialTempl< is_ad >::ParsedFunctorMaterialTempl(), ParsedPostprocessor::ParsedPostprocessor(), PatternedMeshGenerator::PatternedMeshGenerator(), PenaltyPeriodicSegmentalConstraint::PenaltyPeriodicSegmentalConstraint(), PeriodicSegmentalConstraint::PeriodicSegmentalConstraint(), PIDTransientControl::PIDTransientControl(), PlaneDeletionGenerator::PlaneDeletionGenerator(), PlaneIDMeshGenerator::PlaneIDMeshGenerator(), PointwiseRenormalizeVector::PointwiseRenormalizeVector(), PolyLineMeshGenerator::PolyLineMeshGenerator(), ReporterInterface::possiblyCheckHasReporter(), VectorPostprocessorInterface::possiblyCheckHasVectorPostprocessor(), LibmeshPartitioner::prepareBlocksForSubdomainPartitioner(), ProjectedMaterialPropertyNodalPatchRecoveryAux::ProjectedMaterialPropertyNodalPatchRecoveryAux(), ProjectionAux::ProjectionAux(), PropertyReadFile::PropertyReadFile(), RandomIC::RandomIC(), MultiApp::readCommandLineArguments(), PropertyReadFile::readData(), SolutionUserObjectBase::readXda(), ReferenceResidualConvergence::ReferenceResidualConvergence(), RefineBlockGenerator::RefineBlockGenerator(), RefineSidesetGenerator::RefineSidesetGenerator(), RenameBlockGenerator::RenameBlockGenerator(), RenameBoundaryGenerator::RenameBoundaryGenerator(), ReporterPointSource::ReporterPointSource(), FEProblemBase::restoreSolutions(), SecondTimeDerivativeAux::SecondTimeDerivativeAux(), FEProblemBase::setLinearConvergenceNames(), FEProblemBase::setNonlinearConvergenceNames(), MooseMesh::setPartitioner(), NodeSetsGeneratorBase::setup(), SideSetsGeneratorBase::setup(), NEML2Action::setupDerivativeMappings(), NEML2Action::setupParameterDerivativeMappings(), TimeSequenceStepperBase::setupSequence(), SidesetAroundSubdomainUpdater::SidesetAroundSubdomainUpdater(), SideSetsFromBoundingBoxGenerator::SideSetsFromBoundingBoxGenerator(), SideValueSampler::SideValueSampler(), SingleRankPartitioner::SingleRankPartitioner(), SphericalGridDivision::SphericalGridDivision(), StitchBoundaryMeshGenerator::StitchBoundaryMeshGenerator(), StitchMeshGenerator::StitchMeshGenerator(), SymmetryTransformGenerator::SymmetryTransformGenerator(), Terminator::Terminator(), TimeDerivativeAux::TimeDerivativeAux(), Transfer::Transfer(), TransformGenerator::TransformGenerator(), TransientMultiApp::TransientMultiApp(), ParsedCurveGenerator::tSectionSpaceDefiner(), UniqueExtraIDMeshGenerator::UniqueExtraIDMeshGenerator(), UserObject::UserObject(), Checkpoint::validateExecuteOn(), ParsedAux::validateGenericVectorNames(), ParsedMaterialBase::validateVectorNames(), FunctorIC::value(), VariableCondensationPreconditioner::VariableCondensationPreconditioner(), VectorBodyForce::VectorBodyForce(), VectorFunctionDirichletBC::VectorFunctionDirichletBC(), VectorFunctionIC::VectorFunctionIC(), VolumeAux::VolumeAux(), WebServerControl::WebServerControl(), XYDelaunayGenerator::XYDelaunayGenerator(), XYMeshLineCutter::XYMeshLineCutter(), and XYZDelaunayGenerator::XYZDelaunayGenerator().

436 {
437  _pars.paramError(param, std::forward<Args>(args)...);
438 }
const InputParameters & _pars
The object&#39;s parameters.
Definition: MooseBase.h:362
void paramError(const std::string &param, Args... args) const
Emits a parameter error prefixed with the parameter location and object information if available...

◆ parameters()

const InputParameters& MooseBase::parameters ( ) const
inlineinherited

Get the parameters of the object.

Returns
The parameters of the object

Definition at line 127 of file MooseBase.h.

Referenced by MeshOnlyAction::act(), SplitMeshAction::act(), SetupDebugAction::act(), AddActionComponentAction::act(), CommonOutputAction::act(), Action::Action(), FEProblemBase::addAnyRedistributers(), MFEMProblem::addAuxKernel(), FEProblemBase::addAuxKernel(), FEProblemBase::addAuxScalarKernel(), MFEMProblem::addAuxVariable(), DisplacedProblem::addAuxVariable(), MFEMProblem::addBoundaryCondition(), FEProblemBase::addBoundaryCondition(), FEProblemBase::addConstraint(), FEProblemBase::addConvergence(), FEProblemBase::addDamper(), AddDefaultConvergenceAction::addDefaultMultiAppFixedPointConvergence(), FEProblemBase::addDefaultMultiAppFixedPointConvergence(), ReferenceResidualProblem::addDefaultNonlinearConvergence(), AddDefaultConvergenceAction::addDefaultNonlinearConvergence(), FEProblemBase::addDefaultNonlinearConvergence(), AddDefaultConvergenceAction::addDefaultSteadyStateConvergence(), FEProblemBase::addDefaultSteadyStateConvergence(), FEProblemBase::addDGKernel(), FEProblemBase::addDiracKernel(), FEProblemBase::addDistribution(), MFEMProblem::addFESpace(), MFEMProblem::addFunction(), FEProblemBase::addFunction(), MFEMProblem::addFunctorMaterial(), FEProblemBase::addFunctorMaterial(), FEProblemBase::addFVBC(), FEProblemBase::addFVInitialCondition(), FEProblemBase::addFVInterfaceKernel(), FEProblemBase::addFVKernel(), MFEMProblem::addGridFunction(), FEProblemBase::addHDGKernel(), FEProblemBase::addIndicator(), MFEMProblem::addInitialCondition(), FEProblemBase::addInitialCondition(), DiffusionPhysicsBase::addInitialConditions(), FEProblemBase::addInterfaceKernel(), FEProblemBase::addInterfaceMaterial(), MFEMProblem::addKernel(), FEProblemBase::addKernel(), FEProblemBase::addLinearFVBC(), FEProblemBase::addLinearFVKernel(), FEProblem::addLineSearch(), FEProblemBase::addMarker(), FEProblemBase::addMaterial(), FEProblemBase::addMaterialHelper(), FEProblemBase::addMeshDivision(), MFEMProblem::addMFEMFESpaceFromMOOSEVariable(), MFEMProblem::addMFEMPreconditioner(), MFEMProblem::addMFEMSolver(), FEProblemBase::addMultiApp(), FEProblemBase::addNodalKernel(), FEProblemBase::addObject(), FEProblemBase::addObjectParamsHelper(), FEProblemBase::addOutput(), MFEMProblem::addPostprocessor(), FEProblemBase::addPostprocessor(), FEProblemBase::addPredictor(), FEProblemBase::addReporter(), FEProblemBase::addSampler(), FEProblemBase::addScalarKernel(), MFEMProblem::addSubMesh(), FEProblemBase::addTimeIntegrator(), MFEMProblem::addTransfer(), FEProblemBase::addTransfer(), FEProblemBase::addUserObject(), MFEMProblem::addVariable(), DisplacedProblem::addVariable(), FEProblemBase::addVectorPostprocessor(), ADPiecewiseLinearInterpolationMaterial::ADPiecewiseLinearInterpolationMaterial(), AdvancedOutput::AdvancedOutput(), ADVectorFunctionDirichletBC::ADVectorFunctionDirichletBC(), AnnularMesh::AnnularMesh(), AnnularMeshGenerator::AnnularMeshGenerator(), Action::associateWithParameter(), AuxKernelTempl< Real >::AuxKernelTempl(), AuxScalarKernel::AuxScalarKernel(), BoundsBase::BoundsBase(), MooseMesh::buildTypedMesh(), PostprocessorInterface::checkParam(), AddDefaultConvergenceAction::checkUnusedMultiAppFixedPointConvergenceParameters(), AddDefaultConvergenceAction::checkUnusedNonlinearConvergenceParameters(), AddDefaultConvergenceAction::checkUnusedSteadyStateConvergenceParameters(), SampledOutput::cloneMesh(), LibtorchNeuralNetControl::conditionalParameterError(), Console::Console(), CommonOutputAction::create(), MultiApp::createApp(), Postprocessor::declareValue(), DumpObjectsProblem::deduceNecessaryParameters(), DefaultMultiAppFixedPointConvergence::DefaultMultiAppFixedPointConvergence(), DumpObjectsProblem::dumpObjectHelper(), DumpObjectsProblem::DumpObjectsProblem(), EigenProblem::EigenProblem(), Eigenvalue::Eigenvalue(), ElementMaterialSampler::ElementMaterialSampler(), ExamplePatchMeshGenerator::ExamplePatchMeshGenerator(), Executor::Executor(), Exodus::Exodus(), FEProblem::FEProblem(), FixedPointSolve::FixedPointSolve(), FunctorSmootherTempl< T >::FunctorSmootherTempl(), GapValueAux::GapValueAux(), ParsedSubdomainGeneratorBase::generate(), ActionWarehouse::getCurrentActionName(), ExecutorInterface::getExecutor(), Material::getMaterial(), ReporterInterface::getReporterName(), Reporter::getReporterValueName(), UserObjectInterface::getUserObjectName(), VectorPostprocessorInterface::getVectorPostprocessorName(), GhostingUserObject::GhostingUserObject(), MeshGeneratorSystem::hasDataDrivenAllowed(), AttribSystem::initFrom(), AttribDisplaced::initFrom(), BlockRestrictable::initializeBlockRestrictable(), FullSolveMultiApp::initialSetup(), FEProblemBase::initNullSpaceVectors(), InterfaceDiffusiveFluxIntegralTempl< is_ad >::InterfaceDiffusiveFluxIntegralTempl(), InterfaceIntegralVariableValuePostprocessor::InterfaceIntegralVariableValuePostprocessor(), InterfaceKernelTempl< T >::InterfaceKernelTempl(), isValid(), IterationAdaptiveDT::IterationAdaptiveDT(), LibtorchNeuralNetControl::LibtorchNeuralNetControl(), MFEMCGSolver::MFEMCGSolver(), MFEMGMRESSolver::MFEMGMRESSolver(), MFEMHypreADS::MFEMHypreADS(), MFEMHypreAMS::MFEMHypreAMS(), MFEMHypreBoomerAMG::MFEMHypreBoomerAMG(), MFEMHypreFGMRES::MFEMHypreFGMRES(), MFEMHypreGMRES::MFEMHypreGMRES(), MFEMHyprePCG::MFEMHyprePCG(), MFEMOperatorJacobiSmoother::MFEMOperatorJacobiSmoother(), MFEMSuperLU::MFEMSuperLU(), MooseObject::MooseObject(), UserObjectInterface::mooseObjectError(), MooseVariableInterface< Real >::MooseVariableInterface(), MultiApp::MultiApp(), MultiAppGeneralFieldTransfer::MultiAppGeneralFieldTransfer(), MultiAppGeneralFieldUserObjectTransfer::MultiAppGeneralFieldUserObjectTransfer(), MultiAppTransfer::MultiAppTransfer(), MultiAppVariableValueSamplePostprocessorTransfer::MultiAppVariableValueSamplePostprocessorTransfer(), NodeFaceConstraint::NodeFaceConstraint(), ConsoleUtils::outputLegacyInformation(), OverlayMeshGenerator::OverlayMeshGenerator(), MooseServer::parseDocumentForDiagnostics(), PenetrationAux::PenetrationAux(), PiecewiseBilinear::PiecewiseBilinear(), PiecewiseLinearInterpolationMaterial::PiecewiseLinearInterpolationMaterial(), NEML2Action::printSummary(), ProjectedStatefulMaterialStorageAction::processProperty(), PropertyReadFile::PropertyReadFile(), PseudoTimestep::PseudoTimestep(), RandomIC::RandomIC(), ReferenceResidualConvergence::ReferenceResidualConvergence(), InputParameterWarehouse::removeInputParameters(), FEProblem::setInputParametersFEProblem(), FEProblemBase::setInputParametersFEProblem(), FEProblemBase::setResidualObjectParamsAndLog(), SideSetsGeneratorBase::setup(), NonlinearSystemBase::shouldEvaluatePreSMOResidual(), SideSetsFromBoundingBoxGenerator::SideSetsFromBoundingBoxGenerator(), Moose::PetscSupport::storePetscOptions(), DumpObjectsProblem::stringifyParameters(), TaggingInterface::TaggingInterface(), Transfer::Transfer(), TransientBase::TransientBase(), VectorBodyForce::VectorBodyForce(), VectorFunctionDirichletBC::VectorFunctionDirichletBC(), VectorFunctionIC::VectorFunctionIC(), VectorMagnitudeFunctorMaterialTempl< is_ad >::VectorMagnitudeFunctorMaterialTempl(), and ~MooseApp().

127 { return _pars; }
const InputParameters & _pars
The object&#39;s parameters.
Definition: MooseBase.h:362

◆ paramInfo()

template<typename... Args>
void MooseBase::paramInfo ( const std::string &  param,
Args...  args 
) const
inherited

Emits an informational message prefixed with the file and line number of the given param (from the input file) along with the full parameter path+name followed by the given args as the message.

If this object's parameters were not created directly by the Parser, then this function falls back to the normal behavior of mooseInfo - only printing a message using the given args.

Definition at line 449 of file MooseBase.h.

Referenced by GridPartitioner::_do_partition(), ComboMarker::ComboMarker(), Control::Control(), FunctorIC::FunctorIC(), and TransientMultiApp::TransientMultiApp().

450 {
451  mooseInfo(_pars.paramMessage(param, std::forward<Args>(args)...));
452 }
std::string paramMessage(const std::string &param, Args... args) const
void mooseInfo(Args &&... args) const
Definition: MooseBase.h:317
const InputParameters & _pars
The object&#39;s parameters.
Definition: MooseBase.h:362

◆ paramWarning()

template<typename... Args>
void MooseBase::paramWarning ( const std::string &  param,
Args...  args 
) const
inherited

Emits a warning prefixed with the file and line number of the given param (from the input file) along with the full parameter path+name followed by the given args as the message.

If this object's parameters were not created directly by the Parser, then this function falls back to the normal behavior of mooseWarning - only printing a message using the given args.

Definition at line 442 of file MooseBase.h.

Referenced by GridPartitioner::_do_partition(), MultiAppTransfer::checkParentAppUserObjectExecuteOn(), EigenProblem::checkProblemIntegrity(), CombinerGenerator::copyIntoMesh(), DefaultMultiAppFixedPointConvergence::DefaultMultiAppFixedPointConvergence(), MultiAppNearestNodeTransfer::execute(), FEProblemSolve::FEProblemSolve(), UniqueExtraIDMeshGenerator::generate(), PlaneIDMeshGenerator::generate(), Terminator::initialSetup(), SampledOutput::initSample(), MooseMesh::MooseMesh(), FEProblemBase::setPreserveMatrixSparsityPattern(), and Terminator::Terminator().

443 {
444  mooseWarning(_pars.paramMessage(param, std::forward<Args>(args)...));
445 }
std::string paramMessage(const std::string &param, Args... args) const
const InputParameters & _pars
The object&#39;s parameters.
Definition: MooseBase.h:362
void mooseWarning(Args &&... args) const
Emits a warning prefixed with object name and type.
Definition: MooseBase.h:295

◆ parser() [1/2]

const Parser & MooseApp::parser ( ) const
Returns
The Parser

Definition at line 1987 of file MooseApp.C.

Referenced by ActionFactory::create().

1988 {
1989  mooseAssert(_parser, "Not set");
1990  return *_parser;
1991 }
const std::shared_ptr< Parser > _parser
Parser for parsing the input file (owns the root hit node)
Definition: MooseApp.h:1182

◆ parser() [2/2]

Parser & MooseApp::parser ( )

Definition at line 1994 of file MooseApp.C.

1995 {
1996  return const_cast<Parser &>(std::as_const(*this).parser());
1997 }
Class for parsing input files.
Definition: Parser.h:87

◆ perfGraph()

PerfGraph& MooseApp::perfGraph ( )
inline

Get the PerfGraph for this app.

Definition at line 166 of file MooseApp.h.

Referenced by PerfGraphInterface::perfGraph().

166 { return _perf_graph; }
PerfGraph & _perf_graph
The PerfGraph object for this application (recoverable)
Definition: MooseApp.h:1203

◆ possiblyLoadRestartableMetaData()

void MooseApp::possiblyLoadRestartableMetaData ( const RestartableDataMapName name,
const std::filesystem::path &  folder_base 
)

Loads the restartable meta data for name if it is available with the folder base folder_base.

Definition at line 2563 of file MooseApp.C.

Referenced by FileMesh::buildMesh(), FileMeshGenerator::generate(), and loadRestartableMetaData().

2565 {
2566  const auto & map_name = getRestartableDataMapName(name);
2567  const auto meta_data_folder_base = metaDataFolderBase(folder_base, map_name);
2568  if (RestartableDataReader::isAvailable(meta_data_folder_base))
2569  {
2571  reader.setErrorOnLoadWithDifferentNumberOfProcessors(false);
2572  reader.setInput(meta_data_folder_base);
2573  reader.restore();
2574  }
2575 }
Reader for restartable data written by the RestartableDataWriter.
static std::filesystem::path metaDataFolderBase(const std::filesystem::path &folder_base, const std::string &map_suffix)
The file suffix for meta data (header and data)
Definition: MooseApp.C:3079
bool forceRestart() const
Whether or not we are forcefully restarting (allowing the load of potentially incompatibie checkpoint...
Definition: MooseApp.h:1061
RestartableDataMap & getRestartableDataMap(const RestartableDataMapName &name)
Return a reference to restartable data for the specific type flag.
Definition: MooseApp.C:3460
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:99
const std::string & getRestartableDataMapName(const RestartableDataMapName &name) const
Definition: MooseApp.C:3487
static bool isAvailable(const std::filesystem::path &folder_base)

◆ postRestore()

virtual void MooseApp::postRestore ( const bool  )
inlinevirtual

Insertion point for other apps that is called after restore()

Parameters
for_restartWhether this restoration is explicitly for the first restoration of restart data

Definition at line 766 of file MooseApp.h.

Referenced by restore().

766 {}

◆ preBackup()

virtual void MooseApp::preBackup ( )
inlinevirtual

Insertion point for other apps that is called before backup()

Definition at line 732 of file MooseApp.h.

Referenced by backup().

732 {}

◆ processor_id()

processor_id_type MooseApp::processor_id ( ) const
inline

Returns the MPI processor ID of the current processor.

Definition at line 404 of file MooseApp.h.

Referenced by restartFolderBase(), FileOutput::setFileBaseInternal(), and writeRestartableMetaData().

404 { return _comm->rank(); }
const std::shared_ptr< libMesh::Parallel::Communicator > _comm
The MPI communicator this App is going to use.
Definition: MooseApp.h:1142

◆ queryParam()

template<typename T >
const T * MooseBase::queryParam ( const std::string &  name) const
inherited

Query a parameter for the object.

If the parameter is not valid, nullptr will be returned

Parameters
nameThe name of the parameter
Returns
A pointer to the parameter value, if it exists

Definition at line 391 of file MooseBase.h.

392 {
393  return isParamValid(name) ? &getParam<T>(name) : nullptr;
394 }
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:99
bool isParamValid(const std::string &name) const
Test if the supplied parameter is valid.
Definition: MooseBase.h:195

◆ rankMap()

const RankMap& MooseApp::rankMap ( )
inline

The RankMap is a useful object for determining how the processes are laid out on the physical nodes of the cluster.

Definition at line 161 of file MooseApp.h.

161 { return _rank_map; }
const RankMap _rank_map
The RankMap is a useful object for determining how the processes are laid out on the physical hardwar...
Definition: MooseApp.h:1209

◆ recursivelyCreateExecutors()

void MooseApp::recursivelyCreateExecutors ( const std::string &  current_executor_name,
std::list< std::string > &  possible_roots,
std::list< std::string > &  current_branch 
)
private

Internal function used to recursively create the executor objects.

Called by createExecutors

Parameters
current_executor_nameThe name of the executor currently needing to be built
possible_rootsThe names of executors that are currently candidates for being the root

Definition at line 2000 of file MooseApp.C.

Referenced by createExecutors().

2003 {
2004  // Did we already make this one?
2005  if (_executors.find(current_executor_name) != _executors.end())
2006  return;
2007 
2008  // Is this one already on the current branch (i.e. there is a cycle)
2009  if (std::find(current_branch.begin(), current_branch.end(), current_executor_name) !=
2010  current_branch.end())
2011  {
2012  std::stringstream exec_names_string;
2013 
2014  auto branch_it = current_branch.begin();
2015 
2016  exec_names_string << *branch_it++;
2017 
2018  for (; branch_it != current_branch.end(); ++branch_it)
2019  exec_names_string << ", " << *branch_it;
2020 
2021  exec_names_string << ", " << current_executor_name;
2022 
2023  mooseError("Executor cycle detected: ", exec_names_string.str());
2024  }
2025 
2026  current_branch.push_back(current_executor_name);
2027 
2028  // Build the dependencies first
2029  const auto & params = *_executor_params[current_executor_name].second;
2030 
2031  for (const auto & param : params)
2032  {
2033  if (params.have_parameter<ExecutorName>(param.first))
2034  {
2035  const auto & dependency_name = params.get<ExecutorName>(param.first);
2036 
2037  possible_roots.remove(dependency_name);
2038 
2039  if (!dependency_name.empty())
2040  recursivelyCreateExecutors(dependency_name, possible_roots, current_branch);
2041  }
2042  }
2043 
2044  // Add this Executor
2045  const auto & type = _executor_params[current_executor_name].first;
2046  addExecutor(type, current_executor_name, params);
2047 
2048  current_branch.pop_back();
2049 }
std::unordered_map< std::string, std::pair< std::string, std::unique_ptr< InputParameters > > > _executor_params
Used in building the Executors Maps the name of the Executor block to the <type, params> ...
Definition: MooseApp.h:1223
void recursivelyCreateExecutors(const std::string &current_executor_name, std::list< std::string > &possible_roots, std::list< std::string > &current_branch)
Internal function used to recursively create the executor objects.
Definition: MooseApp.C:2000
std::map< std::string, std::shared_ptr< Executor > > _executors
Pointers to all of the Executors for this run.
Definition: MooseApp.h:1218
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:89
void addExecutor(const std::string &type, const std::string &name, const InputParameters &params)
Definition: MooseApp.C:1967
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:267

◆ registerCapabilities()

void MooseApp::registerCapabilities ( )
private

Register all base MooseApp capabilities to the Moose::Capabilities registry.

Apps and Modules may register additional capabilities in their registerAll function.

◆ registerInterfaceObject()

template<class T >
void MooseApp::registerInterfaceObject ( T &  interface)

Registers an interface object for accessing with getInterfaceObjects.

This should be called within the constructor of the interface in interest.

Definition at line 1586 of file MooseApp.h.

Referenced by Coupleable::Coupleable(), MaterialPropertyInterface::MaterialPropertyInterface(), PetscOutputInterface::PetscOutputInterface(), and Reporter::Reporter().

1587 {
1588  static_assert(!std::is_base_of<MooseObject, T>::value, "T is not an interface");
1589 
1590  InterfaceRegistryObjects<T> * registry = nullptr;
1591  auto it = _interface_registry.find(typeid(T));
1592  if (it == _interface_registry.end())
1593  {
1594  auto new_registry = std::make_unique<InterfaceRegistryObjects<T>>();
1595  registry = new_registry.get();
1596  _interface_registry.emplace(typeid(T), std::move(new_registry));
1597  }
1598  else
1599  registry = static_cast<InterfaceRegistryObjects<T> *>(it->second.get());
1600 
1601  mooseAssert(std::count(registry->_objects.begin(), registry->_objects.end(), &interface) == 0,
1602  "Interface already registered");
1603  registry->_objects.push_back(&interface);
1604 }
std::map< std::type_index, std::unique_ptr< InterfaceRegistryObjectsBase > > _interface_registry
Registration for interface objects.
Definition: MooseApp.h:1557

◆ registerRestartableData() [1/2]

RestartableDataValue & MooseApp::registerRestartableData ( std::unique_ptr< RestartableDataValue data,
THREAD_ID  tid,
bool  read_only,
const RestartableDataMapName metaname = "" 
)

Definition at line 2482 of file MooseApp.C.

Referenced by createRecoverablePerfGraph(), createRecoverableSolutionInvalidity(), MeshGenerator::declareMeshProperty(), ReporterData::getRestartableDataHelper(), and Restartable::registerRestartableDataOnApp().

2486 {
2487  if (!metaname.empty() && tid != 0)
2488  mooseError(
2489  "The meta data storage for '", metaname, "' is not threaded, so the tid must be zero.");
2490 
2491  mooseAssert(metaname.empty() ||
2492  _restartable_meta_data.find(metaname) != _restartable_meta_data.end(),
2493  "The desired meta data name does not exist: " + metaname);
2494 
2495  // Select the data store for saving this piece of restartable data (mesh or everything else)
2496  auto & data_map =
2497  metaname.empty() ? _restartable_data[tid] : _restartable_meta_data[metaname].first;
2498 
2499  RestartableDataValue * stored_data = data_map.findData(data->name());
2500  if (stored_data)
2501  {
2502  if (data->typeId() != stored_data->typeId())
2503  mooseError("Type mismatch found in RestartableData registration of '",
2504  data->name(),
2505  "'\n\n Stored type: ",
2506  stored_data->type(),
2507  "\n New type: ",
2508  data->type());
2509  }
2510  else
2511  stored_data = &data_map.addData(std::move(data));
2512 
2513  if (!read_only)
2514  stored_data->setDeclared({});
2515 
2516  return *stored_data;
2517 }
std::unordered_map< RestartableDataMapName, std::pair< RestartableDataMap, std::string > > _restartable_meta_data
General storage for custom RestartableData that can be added to from outside applications.
Definition: MooseApp.h:1494
virtual const std::type_info & typeId() const =0
The type ID of the underlying data.
std::vector< RestartableDataMap > _restartable_data
Where the restartable data is held (indexed on tid)
Definition: MooseApp.h:1194
virtual std::string type() const =0
String identifying the type of parameter stored.
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:267
void setDeclared(const SetDeclaredKey)
Sets that this restartable value has been declared.
Abstract definition of a RestartableData value.

◆ registerRestartableData() [2/2]

RestartableDataValue& MooseApp::registerRestartableData ( const std::string &  name,
std::unique_ptr< RestartableDataValue data,
THREAD_ID  tid,
bool  read_only,
const RestartableDataMapName metaname = "" 
)

◆ registerRestartableDataMapName()

void MooseApp::registerRestartableDataMapName ( const RestartableDataMapName name,
std::string  suffix = "" 
)

Reserve a location for storing custom RestartableDataMap objects.

This should be called in the constructor of an application.

Parameters
nameA key to use for accessing the data object
suffixThe suffix to use when appending to checkpoint output, if not supplied the given name is used to generate the suffix (MyMetaData -> _mymetadata)

Definition at line 3477 of file MooseApp.C.

3478 {
3479  if (!suffix.empty())
3480  std::transform(suffix.begin(), suffix.end(), suffix.begin(), ::tolower);
3481  suffix.insert(0, "_");
3482  _restartable_meta_data.emplace(
3483  std::make_pair(name, std::make_pair(RestartableDataMap(), suffix)));
3484 }
std::unordered_map< RestartableDataMapName, std::pair< RestartableDataMap, std::string > > _restartable_meta_data
General storage for custom RestartableData that can be added to from outside applications.
Definition: MooseApp.h:1494
Storage for restartable data that is ordered based on insertion order.
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:99

◆ registerRestartableNameWithFilter()

void MooseApp::registerRestartableNameWithFilter ( const std::string &  name,
Moose::RESTARTABLE_FILTER  filter 
)
protected

NOTE: This is an internal function meant for MOOSE use only!

Register a piece of restartable data that will be used in a filter in/out during deserialization. Note however that this data will always be written to the restart file.

Parameters
nameThe full (unique) name.
filterThe filter name where to direct the name

Definition at line 1833 of file MooseApp.C.

Referenced by createRecoverablePerfGraph(), createRecoverableSolutionInvalidity(), and Restartable::registerRestartableNameWithFilterOnApp().

1835 {
1837  switch (filter)
1838  {
1839  case RESTARTABLE_FILTER::RECOVERABLE:
1840  _recoverable_data_names.insert(name);
1841  break;
1842  default:
1843  mooseError("Unknown filter");
1844  }
1845 }
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:99
RESTARTABLE_FILTER
The filter type applied to a particular piece of "restartable" data.
Definition: MooseTypes.h:792
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:267
DataNames _recoverable_data_names
Data names that will only be read from the restart file during RECOVERY.
Definition: MooseApp.h:1200

◆ registerTimedSection() [1/2]

PerfID PerfGraphInterface::registerTimedSection ( const std::string &  section_name,
const unsigned int  level 
) const
protectedinherited

Call to register a named section for timing.

Parameters
section_nameThe name of the code section to be timed
levelThe importance of the timer - lower is more important (0 will always come out)
Returns
The ID of the section - use when starting timing

Definition at line 53 of file PerfGraphInterface.C.

55 {
56  const auto timed_section_name = timedSectionName(section_name);
57  if (!moose::internal::getPerfGraphRegistry().sectionExists(timed_section_name))
58  return moose::internal::getPerfGraphRegistry().registerSection(timed_section_name, level);
59  else
60  return moose::internal::getPerfGraphRegistry().sectionID(timed_section_name);
61 }
PerfID registerSection(const std::string &section_name, const unsigned int level)
Call to register a named section for timing.
std::string timedSectionName(const std::string &section_name) const
PerfID sectionID(const std::string &section_name) const
Given a name return the PerfID The name of the section.
PerfGraphRegistry & getPerfGraphRegistry()
Get the global PerfGraphRegistry singleton.

◆ registerTimedSection() [2/2]

PerfID PerfGraphInterface::registerTimedSection ( const std::string &  section_name,
const unsigned int  level,
const std::string &  live_message,
const bool  print_dots = true 
) const
protectedinherited

Call to register a named section for timing.

Parameters
section_nameThe name of the code section to be timed
levelThe importance of the timer - lower is more important (0 will always come out)
live_messageThe message to be printed to the screen during execution
print_dotsWhether or not progress dots should be printed for this section
Returns
The ID of the section - use when starting timing

Definition at line 64 of file PerfGraphInterface.C.

68 {
69  const auto timed_section_name = timedSectionName(section_name);
70  if (!moose::internal::getPerfGraphRegistry().sectionExists(timed_section_name))
72  timedSectionName(section_name), level, live_message, print_dots);
73  else
74  return moose::internal::getPerfGraphRegistry().sectionID(timed_section_name);
75 }
PerfID registerSection(const std::string &section_name, const unsigned int level)
Call to register a named section for timing.
std::string timedSectionName(const std::string &section_name) const
PerfID sectionID(const std::string &section_name) const
Given a name return the PerfID The name of the section.
PerfGraphRegistry & getPerfGraphRegistry()
Get the global PerfGraphRegistry singleton.

◆ relationshipManagers()

const std::set<std::shared_ptr<RelationshipManager> >& MooseApp::relationshipManagers ( ) const
inline

Return the container of relationship managers.

Definition at line 1010 of file MooseApp.h.

Referenced by NumRelationshipManagers::getValue().

1011  {
1012  return _relationship_managers;
1013  }
std::set< std::shared_ptr< RelationshipManager > > _relationship_managers
The relationship managers that have been added.
Definition: MooseApp.h:1302

◆ removeRelationshipManager()

void MooseApp::removeRelationshipManager ( std::shared_ptr< RelationshipManager relationship_manager)
private

Purge this relationship manager from meshes and DofMaps and finally from us.

This method is private because only this object knows when we should remove relationship managers: when we are adding relationship managers to this object's storage, we perform an operator>= comparison between our existing RMs and the RM we are trying to add. If any comparison returns true, we do not add the new RM because the comparison indicates that we would gain no new coverage. However, if no comparison return true, then we add the new RM and we turn the comparison around! Consequently if our new RM is >= than any of our preexisting RMs, we remove those preexisting RMs using this method

Definition at line 3126 of file MooseApp.C.

Referenced by addRelationshipManager().

3127 {
3128  auto * const mesh = _action_warehouse.mesh().get();
3129  if (!mesh)
3130  mooseError("The MooseMesh should exist");
3131 
3132  const MeshBase * const undisp_lm_mesh = mesh->getMeshPtr();
3133  RelationshipManager * undisp_clone = nullptr;
3134  if (undisp_lm_mesh && hasRMClone(*rm, *undisp_lm_mesh))
3135  {
3136  undisp_clone = &getRMClone(*rm, *undisp_lm_mesh);
3137  const_cast<MeshBase *>(undisp_lm_mesh)->remove_ghosting_functor(*undisp_clone);
3138  }
3139 
3140  auto & displaced_mesh = _action_warehouse.displacedMesh();
3141  MeshBase * const disp_lm_mesh = displaced_mesh ? &displaced_mesh->getMesh() : nullptr;
3142  RelationshipManager * disp_clone = nullptr;
3143  if (disp_lm_mesh && hasRMClone(*rm, *disp_lm_mesh))
3144  {
3145  disp_clone = &getRMClone(*rm, *disp_lm_mesh);
3146  disp_lm_mesh->remove_ghosting_functor(*disp_clone);
3147  }
3148 
3149  if (_executioner)
3150  {
3151  auto & problem = feProblem();
3152  if (undisp_clone)
3153  {
3154  problem.removeAlgebraicGhostingFunctor(*undisp_clone);
3155  problem.removeCouplingGhostingFunctor(*undisp_clone);
3156  }
3157 
3158  auto * dp = problem.getDisplacedProblem().get();
3159  if (dp && disp_clone)
3160  dp->removeAlgebraicGhostingFunctor(*disp_clone);
3161  }
3162 
3163  _factory.releaseSharedObjects(*rm);
3164  _relationship_managers.erase(rm);
3165 }
bool hasRMClone(const RelationshipManager &template_rm, const MeshBase &mesh) const
Definition: MooseApp.C:3103
std::shared_ptr< MooseMesh > & displacedMesh()
RelationshipManager & getRMClone(const RelationshipManager &template_rm, const MeshBase &mesh) const
Return the relationship manager clone originally created from the provided template relationship mana...
Definition: MooseApp.C:3111
void remove_ghosting_functor(GhostingFunctor &ghosting_functor)
MeshBase & mesh
ActionWarehouse _action_warehouse
Where built actions are stored.
Definition: MooseApp.h:1176
FEProblemBase & feProblem() const
Definition: MooseApp.C:1960
std::shared_ptr< MooseMesh > & mesh()
std::shared_ptr< Executioner > _executioner
Pointer to the executioner of this run (typically build by actions)
Definition: MooseApp.h:1212
RelationshipManagers are used for describing what kinds of non-local resources are needed for an obje...
std::set< std::shared_ptr< RelationshipManager > > _relationship_managers
The relationship managers that have been added.
Definition: MooseApp.h:1302
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:267
Factory _factory
Definition: MooseApp.h:1250

◆ restartFolderBase()

std::filesystem::path MooseApp::restartFolderBase ( const std::filesystem::path &  folder_base) const

The file suffix for restartable data.

Definition at line 3087 of file MooseApp.C.

Referenced by FEProblemBase::initialSetup(), and Checkpoint::output().

3088 {
3089  auto folder = folder_base;
3090  folder += "-restart-" + std::to_string(processor_id());
3092 }
processor_id_type processor_id() const
Returns the MPI processor ID of the current processor.
Definition: MooseApp.h:404
static std::filesystem::path restartableDataFolder(const std::filesystem::path &folder_base)

◆ restore() [1/2]

void MooseApp::restore ( const std::filesystem::path &  folder_base,
const bool  for_restart 
)

Restore an application from file.

Parameters
folder_baseThe backup folder base
for_restartWhether this restoration is explicitly for the first restoration of restart data

You must call finalizeRestore() after this in order to finalize the restoration. The restore process is kept open in order to restore additional data after the initial restore (that is, the restoration of data that has already been declared).

Definition at line 1874 of file MooseApp.C.

Referenced by FEProblemBase::initialSetup(), and restoreFromInitialBackup().

1875 {
1876  TIME_SECTION("restore", 2, "Restoring Application from File");
1877 
1878  const DataNames filter_names = for_restart ? getRecoverableData() : DataNames{};
1879 
1880  _rd_reader.setInput(folder_base);
1881  _rd_reader.restore(filter_names);
1882 
1883  postRestore(for_restart);
1884 }
void setInput(std::unique_ptr< std::stringstream > header_stream, std::unique_ptr< std::stringstream > data_stream)
Sets the input stream for reading from the stringstreams header_stream and data_stream for the header...
RestartableDataReader _rd_reader
Definition: MooseApp.h:1527
virtual void postRestore(const bool)
Insertion point for other apps that is called after restore()
Definition: MooseApp.h:766
std::unordered_set< std::string > DataNames
void restore(const DataNames &filter_names={})
Restores the restartable data.
const DataNames & getRecoverableData() const
Return a reference to the recoverable data object.
Definition: MooseApp.h:714

◆ restore() [2/2]

void MooseApp::restore ( std::unique_ptr< Backup backup,
const bool  for_restart 
)

Restore an application from the backup backup.

Parameters
backupThe backup
for_restartWhether this restoration is explicitly for the first restoration of restart data

You must call finalizeRestore() after this in order to finalize the restoration. The restore process is kept open in order to restore additional data after the initial restore (that is, the restoration of data that has already been declared).

Definition at line 1887 of file MooseApp.C.

1888 {
1889  TIME_SECTION("restore", 2, "Restoring Application");
1890 
1891  const DataNames filter_names = for_restart ? getRecoverableData() : DataNames{};
1892 
1893  if (!backup)
1894  mooseError("MooseApp::restore(): Provided backup is not initialized");
1895 
1896  auto header = std::move(backup->header);
1897  mooseAssert(header, "Header not available");
1898 
1899  auto data = std::move(backup->data);
1900  mooseAssert(data, "Data not available");
1901 
1902  _rd_reader.setInput(std::move(header), std::move(data));
1903  _rd_reader.restore(filter_names);
1904 
1905  postRestore(for_restart);
1906 }
void setInput(std::unique_ptr< std::stringstream > header_stream, std::unique_ptr< std::stringstream > data_stream)
Sets the input stream for reading from the stringstreams header_stream and data_stream for the header...
RestartableDataReader _rd_reader
Definition: MooseApp.h:1527
virtual void postRestore(const bool)
Insertion point for other apps that is called after restore()
Definition: MooseApp.h:766
std::unique_ptr< Backup > backup()
Backs up the application memory in a Backup.
Definition: MooseApp.C:1859
virtual std::string header() const
Returns a string to be printed at the beginning of a simulation.
Definition: MooseApp.C:2906
std::unordered_set< std::string > DataNames
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:267
void restore(const DataNames &filter_names={})
Restores the restartable data.
const DataNames & getRecoverableData() const
Return a reference to the recoverable data object.
Definition: MooseApp.h:714

◆ restoreFromInitialBackup()

void MooseApp::restoreFromInitialBackup ( const bool  for_restart)

Restores from a "initial" backup, that is, one set in _initial_backup.

Parameters
for_restartWhether this restoration is explicitly for the first restoration of restart data

This is only used for restoration of multiapp subapps, which have been given a Backup from their parent on initialization. Said Backup is passed to this app via the "_initial_backup" private input parameter.

See restore() for more information

Definition at line 1909 of file MooseApp.C.

Referenced by FEProblemBase::initialSetup().

1910 {
1911  mooseAssert(hasInitialBackup(), "Missing initial backup");
1912  restore(std::move(*_initial_backup), for_restart);
1913 }
bool hasInitialBackup() const
Definition: MooseApp.h:994
void restore(const std::filesystem::path &folder_base, const bool for_restart)
Restore an application from file.
Definition: MooseApp.C:1874
std::unique_ptr< Backup > *const _initial_backup
The backup for use in initial setup; this will get set from the _initial_backup input parameter that ...
Definition: MooseApp.h:1563

◆ run()

void MooseApp::run ( )
virtual

Run the application.

Definition at line 2135 of file MooseApp.C.

Referenced by MooseServer::parseDocumentForDiagnostics().

2136 {
2137  TIME_SECTION("run", 3);
2138  if (getParam<bool>("show_docs"))
2139  {
2140  auto binname = appBinaryName();
2141  if (binname == "")
2142  mooseError("could not locate installed tests to run (unresolved binary/app name)");
2143  auto docspath = MooseUtils::docsDir(binname);
2144  if (docspath == "")
2145  mooseError("no installed documentation found");
2146 
2147  auto docmsgfile = MooseUtils::pathjoin(docspath, "docmsg.txt");
2148  std::string docmsg = "file://" + MooseUtils::realpath(docspath) + "/index.html";
2149  if (MooseUtils::pathExists(docmsgfile) && MooseUtils::checkFileReadable(docmsgfile))
2150  {
2151  std::ifstream ifs(docmsgfile);
2152  std::string content((std::istreambuf_iterator<char>(ifs)),
2153  (std::istreambuf_iterator<char>()));
2154  content.replace(content.find("$LOCAL_SITE_HOME"), content.length(), docmsg);
2155  docmsg = content;
2156  }
2157 
2158  Moose::out << docmsg << "\n";
2159  _early_exit_param = "--docs";
2160  _ready_to_exit = true;
2161  return;
2162  }
2163 
2164  if (showInputs() || copyInputs() || runInputs())
2165  {
2166  _early_exit_param = "--show-input, --copy-inputs, or --run";
2167  _ready_to_exit = true;
2168  return;
2169  }
2170 
2171  try
2172  {
2173  TIME_SECTION("setup", 2, "Setting Up");
2174  setupOptions();
2175  runInputFile();
2176  }
2177  catch (Parser::Error & err)
2178  {
2179  mooseAssert(_parser->getThrowOnError(), "Should be true");
2180  throw err;
2181  }
2182  catch (MooseRuntimeError & err)
2183  {
2184  mooseAssert(Moose::_throw_on_error, "Should be true");
2185  throw err;
2186  }
2187  catch (std::exception & err)
2188  {
2189  mooseError(err.what());
2190  }
2191 
2192  if (!_check_input)
2193  {
2194  TIME_SECTION("execute", 2, "Executing");
2196  }
2197  else
2198  {
2199  errorCheck();
2200  // Output to stderr, so it is easier for peacock to get the result
2201  Moose::err << "Syntax OK" << std::endl;
2202  }
2203 }
OStreamProxy err
std::string docsDir(const std::string &app_name)
Returns the directory of any installed docs/site.
Definition: MooseUtils.C:121
virtual void setupOptions()
Setup options based on InputParameters.
Definition: MooseApp.C:1235
const std::shared_ptr< Parser > _parser
Parser for parsing the input file (owns the root hit node)
Definition: MooseApp.h:1182
virtual std::string appBinaryName() const
Definition: MooseApp.h:137
bool runInputs()
Handles the run input parameter logic: Checks to see whether a directory exists in user space and lau...
Definition: MooseApp.C:2309
bool _check_input
true if we want to just check the input file
Definition: MooseApp.h:1299
std::string realpath(const std::string &path)
Wrapper around PetscGetRealPath, which is a cross-platform replacement for realpath.
Definition: MooseUtils.C:1231
bool showInputs() const
Prints a message showing the installable inputs for a given application (if getInstallableInputs has ...
Definition: MooseApp.C:2206
bool checkFileReadable(const std::string &filename, bool check_line_endings=false, bool throw_on_unreadable=true, bool check_for_git_lfs_pointer=true)
Checks to see if a file is readable (exists and permissions)
Definition: MooseUtils.C:250
std::filesystem::path pathjoin(const std::filesystem::path &p)
Definition: MooseUtils.C:59
virtual void executeExecutioner()
Execute the Executioner that was built.
Definition: MooseApp.C:1769
virtual void runInputFile()
Actually build everything in the input file.
Definition: MooseApp.C:1694
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:267
bool pathExists(const std::string &path)
Definition: MooseUtils.C:243
Exception to be thrown whenever we have _throw_on_error set and a mooseError() is emitted...
Definition: MooseError.h:143
bool _ready_to_exit
Definition: MooseApp.h:1256
bool copyInputs()
Handles the copy_inputs input parameter logic: Checks to see whether the passed argument is valid (a ...
Definition: MooseApp.C:2244
bool _throw_on_error
Variable to turn on exceptions during mooseError(), should only be used within MOOSE unit tests or wh...
Definition: Moose.C:780
void errorCheck()
Runs post-initialization error checking that cannot be run correctly unless the simulation has been f...
Definition: MooseApp.C:1733
std::string _early_exit_param
Indicates if simulation is ready to exit, and keeps track of which param caused it to exit...
Definition: MooseApp.h:1255

◆ runInputFile()

void MooseApp::runInputFile ( )
virtual

Actually build everything in the input file.

Definition at line 1694 of file MooseApp.C.

Referenced by run().

1695 {
1696  TIME_SECTION("runInputFile", 3);
1697 
1698  // If early exit param has been set, then just return
1699  if (_ready_to_exit)
1700  return;
1701 
1703 
1704  if (isParamSetByUser("mesh_only"))
1705  {
1706  _early_exit_param = "--mesh-only";
1707  _ready_to_exit = true;
1708  }
1709  else if (isParamSetByUser("split_mesh"))
1710  {
1711  _early_exit_param = "--split-mesh";
1712  _ready_to_exit = true;
1713  }
1714  else if (isParamSetByUser("parse_neml2_only"))
1715  {
1716  _early_exit_param = "--parse-neml2-only";
1717  _ready_to_exit = true;
1718  }
1719  else if (getParam<bool>("list_constructed_objects"))
1720  {
1721  // TODO: ask multiapps for their constructed objects
1722  _early_exit_param = "--list-constructed-objects";
1723  _ready_to_exit = true;
1724  std::stringstream ss;
1725  for (const auto & obj : _factory.getConstructedObjects())
1726  ss << obj << '\n';
1728  "list_constructed_objects", "**START OBJECT DATA**\n", "\n**END OBJECT DATA**", ss.str());
1729  }
1730 }
ActionWarehouse _action_warehouse
Where built actions are stored.
Definition: MooseApp.h:1176
void outputMachineReadableData(const std::string &param, const std::string &start_marker, const std::string &end_marker, const std::string &data) const
Outputs machine readable data (JSON, YAML, etc.) either to the screen (if no filename was provided as...
Definition: MooseApp.C:3568
Factory _factory
Definition: MooseApp.h:1250
void executeAllActions()
This method loops over all actions in the warehouse and executes them.
bool _ready_to_exit
Definition: MooseApp.h:1256
bool isParamSetByUser(const std::string &name) const
Test if the supplied parameter is set by a user, as opposed to not set or set to default.
Definition: MooseBase.h:201
std::string _early_exit_param
Indicates if simulation is ready to exit, and keeps track of which param caused it to exit...
Definition: MooseApp.h:1255

◆ runInputs()

bool MooseApp::runInputs ( )
private

Handles the run input parameter logic: Checks to see whether a directory exists in user space and launches the TestHarness to process the given directory.

Returns
a Boolean value used to indicate whether the application should exit early

Definition at line 2309 of file MooseApp.C.

Referenced by run().

2310 {
2311  if (isParamSetByUser("run"))
2312  {
2313  if (comm().size() > 1)
2314  mooseError("The --run option should not be ran in parallel");
2315 
2316  // Pass everything after --run on the cli to the TestHarness
2317  const auto find_run_it = std::as_const(*_command_line).findCommandLineParam("run");
2318  const auto & cl_entries = std::as_const(*_command_line).getEntries();
2319  mooseAssert(find_run_it != cl_entries.end(), "Didn't find the option");
2320  std::string test_args;
2321  for (auto it = std::next(find_run_it); it != cl_entries.end(); ++it)
2322  for (const auto & arg : it->raw_args)
2323  {
2324  test_args += " " + arg;
2326  }
2327 
2328  auto working_dir = MooseUtils::getCurrentWorkingDir();
2329  if (MooseUtils::findTestRoot() == "")
2330  {
2331  auto bin_name = appBinaryName();
2332  if (bin_name == "")
2333  mooseError("Could not locate binary name relative to installed location");
2334 
2335  auto cmd_name = Moose::getExecutableName();
2336  mooseError(
2337  "Could not locate installed tests from the current working directory:",
2338  working_dir,
2339  ".\nMake sure you are executing this command from within a writable installed inputs ",
2340  "directory.\nRun \"",
2341  cmd_name,
2342  " --copy-inputs <dir>\" to copy the contents of <dir> to a \"./",
2343  bin_name,
2344  "_<dir>\" directory.\nChange into that directory and try \"",
2345  cmd_name,
2346  " --run <dir>\" again.");
2347  }
2348 
2349  // Set this application as the app name for the moose_test_runner script that we're running
2350  setenv("MOOSE_TEST_RUNNER_APP_NAME", appBinaryName().c_str(), true);
2351 
2352  const std::string cmd = MooseUtils::runTestsExecutable() + test_args;
2353  Moose::out << "Working Directory: " << working_dir << "\nRunning Command: " << cmd << std::endl;
2354  mooseAssert(comm().size() == 1, "Should be run in serial");
2355  const auto return_value = system(cmd.c_str());
2356  if (!WIFEXITED(return_value))
2357  mooseError("Process exited unexpectedly");
2358  setExitCode(WEXITSTATUS(return_value));
2359  return true;
2360  }
2361 
2362  return false;
2363 }
virtual std::string appBinaryName() const
Definition: MooseApp.h:137
const Parallel::Communicator & comm() const
std::string runTestsExecutable()
Returns the location of either a local repo run_tests script - or an installed test executor script i...
Definition: MooseUtils.C:65
void add_command_line_name(const std::string &name)
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:267
std::string getCurrentWorkingDir()
Returns the current working directory as a string.
Definition: MooseUtils.C:432
void setExitCode(const int exit_code)
Sets the exit code that the application will exit with.
Definition: MooseApp.h:155
bool isParamSetByUser(const std::string &name) const
Test if the supplied parameter is set by a user, as opposed to not set or set to default.
Definition: MooseBase.h:201
std::string getExecutableName()
Gets the name of the running executable on Mac OS X and linux.
std::string findTestRoot()
Searches in the current working directory and then recursively up in each parent directory looking fo...
Definition: MooseUtils.C:75

◆ setCheckUnusedFlag()

void MooseApp::setCheckUnusedFlag ( bool  warn_is_error = false)
private

Set a flag so that the parser will either warn or error when unused variables are seen after parsing is complete.

Definition at line 1948 of file MooseApp.C.

Referenced by setupOptions().

1949 {
1950  _enable_unused_check = warn_is_error ? ERROR_UNUSED : WARN_UNUSED;
1951 }
enum MooseApp::UNUSED_CHECK _enable_unused_check

◆ setErrorOverridden()

void MooseApp::setErrorOverridden ( )

Set a flag so that the parser will throw an error if overridden parameters are detected.

Definition at line 2129 of file MooseApp.C.

Referenced by setupOptions().

2130 {
2131  _error_overridden = true;
2132 }
bool _error_overridden
Indicates whether warnings or errors are displayed when overridden parameters are detected...
Definition: MooseApp.h:1253

◆ setExecutioner()

void MooseApp::setExecutioner ( std::shared_ptr< Executioner > &&  executioner)
inline

Set the Executioner for this App.

Definition at line 336 of file MooseApp.h.

Referenced by CreateExecutionerAction::act().

336 { _executioner = executioner; }
std::shared_ptr< Executioner > _executioner
Pointer to the executioner of this run (typically build by actions)
Definition: MooseApp.h:1212

◆ setExecutor()

void MooseApp::setExecutor ( std::shared_ptr< Executor > &&  executor)
inline

Definition at line 337 of file MooseApp.h.

337 { _executor = executor; }
std::shared_ptr< Executor > _executor
Pointer to the Executor of this run.
Definition: MooseApp.h:1215

◆ setExitCode()

void MooseApp::setExitCode ( const int  exit_code)
inline

Sets the exit code that the application will exit with.

Definition at line 155 of file MooseApp.h.

Referenced by copyInputs(), executeExecutioner(), and runInputs().

155 { _exit_code = exit_code; }
int _exit_code
The exit code.
Definition: MooseApp.h:1258

◆ setExodusFileRestart()

void MooseApp::setExodusFileRestart ( bool  flag)
inline

Set the flag to indicate whether or not we need to use a separate Exodus reader to read the mesh BEFORE we create the mesh.

Definition at line 417 of file MooseApp.h.

Referenced by CopyNodalVarsAction::act(), and PhysicsBase::prepareCopyVariablesFromMesh().

417 { _initial_from_file = flag; }
bool _initial_from_file
This variable indicates when a request has been made to restart from an Exodus file.
Definition: MooseApp.h:1261

◆ setExReaderForRestart()

void MooseApp::setExReaderForRestart ( std::shared_ptr< libMesh::ExodusII_IO > &&  exreader)
inline

Set the Exodus reader to restart variables from an Exodus mesh file.

Definition at line 428 of file MooseApp.h.

Referenced by FileMesh::buildMesh(), and FileMeshGenerator::generate().

429  {
430  _ex_reader = exreader;
431  }
std::shared_ptr< libMesh::ExodusII_IO > _ex_reader
The Exodus reader when _initial_from_file is set to true.
Definition: MooseApp.h:1264

◆ setGlobalTimeOffset()

void MooseApp::setGlobalTimeOffset ( Real  offset)
inline

Each App has it's own local time.

The "global" time of the whole problem might be different. This offset is how far off the local App time is from the global time.

Definition at line 299 of file MooseApp.h.

299 { _global_time_offset = offset; }
Real _global_time_offset
Offset of the local App time to the "global" problem time.
Definition: MooseApp.h:1163

◆ setMFEMDevice()

void MooseApp::setMFEMDevice ( const std::string &  device_string,
Moose::PassKey< MFEMProblemSolve  
)

Create/configure the MFEM device with the provided device_string.

More than one device can be configured. If supplying multiple devices, they should be comma separated

Definition at line 3612 of file MooseApp.C.

Referenced by MFEMProblemSolve::MFEMProblemSolve().

3613 {
3614  const auto string_vec = MooseUtils::split(device_string, ",");
3615  auto string_set = std::set<std::string>(string_vec.begin(), string_vec.end());
3616  if (!_mfem_device)
3617  {
3618  _mfem_device = std::make_shared<mfem::Device>(device_string);
3619  _mfem_devices = std::move(string_set);
3620  _mfem_device->Print(Moose::out);
3621  }
3622  else if (!device_string.empty() && string_set != _mfem_devices)
3623  mooseError("Attempted to configure with MFEM devices '",
3624  MooseUtils::join(string_set, " "),
3625  "', but we have already configured the MFEM device object with the devices '",
3627  "'");
3628 }
std::string join(Iterator begin, Iterator end, const std::string &delimiter)
Python-like join function for strings over an iterator range.
Definition: MooseUtils.h:142
std::set< std::string > _mfem_devices
MFEM supported devices based on user-provided config.
Definition: MooseApp.h:1575
std::vector< std::string > split(const std::string &str, const std::string &delimiter, std::size_t max_count=std::numeric_limits< std::size_t >::max())
Python like split functions for strings.
Definition: MooseUtils.C:1126
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:267
std::shared_ptr< mfem::Device > _mfem_device
The MFEM Device object.
Definition: MooseApp.h:1572

◆ setOutputFileBase()

void MooseApp::setOutputFileBase ( const std::string &  output_file_base)

Override the selection of the output file base name.

Note: This method is supposed to be called by MultiApp only.

Definition at line 1678 of file MooseApp.C.

1679 {
1680  _output_file_base = output_file_base;
1681 
1682  // Reset the file base in the outputs
1684 
1685  // Reset the file base in multiapps (if they have been constructed yet)
1686  if (getExecutioner())
1687  for (auto & multi_app : feProblem().getMultiAppWarehouse().getObjects())
1688  multi_app->setAppOutputFileBase();
1689 
1690  _file_base_set_by_user = true;
1691 }
bool _file_base_set_by_user
Whether or not file base is set through input or setOutputFileBase by MultiApp.
Definition: MooseApp.h:1148
FEProblemBase & feProblem() const
Definition: MooseApp.C:1960
void resetFileBase()
Resets the file base for all FileOutput objects.
Executioner * getExecutioner() const
Retrieve the Executioner for this App.
Definition: MooseApp.C:2123
OutputWarehouse _output_warehouse
OutputWarehouse object for this App.
Definition: MooseApp.h:1179
std::string _output_file_base
The output file basename.
Definition: MooseApp.h:1145

◆ setOutputFileNumbers()

void MooseApp::setOutputFileNumbers ( const std::map< std::string, unsigned int > &  numbers)
inline

Store a map of outputter names and file numbers The MultiApp system requires this to get the file numbering to propagate down through the Multiapps.

Parameters
numbersMap of outputter names and file numbers
See also
MultiApp TransientMultiApp OutputWarehouse

Definition at line 527 of file MooseApp.h.

528  {
529  _output_file_numbers = numbers;
530  }
std::map< std::string, unsigned int > _output_file_numbers
Map of outputer name and file number (used by MultiApps to propagate file numbers down through the mu...
Definition: MooseApp.h:1296

◆ setOutputPosition()

void MooseApp::setOutputPosition ( const Point p)

Tell the app to output in a specific position.

Definition at line 2379 of file MooseApp.C.

2380 {
2381  _output_position_set = true;
2382  _output_position = p;
2384 
2385  if (_executioner.get())
2386  _executioner->parentOutputPositionChanged();
2387 }
bool _output_position_set
Whether or not an output position has been set for this app.
Definition: MooseApp.h:1151
void meshChanged()
Calls the meshChanged method for every output object.
std::shared_ptr< Executioner > _executioner
Pointer to the executioner of this run (typically build by actions)
Definition: MooseApp.h:1212
Point _output_position
The output position.
Definition: MooseApp.h:1154
OutputWarehouse _output_warehouse
OutputWarehouse object for this App.
Definition: MooseApp.h:1179

◆ setRecover()

void MooseApp::setRecover ( bool  value)

Definition at line 2918 of file MooseApp.C.

2919 {
2920  _recover = value;
2921 }
Real value(unsigned n, unsigned alpha, unsigned beta, Real x)
bool _recover
Whether or not this is a recovery run.
Definition: MooseApp.h:1270

◆ setRestart()

void MooseApp::setRestart ( bool  value)

Sets the restart/recover flags.

Parameters
stateThe state to set the flag to

Definition at line 2912 of file MooseApp.C.

Referenced by FEProblemBase::setRestartFile().

2913 {
2914  _restart = value;
2915 }
bool _restart
Whether or not this is a restart run.
Definition: MooseApp.h:1273
Real value(unsigned n, unsigned alpha, unsigned beta, Real x)

◆ setRestartRecoverFileBase()

void MooseApp::setRestartRecoverFileBase ( const std::string &  file_base)
inline

mutator for recover_base (set by RecoverBaseAction)

Definition at line 499 of file MooseApp.h.

Referenced by SetupRecoverFileBaseAction::act(), and FEProblemBase::setRestartFile().

500  {
501  if (file_base.empty())
503  else
504  _restart_recover_base = file_base;
505  }
std::list< std::string > getCheckpointFiles() const
Extract all possible checkpoint file names.
Definition: MooseApp.C:2422
std::string _restart_recover_base
The base name to restart/recover from. If blank then we will find the newest checkpoint file...
Definition: MooseApp.h:1288
std::string getLatestCheckpointFilePrefix(const std::list< std::string > &checkpoint_files)
Returns the most recent checkpoint prefix (the four numbers at the beginning) If a suitable file isn&#39;...
Definition: MooseUtils.C:815

◆ setStartTime()

void MooseApp::setStartTime ( Real  time)

Set the starting time for the simulation.

This will override any choice made in the input file.

Parameters
timeThe start time for the simulation.

Definition at line 2429 of file MooseApp.C.

Referenced by EigenExecutionerBase::EigenExecutionerBase(), and TransientBase::TransientBase().

2430 {
2431  _start_time_set = true;
2432  _start_time = time;
2433 }
Real _start_time
The time at which to start the simulation.
Definition: MooseApp.h:1160
bool _start_time_set
Whether or not an start time has been set.
Definition: MooseApp.h:1157

◆ setupOptions()

void MooseApp::setupOptions ( )
virtual

Setup options based on InputParameters.

Definition at line 1235 of file MooseApp.C.

Referenced by run().

1236 {
1237  TIME_SECTION("setupOptions", 5, "Setting Up Options");
1238 
1239  // Print the header, this is as early as possible
1240  if (header().length() && !getParam<bool>("suppress_header"))
1241  _console << header() << std::endl;
1242 
1243  if (getParam<bool>("error_unused"))
1244  setCheckUnusedFlag(true);
1245  else if (getParam<bool>("allow_unused"))
1246  setCheckUnusedFlag(false);
1247 
1248  if (getParam<bool>("error_override"))
1250 
1251  _distributed_mesh_on_command_line = getParam<bool>("distributed_mesh");
1252 
1253  if (getParam<bool>("trap_fpe"))
1254  {
1255  _trap_fpe = true;
1256  _perf_graph.setActive(false);
1257  if (getParam<bool>("no_trap_fpe"))
1258  mooseError("Cannot use both \"--trap-fpe\" and \"--no-trap-fpe\" flags.");
1259  }
1260  else if (getParam<bool>("no_trap_fpe"))
1261  _trap_fpe = false;
1262 
1263  // Turn all warnings in MOOSE to errors (almost see next logic block)
1264  Moose::_warnings_are_errors = getParam<bool>("error");
1265 
1266  // Deprecated messages can be toggled to errors independently from everything else.
1267  Moose::_deprecated_is_error = getParam<bool>("error_deprecated");
1268 
1269  if (isUltimateMaster()) // makes sure coloring isn't reset incorrectly in multi-app settings
1270  {
1271  // Set from command line
1272  auto color = getParam<MooseEnum>("color");
1273  if (!isParamSetByUser("color"))
1274  {
1275  // Set from deprecated --no-color
1276  if (getParam<bool>("no_color"))
1277  color = "off";
1278  // Set from environment
1279  else
1280  {
1281  char * c_color = std::getenv("MOOSE_COLOR");
1282  if (c_color)
1283  color.assign(std::string(c_color), "While assigning environment variable MOOSE_COLOR");
1284  }
1285  }
1286 
1287  if (color == "auto")
1288  Moose::setColorConsole(true);
1289  else if (color == "on")
1290  Moose::setColorConsole(true, true);
1291  else if (color == "off")
1292  Moose::setColorConsole(false);
1293  else
1294  mooseAssert(false, "Should not hit");
1295 
1296  // After setting color so that non-yellow deprecated is honored
1297  if (getParam<bool>("no_color"))
1298  mooseDeprecated("The --no-color flag is deprecated. Use '--color off' instead.");
1299  }
1300 
1301 // If there's no threading model active, but the user asked for
1302 // --n-threads > 1 on the command line, throw a mooseError. This is
1303 // intended to prevent situations where the user has potentially
1304 // built MOOSE incorrectly (neither TBB nor pthreads found) and is
1305 // asking for multiple threads, not knowing that there will never be
1306 // any threads launched.
1307 #if !LIBMESH_USING_THREADS
1308  if (libMesh::command_line_value("--n-threads", 1) > 1)
1309  mooseError("You specified --n-threads > 1, but there is no threading model active!");
1310 #endif
1311 
1312  // Build a minimal running application, ignoring the input file.
1313  if (getParam<bool>("minimal"))
1314  createMinimalApp();
1315 
1316  else if (getParam<bool>("display_version"))
1317  {
1318  Moose::out << getPrintableVersion() << std::endl;
1319  _early_exit_param = "--version";
1320  _ready_to_exit = true;
1321  return;
1322  }
1323  else if (getParam<bool>("help"))
1324  {
1325  _command_line->printUsage();
1326  _early_exit_param = "--help";
1327  _ready_to_exit = true;
1328  }
1329  else if (getParam<bool>("dump") || isParamSetByUser("dump_search"))
1330  {
1331  const std::string search =
1332  isParamSetByUser("dump_search") ? getParam<std::string>("dump_search") : "";
1333 
1334  JsonSyntaxTree tree(search);
1335 
1336  {
1337  TIME_SECTION("dump", 1, "Building Syntax Tree");
1339  }
1340 
1341  // Check if second arg is valid or not
1342  if ((tree.getRoot()).is_object())
1343  {
1344  // Turn off live printing so that it doesn't mess with the dump
1346 
1347  JsonInputFileFormatter formatter;
1348  Moose::out << "\n### START DUMP DATA ###\n"
1349  << formatter.toString(tree.getRoot()) << "\n### END DUMP DATA ###" << std::endl;
1350  _early_exit_param = "--dump";
1351  _ready_to_exit = true;
1352  }
1353  else
1354  mooseError("Search parameter '", search, "' was not found in the registered syntax.");
1355  }
1356  else if (getParam<bool>("registry"))
1357  {
1359 
1360  Moose::out << "Label\tType\tName\tClass\tFile\n";
1361 
1362  auto & objmap = Registry::allObjects();
1363  for (auto & entry : objmap)
1364  for (auto & obj : entry.second)
1365  Moose::out << entry.first << "\tobject\t" << obj->name() << "\t" << obj->_classname << "\t"
1366  << obj->_file << "\n";
1367 
1368  auto & actmap = Registry::allActions();
1369  for (auto & entry : actmap)
1370  {
1371  for (auto & act : entry.second)
1372  Moose::out << entry.first << "\taction\t" << act->_name << "\t" << act->_classname << "\t"
1373  << act->_file << "\n";
1374  }
1375  _early_exit_param = "--registry";
1376  _ready_to_exit = true;
1377  }
1378  else if (getParam<bool>("registry_hit"))
1379  {
1381 
1382  Moose::out << "### START REGISTRY DATA ###\n";
1383 
1384  hit::Section root("");
1385  auto sec = new hit::Section("registry");
1386  root.addChild(sec);
1387  auto objsec = new hit::Section("objects");
1388  sec->addChild(objsec);
1389 
1390  auto & objmap = Registry::allObjects();
1391  for (auto & entry : objmap)
1392  for (auto & obj : entry.second)
1393  {
1394  auto ent = new hit::Section("entry");
1395  objsec->addChild(ent);
1396  ent->addChild(new hit::Field("label", hit::Field::Kind::String, entry.first));
1397  ent->addChild(new hit::Field("type", hit::Field::Kind::String, "object"));
1398  ent->addChild(new hit::Field("name", hit::Field::Kind::String, obj->name()));
1399  ent->addChild(new hit::Field("class", hit::Field::Kind::String, obj->_classname));
1400  ent->addChild(new hit::Field("file", hit::Field::Kind::String, obj->_file));
1401  }
1402 
1403  auto actsec = new hit::Section("actions");
1404  sec->addChild(actsec);
1405  auto & actmap = Registry::allActions();
1406  for (auto & entry : actmap)
1407  for (auto & act : entry.second)
1408  {
1409  auto ent = new hit::Section("entry");
1410  actsec->addChild(ent);
1411  ent->addChild(new hit::Field("label", hit::Field::Kind::String, entry.first));
1412  ent->addChild(new hit::Field("type", hit::Field::Kind::String, "action"));
1413  ent->addChild(new hit::Field("task", hit::Field::Kind::String, act->_name));
1414  ent->addChild(new hit::Field("class", hit::Field::Kind::String, act->_classname));
1415  ent->addChild(new hit::Field("file", hit::Field::Kind::String, act->_file));
1416  }
1417 
1418  Moose::out << root.render();
1419 
1420  Moose::out << "\n### END REGISTRY DATA ###\n";
1421  _early_exit_param = "--registry_hit";
1422  _ready_to_exit = true;
1423  }
1424  else if (getParam<bool>("definition"))
1425  {
1427 
1428  JsonSyntaxTree tree("");
1430  SONDefinitionFormatter formatter;
1431  Moose::out << "%-START-SON-DEFINITION-%\n"
1432  << formatter.toString(tree.getRoot()) << "\n%-END-SON-DEFINITION-%\n";
1433  _early_exit_param = "--definition";
1434  _ready_to_exit = true;
1435  }
1436  else if (getParam<bool>("yaml") || isParamSetByUser("yaml_search"))
1437  {
1438  const std::string search =
1439  isParamSetByUser("yaml_search") ? getParam<std::string>("yaml_search") : "";
1441 
1443  _builder.buildFullTree(search);
1444 
1445  _early_exit_param = "--yaml";
1446  _ready_to_exit = true;
1447  }
1448  else if (getParam<bool>("json") || isParamSetByUser("json_search"))
1449  {
1450  const std::string search =
1451  isParamSetByUser("json_search") ? getParam<std::string>("json_search") : "";
1453 
1454  JsonSyntaxTree tree(search);
1456 
1458  "json", "**START JSON DATA**\n", "\n**END JSON DATA**", tree.getRoot().dump(2));
1459  _early_exit_param = "--json";
1460  _ready_to_exit = true;
1461  }
1462  else if (getParam<bool>("syntax"))
1463  {
1465 
1466  std::multimap<std::string, Syntax::ActionInfo> syntax = _syntax.getAssociatedActions();
1467  std::stringstream ss;
1468  for (const auto & it : syntax)
1469  ss << it.first << "\n";
1470  outputMachineReadableData("syntax", "**START SYNTAX DATA**\n", "**END SYNTAX DATA**", ss.str());
1471  _early_exit_param = "--syntax";
1472  _ready_to_exit = true;
1473  }
1474  else if (getParam<bool>("show_type"))
1475  {
1477 
1478  Moose::out << "MooseApp Type: " << type() << std::endl;
1479  _early_exit_param = "--show-type";
1480  _ready_to_exit = true;
1481  }
1482  else if (getParam<bool>("show_capabilities"))
1483  {
1485  outputMachineReadableData("show_capabilities",
1486  "**START JSON DATA**\n",
1487  "\n**END JSON DATA**",
1489  _ready_to_exit = true;
1490  }
1491  else if (isParamValid("check_capabilities"))
1492  {
1494  const auto & capabilities = getParam<std::string>("check_capabilities");
1495  auto [status, reason, doc] = Moose::Capabilities::getCapabilityRegistry().check(capabilities);
1496  const bool pass = status == CapabilityUtils::CERTAIN_PASS;
1497  _console << "Capabilities '" << capabilities << "' are " << (pass ? "" : "not ") << "fulfilled."
1498  << std::endl;
1499  _ready_to_exit = true;
1500  if (!pass)
1501  _exit_code = 77;
1502  return;
1503  }
1504  else if (!getInputFileNames().empty())
1505  {
1506  if (isParamSetByUser("recover"))
1507  {
1508  // We need to set the flag manually here since the recover parameter is a string type (takes
1509  // an optional filename)
1510  _recover = true;
1511  const auto & recover = getParam<std::string>("recover");
1512  if (recover.size())
1513  _restart_recover_base = recover;
1514  }
1515 
1516  _builder.build();
1517 
1518  if (isParamValid("required_capabilities"))
1519  {
1521 
1522  const auto required_capabilities = getParam<std::string>("required_capabilities");
1523  auto [status, reason, doc] =
1524  Moose::Capabilities::getCapabilityRegistry().check(required_capabilities);
1526  {
1527  mooseInfo("Required capabilities '", required_capabilities, "' not fulfilled.");
1528  _ready_to_exit = true;
1529  // we use code 77 as "skip" in the Testharness
1530  _exit_code = 77;
1531  return;
1532  }
1534  mooseError("Required capabilities '",
1535  required_capabilities,
1536  "' are not specific enough. A comparison test is performed on an undefined "
1537  "capability. Disambiguate this requirement by adding an existence/non-existence "
1538  "requirement. Example: 'unknown<1.2.3' should become 'unknown & unknown<1.2.3' "
1539  "or '!unknown | unknown<1.2.3'");
1540  }
1541 
1542  // Lambda to check for mutually exclusive parameters
1543  auto isExclusiveParamSetByUser =
1544  [this](const std::vector<std::string> & group, const std::string & param)
1545  {
1546  auto is_set = isParamSetByUser(param);
1547  if (is_set)
1548  for (const auto & p : group)
1549  if (p != param && isParamSetByUser(p))
1550  mooseError("Parameters '" + p + "' and '" + param +
1551  "' are mutually exclusive. Please choose only one of them.");
1552  return is_set;
1553  };
1554 
1555  // The following parameters set the final task and so are mutually exclusive.
1556  const std::vector<std::string> final_task_params = {
1557  "mesh_only", "split_mesh", "parse_neml2_only"};
1558  if (isExclusiveParamSetByUser(final_task_params, "mesh_only"))
1559  {
1560  // If we are looking to just check the input, there is no need to
1561  // call MeshOnlyAction and generate a mesh
1562  if (_check_input)
1563  _action_warehouse.setFinalTask("setup_mesh_complete");
1564  else
1565  {
1566  _syntax.registerTaskName("mesh_only", true);
1567  _syntax.addDependency("mesh_only", "setup_mesh_complete");
1568  _syntax.addDependency("determine_system_type", "mesh_only");
1569  _action_warehouse.setFinalTask("mesh_only");
1570  }
1571  }
1572  else if (isExclusiveParamSetByUser(final_task_params, "split_mesh"))
1573  {
1574  _split_mesh = true;
1575  _syntax.registerTaskName("split_mesh", true);
1576  _syntax.addDependency("split_mesh", "setup_mesh_complete");
1577  _syntax.addDependency("determine_system_type", "split_mesh");
1578  _action_warehouse.setFinalTask("split_mesh");
1579  }
1580  else if (isExclusiveParamSetByUser(final_task_params, "parse_neml2_only"))
1581  {
1582  _syntax.registerTaskName("parse_neml2");
1583  _syntax.addDependency("determine_system_type", "parse_neml2");
1584  _action_warehouse.setFinalTask("parse_neml2");
1585  }
1587 
1588  // Setup the AppFileBase for use by the Outputs or other systems that need output file info
1589  {
1590  // Extract the CommonOutputAction
1591  const auto common_actions = _action_warehouse.getActions<CommonOutputAction>();
1592  mooseAssert(common_actions.size() <= 1, "Should not be more than one CommonOutputAction");
1593  const Action * common = common_actions.empty() ? nullptr : *common_actions.begin();
1594 
1595  // If file_base is set in CommonOutputAction through parsing input, obtain the file_base
1596  if (common && common->isParamValid("file_base"))
1597  {
1598  _output_file_base = common->getParam<std::string>("file_base");
1599  _file_base_set_by_user = true;
1600  }
1601  else if (isUltimateMaster())
1602  {
1603  // if this app is a master, we use the first input file name as the default file base.
1604  // use proximate here because the input file is an absolute path
1605  const auto & base = getLastInputFileName();
1606  size_t pos = base.find_last_of('.');
1607  _output_file_base = base.substr(0, pos);
1608  // Note: we did not append "_out" in the file base here because we do not want to
1609  // have it in between the input file name and the object name for Output/*
1610  // syntax.
1611  }
1612  // default file base for multiapps is set by MultiApp
1613  }
1614  }
1615  // No input file provided but we have other arguments (so don't just show print usage)
1616  else if (!isParamSetByUser("input_file") && _command_line->getArguments().size() > 2)
1617  {
1618  mooseAssert(getInputFileNames().empty(), "Should be empty");
1619 
1620  if (_check_input)
1621  mooseError("You specified --check-input, but did not provide an input file. Add -i "
1622  "<inputfile> to your command line.");
1623 
1624  mooseError("No input files specified. Add -i <inputfile> to your command line.");
1625  }
1626  else if (isParamValid("language_server") && getParam<bool>("language_server"))
1627  {
1629 
1630  // Reset output to the buffer what was cached before it was turned it off
1631  if (!Moose::out.rdbuf() && _output_buffer_cache)
1632  Moose::out.rdbuf(_output_buffer_cache);
1633 
1634  // Start a language server that communicates using an iostream connection
1635  MooseServer moose_server(*this);
1636 
1637  moose_server.run();
1638 
1639  _early_exit_param = "--language-server";
1640  _ready_to_exit = true;
1641  }
1642 
1643  else /* The catch-all case for bad options or missing options, etc. */
1644  {
1645  _command_line->printUsage();
1646  _early_exit_param = "bad or missing";
1647  _ready_to_exit = true;
1648  _exit_code = 1;
1649  }
1650 
1651  Moose::out << std::flush;
1652 }
void mooseInfo(Args &&... args) const
Definition: MooseBase.h:317
void build()
Parse an input file (or text string if provided) consisting of hit syntax and setup objects in the MO...
Definition: Builder.C:319
PerfGraph & _perf_graph
The PerfGraph object for this application (recoverable)
Definition: MooseApp.h:1203
bool isUltimateMaster() const
Whether or not this app is the ultimate master app.
Definition: MooseApp.h:813
std::string _restart_recover_base
The base name to restart/recover from. If blank then we will find the newest checkpoint file...
Definition: MooseApp.h:1288
const std::multimap< std::string, ActionInfo > & getAssociatedActions() const
Return all Syntax to Action associations.
Definition: Syntax.C:374
void buildFullTree(const std::string &search_string)
Use MOOSE Factories to construct a full parse tree for documentation or echoing input.
Definition: Builder.C:597
bool _file_base_set_by_user
Whether or not file base is set through input or setOutputFileBase by MultiApp.
Definition: MooseApp.h:1148
void addDependency(const std::string &task, const std::string &pre_req)
Definition: Syntax.C:60
void setCheckUnusedFlag(bool warn_is_error=false)
Set a flag so that the parser will either warn or error when unused variables are seen after parsing ...
Definition: MooseApp.C:1948
bool _warnings_are_errors
Variable to toggle any warning into an error (includes deprecated code warnings)
Definition: Moose.C:778
void registerTaskName(const std::string &task, bool should_auto_build=false)
Method to register a new task.
Definition: Syntax.C:20
static const std::map< std::string, std::vector< std::shared_ptr< RegistryEntryBase > > > & allActions()
Returns a per-label keyed map of all Actions in the registry.
Definition: Registry.h:227
void setFinalTask(const std::string &task)
bool _check_input
true if we want to just check the input file
Definition: MooseApp.h:1299
Syntax _syntax
Syntax of the input file.
Definition: MooseApp.h:1166
Syntax & syntax()
Returns a writable reference to the syntax object.
Definition: MooseApp.h:218
bool _trap_fpe
Whether or not FPE trapping should be turned on.
Definition: MooseApp.h:1285
static const std::map< std::string, std::vector< std::shared_ptr< RegistryEntryBase > > > & allObjects()
Returns a per-label keyed map of all MooseObjects in the registry.
Definition: Registry.h:222
ActionWarehouse _action_warehouse
Where built actions are stored.
Definition: MooseApp.h:1176
This class produces a dump of the InputFileParameters in the Standard Object Notation (SON) format fo...
Holds the syntax in a Json::Value tree.
Base class for actions.
Definition: Action.h:33
int _exit_code
The exit code.
Definition: MooseApp.h:1258
CapabilityUtils::Result check(const std::string &requested_capabilities) const
check if the given required capabilities are fulfilled, returns a bool, a reason, and a verbose docum...
Definition: Capabilities.C:82
MPI_Status status
const std::string & getLastInputFileName() const
Definition: MooseApp.C:1662
void setErrorOverridden()
Set a flag so that the parser will throw an error if overridden parameters are detected.
Definition: MooseApp.C:2129
T command_line_value(const std::string &, T)
bool _deprecated_is_error
Variable to toggle only deprecated warnings as errors.
Definition: Moose.C:779
void mooseDeprecated(Args &&... args) const
Definition: MooseBase.h:310
void setActive(bool active)
Turn on or off timing.
Definition: PerfGraph.h:129
void initSyntaxFormatter(SyntaxFormatterType type, bool dump_mode)
Creates a syntax formatter for printing.
Definition: Builder.C:420
void disableLivePrint()
Completely disables Live Print (cannot be restarted)
Definition: PerfGraph.C:67
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:89
bool _recover
Whether or not this is a recovery run.
Definition: MooseApp.h:1270
void buildJsonSyntaxTree(JsonSyntaxTree &tree) const
Use MOOSE Factories to construct a parameter tree for documentation or echoing input.
Definition: Builder.C:437
std::string toString(const nlohmann::json &root)
returns a string representation of the tree in input file format
const std::shared_ptr< CommandLine > _command_line
The CommandLine object.
Definition: MooseApp.h:1185
void outputMachineReadableData(const std::string &param, const std::string &start_marker, const std::string &end_marker, const std::string &data) const
Outputs machine readable data (JSON, YAML, etc.) either to the screen (if no filename was provided as...
Definition: MooseApp.C:3568
This class produces produces a dump of the InputParameters that appears like the normal input file sy...
static Capabilities & getCapabilityRegistry()
Definition: Capabilities.C:22
bool _distributed_mesh_on_command_line
This variable indicates that DistributedMesh should be used for the libMesh mesh underlying MooseMesh...
Definition: MooseApp.h:1267
Moose::Builder _builder
Builder for building app related parser tree.
Definition: MooseApp.h:1191
std::string _output_file_base
The output file basename.
Definition: MooseApp.h:1145
std::streambuf * _output_buffer_cache
Cache output buffer so the language server can turn it off then back on.
Definition: MooseApp.h:1539
void build()
Builds all auto-buildable tasks.
bool setColorConsole(bool use_color, bool force=false)
Turns color escape sequences on/off for info written to stdout.
Definition: Moose.C:760
virtual std::string header() const
Returns a string to be printed at the beginning of a simulation.
Definition: MooseApp.C:2906
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:267
const std::vector< std::string > & getInputFileNames() const
Definition: MooseApp.C:1655
bool isParamValid(const std::string &name) const
Test if the supplied parameter is valid.
Definition: MooseBase.h:195
const ConsoleStream _console
An instance of helper class to write streams to the Console objects.
std::string toString(const nlohmann::json &root)
Returns a string representation of the tree in input file format.
std::string getPrintableVersion() const
Non-virtual method for printing out the version string in a consistent format.
Definition: MooseApp.C:1229
std::vector< const T * > getActions()
Retrieve all actions in a specific type ordered by their names.
void createMinimalApp()
Method for creating the minimum required actions for an application (no input file) ...
Definition: MooseApp.C:2924
bool _ready_to_exit
Definition: MooseApp.h:1256
bool isParamSetByUser(const std::string &name) const
Test if the supplied parameter is set by a user, as opposed to not set or set to default.
Definition: MooseBase.h:201
bool _split_mesh
Whether or not we are performing a split mesh operation (–split-mesh)
Definition: MooseApp.h:1276
Meta-action for creating common output object parameters This action serves two purpose, first it adds common output object parameters.
std::string _early_exit_param
Indicates if simulation is ready to exit, and keeps track of which param caused it to exit...
Definition: MooseApp.h:1255

◆ showInputs()

bool MooseApp::showInputs ( ) const
private

Prints a message showing the installable inputs for a given application (if getInstallableInputs has been overridden for an application).

Definition at line 2206 of file MooseApp.C.

Referenced by run().

2207 {
2208  if (getParam<bool>("show_inputs"))
2209  {
2210  const auto show_inputs_syntax = _pars.getCommandLineMetadata("show_inputs").switches;
2211  std::vector<std::string> dirs;
2212  const auto installable_inputs = getInstallableInputs();
2213 
2214  if (installable_inputs == "")
2215  {
2216  Moose::out
2217  << "Show inputs has not been overriden in this application.\nContact the developers of "
2218  "this appication and request that they override \"MooseApp::getInstallableInputs\".\n";
2219  }
2220  else
2221  {
2222  mooseAssert(!show_inputs_syntax.empty(), "show_inputs sytnax should not be empty");
2223 
2224  MooseUtils::tokenize(installable_inputs, dirs, 1, " ");
2225  Moose::out << "The following directories are installable into a user-writeable directory:\n\n"
2226  << installable_inputs << '\n'
2227  << "\nTo install one or more directories of inputs, execute the binary with the \""
2228  << show_inputs_syntax[0] << "\" flag. e.g.:\n$ "
2229  << _command_line->getExecutableName() << ' ' << show_inputs_syntax[0] << ' '
2230  << dirs[0] << '\n';
2231  }
2232  return true;
2233  }
2234  return false;
2235 }
virtual std::string getInstallableInputs() const
Method to retrieve the installable inputs from a given applications <app>Revision.h file.
Definition: MooseApp.C:2238
const InputParameters & _pars
The object&#39;s parameters.
Definition: MooseBase.h:362
void tokenize(const std::string &str, std::vector< T > &elements, unsigned int min_len=1, const std::string &delims="/")
This function will split the passed in string on a set of delimiters appending the substrings to the ...
const std::shared_ptr< CommandLine > _command_line
The CommandLine object.
Definition: MooseApp.h:1185
const InputParameters::CommandLineMetadata & getCommandLineMetadata(const std::string &name) const
std::vector< std::string > switches
The switches for the parameter (i.e., [-t, –timing])

◆ solutionInvalidity() [1/2]

SolutionInvalidity& MooseApp::solutionInvalidity ( )
inline

◆ solutionInvalidity() [2/2]

const SolutionInvalidity& MooseApp::solutionInvalidity ( ) const
inline

Definition at line 173 of file MooseApp.h.

173 { return _solution_invalidity; }
SolutionInvalidity & _solution_invalidity
The SolutionInvalidity object for this application.
Definition: MooseApp.h:1206

◆ syntax()

Syntax& MooseApp::syntax ( )
inline

◆ testCheckpointHalfTransient()

bool MooseApp::testCheckpointHalfTransient ( ) const
inline

Whether or not this simulation should only run half its transient (useful for testing recovery)

Definition at line 511 of file MooseApp.h.

Referenced by AutoCheckpointAction::act(), TimeStepper::constrainStep(), TransientBase::execute(), TimeSequenceStepperBase::setupSequence(), and TransientBase::TransientBase().

const bool _test_checkpoint_half_transient
Whether or not this simulation should only run half its transient (useful for testing recovery) ...
Definition: MooseApp.h:1291

◆ testReStep()

bool MooseApp::testReStep ( ) const
inline

Whether or not this simulation should fail a timestep and repeat (for testing).

Selection rules for which time step to fail in TransientBase.C constructor.

Definition at line 517 of file MooseApp.h.

Referenced by Control::Control(), Executioner::Executioner(), and TransientBase::TransientBase().

517 { return _test_restep; }
const bool _test_restep
Whether or not this simulation should fail its middle timestep and repeat (for testing) ...
Definition: MooseApp.h:1293

◆ theWarehouse()

TheWarehouse& MooseApp::theWarehouse ( )
inline

Definition at line 130 of file MooseApp.h.

Referenced by MooseVariableDataFV< OutputType >::MooseVariableDataFV(), and FEProblemBase::theWarehouse().

130 { return *_the_warehouse; }
std::unique_ptr< TheWarehouse > _the_warehouse
The combined warehouse for storing any MooseObject based object.
Definition: MooseApp.h:1504

◆ timedSectionName()

std::string PerfGraphInterface::timedSectionName ( const std::string &  section_name) const
protectedinherited
Returns
The name of the timed section with the name section_name.

Optionally adds a prefix if one is defined.

Definition at line 47 of file PerfGraphInterface.C.

Referenced by PerfGraphInterface::registerTimedSection().

48 {
49  return _prefix.empty() ? "" : (_prefix + "::") + section_name;
50 }
const std::string _prefix
A prefix to use for all sections.

◆ type()

const std::string& MooseBase::type ( ) const
inlineinherited

Get the type of this class.

Returns
the name of the type of this class

Definition at line 89 of file MooseBase.h.

Referenced by CreateProblemDefaultAction::act(), SetupDebugAction::act(), MaterialDerivativeTestAction::act(), MaterialOutputAction::act(), FEProblemBase::addAuxArrayVariable(), FEProblemBase::addAuxScalarVariable(), FEProblemBase::addAuxVariable(), FEProblemBase::addConvergence(), FEProblemBase::addDistribution(), addExecutor(), addExecutorParams(), MFEMProblem::addFunction(), FEProblemBase::addFunction(), FEProblemBase::addMeshDivision(), addMeshGenerator(), MeshGenerator::addMeshSubgenerator(), FEProblemBase::addObject(), MFEMProblem::addPostprocessor(), FEProblemBase::addPredictor(), CreateDisplacedProblemAction::addProxyRelationshipManagers(), FEProblemBase::addReporter(), FEProblemBase::addSampler(), FEProblemBase::addTimeIntegrator(), MooseServer::addValuesToList(), DisplacedProblem::addVectorTag(), SubProblem::addVectorTag(), FEProblemBase::advanceMultiApps(), appendMeshGenerator(), AuxKernelTempl< Real >::AuxKernelTempl(), FEProblemBase::backupMultiApps(), BatchMeshGeneratorAction::BatchMeshGeneratorAction(), BoundaryPreservedMarker::BoundaryPreservedMarker(), DistributedRectilinearMeshGenerator::buildCube(), MooseMesh::buildHRefinementAndCoarseningMaps(), MooseMesh::buildLowerDMesh(), MooseMesh::buildPRefinementAndCoarseningMaps(), PhysicsBase::checkComponentType(), MeshDiagnosticsGenerator::checkNonConformalMeshFromAdaptivity(), ActionComponent::checkRequiredTasks(), PhysicsBase::checkRequiredTasks(), ADDGKernel::computeElemNeighJacobian(), DGKernel::computeElemNeighJacobian(), ElemElemConstraint::computeElemNeighJacobian(), ArrayDGKernel::computeElemNeighJacobian(), ADDGKernel::computeElemNeighResidual(), DGKernel::computeElemNeighResidual(), ElemElemConstraint::computeElemNeighResidual(), ArrayDGKernel::computeElemNeighResidual(), LowerDIntegratedBC::computeLowerDJacobian(), ArrayLowerDIntegratedBC::computeLowerDJacobian(), DGLowerDKernel::computeLowerDJacobian(), ArrayDGLowerDKernel::computeLowerDJacobian(), LowerDIntegratedBC::computeLowerDOffDiagJacobian(), ArrayLowerDIntegratedBC::computeLowerDOffDiagJacobian(), ArrayHFEMDirichletBC::computeLowerDQpJacobian(), ArrayHFEMDiffusion::computeLowerDQpJacobian(), HFEMDirichletBC::computeLowerDQpJacobian(), HFEMDiffusion::computeLowerDQpJacobian(), ArrayHFEMDirichletBC::computeLowerDQpOffDiagJacobian(), HFEMDirichletBC::computeLowerDQpOffDiagJacobian(), ArrayLowerDIntegratedBC::computeLowerDQpOffDiagJacobian(), ArrayDGLowerDKernel::computeLowerDQpOffDiagJacobian(), FEProblemBase::computeMultiAppsDT(), ADDGKernel::computeOffDiagElemNeighJacobian(), DGKernel::computeOffDiagElemNeighJacobian(), ArrayDGKernel::computeOffDiagElemNeighJacobian(), DGLowerDKernel::computeOffDiagLowerDJacobian(), ArrayDGLowerDKernel::computeOffDiagLowerDJacobian(), DGConvection::computeQpJacobian(), ScalarKernel::computeQpJacobian(), InterfaceDiffusion::computeQpJacobian(), InterfaceReaction::computeQpJacobian(), ArrayDGDiffusion::computeQpJacobian(), CoupledTiedValueConstraint::computeQpJacobian(), TiedValueConstraint::computeQpJacobian(), DGDiffusion::computeQpJacobian(), LinearNodalConstraint::computeQpJacobian(), EqualValueBoundaryConstraint::computeQpJacobian(), CoupledTiedValueConstraint::computeQpOffDiagJacobian(), HFEMTestJump::computeQpOffDiagJacobian(), HFEMTrialJump::computeQpOffDiagJacobian(), ArrayDGKernel::computeQpOffDiagJacobian(), ArrayHFEMDiffusion::computeQpResidual(), DGConvection::computeQpResidual(), HFEMDiffusion::computeQpResidual(), ScalarKernel::computeQpResidual(), InterfaceDiffusion::computeQpResidual(), ADMatInterfaceReaction::computeQpResidual(), InterfaceReaction::computeQpResidual(), ADDGAdvection::computeQpResidual(), ArrayDGDiffusion::computeQpResidual(), CoupledTiedValueConstraint::computeQpResidual(), TiedValueConstraint::computeQpResidual(), DGDiffusion::computeQpResidual(), LinearNodalConstraint::computeQpResidual(), ADDGDiffusion::computeQpResidual(), HFEMTestJump::computeQpResidual(), HFEMTrialJump::computeQpResidual(), EqualValueBoundaryConstraint::computeQpResidual(), FEProblemBase::computeSystems(), FEProblemBase::computeUserObjectByName(), FEProblemBase::computeUserObjects(), FEProblemBase::computeUserObjectsInternal(), DisplacedProblem::createQRules(), FEProblemBase::createQRules(), createRecoverablePerfGraph(), DumpObjectsProblem::deduceNecessaryParameters(), DumpObjectsProblem::dumpObjectHelper(), FEProblemBase::duplicateVariableCheck(), FEProblemBase::execMultiApps(), FEProblemBase::execMultiAppTransfers(), FEProblemBase::execTransfers(), WebServerControl::execute(), SteadyBase::execute(), ActionWarehouse::executeActionsWithAction(), FEProblemBase::finishMultiAppStep(), FVScalarLagrangeMultiplierInterface::FVScalarLagrangeMultiplierInterface(), MooseServer::gatherDocumentReferencesLocations(), LowerDBlockFromSidesetGenerator::generate(), SubdomainPerElementGenerator::generate(), PatternedMeshGenerator::generate(), MeshGenerator::generateInternal(), MultiAppTransfer::getAppInfo(), TransfiniteMeshGenerator::getEdge(), ElementGenerator::getElemType(), MooseServer::getInputLookupDefinitionNodes(), FEProblemBase::getMaterial(), FEProblemBase::getMaterialData(), MaterialOutputAction::getParams(), ReporterData::getReporterInfo(), FEProblemBase::getTransfers(), DisplacedProblem::getVectorTags(), SubProblem::getVectorTags(), CommonOutputAction::hasConsole(), FEProblemBase::hasMultiApps(), AdvancedOutput::hasOutput(), FEProblemBase::incrementMultiAppTStep(), AdvancedOutput::initAvailableLists(), FunctorPositions::initialize(), FunctorTimes::initialize(), MultiAppConservativeTransfer::initialSetup(), LinearFVAnisotropicDiffusion::initialSetup(), LinearFVDiffusion::initialSetup(), LinearFVAdvection::initialSetup(), ArrayDGDiffusion::initQpResidual(), AdvancedOutput::initShowHideLists(), RelationshipManager::isType(), FEProblemBase::logAdd(), MaterialFunctorConverterTempl< T >::MaterialFunctorConverterTempl(), MFEMProblem::mesh(), MooseObject::MooseObject(), MultiAppMFEMCopyTransfer::MultiAppMFEMCopyTransfer(), DisplacedProblem::numVectorTags(), SubProblem::numVectorTags(), Console::output(), AdvancedOutput::output(), ConsoleUtils::outputExecutionInformation(), SampledOutput::outputStep(), Output::outputStep(), FEProblemBase::outputStep(), MooseServer::parseDocumentForDiagnostics(), MooseMesh::prepare(), ProjectedStatefulMaterialStorageAction::processProperty(), recursivelyCreateExecutors(), SolutionInvalidInterface::registerInvalidSolutionInternal(), FEProblemBase::restoreMultiApps(), MeshRepairGenerator::separateSubdomainsByElementType(), FEProblemBase::setCoupling(), setupOptions(), ExplicitTVDRK2::solve(), ExplicitRK2::solve(), WebServerControl::startServer(), Reporter::store(), MooseBase::typeAndName(), ScalarKernelBase::uOld(), AuxScalarKernel::uOld(), DisplacedProblem::updateGeomSearch(), FEProblemBase::updateGeomSearch(), UserObjectInterface::userObjectType(), and AdvancedOutput::wantOutput().

90  {
91  mooseAssert(_type.size(), "Empty type");
92  return _type;
93  }
const std::string & _type
The type of this class.
Definition: MooseBase.h:356

◆ typeAndName()

std::string MooseBase::typeAndName ( ) const
inherited

Get the class's combined type and name; useful in error handling.

Returns
The type and name of this class in the form '<type()> "<name()>"'.

Definition at line 54 of file MooseBase.C.

Referenced by FEProblemBase::addPostprocessor(), MaterialPropertyStorage::addProperty(), FEProblemBase::addReporter(), FEProblemBase::addVectorPostprocessor(), MeshGeneratorSystem::dataDrivenError(), ReporterContext< std::vector< T > >::finalize(), and ReporterData::getReporterInfo().

55 {
56  return type() + std::string(" \"") + name() + std::string("\"");
57 }
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:99
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:89

◆ uniqueName()

MooseObjectName MooseBase::uniqueName ( ) const
inherited
Returns
The unique name for accessing input parameters of this object in the InputParameterWarehouse

Definition at line 66 of file MooseBase.C.

Referenced by MooseBase::connectControllableParams(), and Action::uniqueActionName().

67 {
68  if (!_pars.have_parameter<std::string>(unique_name_param))
69  mooseError("uniqueName(): Object does not have a unique name");
70  return MooseObjectName(_pars.get<std::string>(unique_name_param));
71 }
const InputParameters & _pars
The object&#39;s parameters.
Definition: MooseBase.h:362
std::vector< std::pair< R1, R2 > > get(const std::string &param1, const std::string &param2) const
Combine two vector parameters into a single vector of pairs.
static const std::string unique_name_param
The name of the parameter that contains the unique object name.
Definition: MooseBase.h:57
bool have_parameter(std::string_view name) const
A wrapper around the Parameters base class method.
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:267
A class for storing the names of MooseObject by tag and object name.

◆ uniqueParameterName()

MooseObjectParameterName MooseBase::uniqueParameterName ( const std::string &  parameter_name) const
inherited
Returns
The unique parameter name of a valid parameter of this object for accessing parameter controls

Definition at line 60 of file MooseBase.C.

61 {
62  return MooseObjectParameterName(getBase(), name(), parameter_name);
63 }
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:99
A class for storing an input parameter name.
const std::string & getBase() const
Definition: MooseBase.h:143

◆ unusedFlagIsError()

bool MooseApp::unusedFlagIsError ( ) const
inline

Returns whether the flag for unused parameters is set to throw an error.

Definition at line 1067 of file MooseApp.h.

Referenced by MeshOnlyAction::act(), and PhysicsBase::reportPotentiallyMissedParameters().

1067 { return _enable_unused_check == ERROR_UNUSED; }
enum MooseApp::UNUSED_CHECK _enable_unused_check

◆ unusedFlagIsWarning()

bool MooseApp::unusedFlagIsWarning ( ) const
inline

Returns whether the flag for unused parameters is set to throw a warning only.

Definition at line 1064 of file MooseApp.h.

Referenced by MeshOnlyAction::act(), and PhysicsBase::reportPotentiallyMissedParameters().

1064 { return _enable_unused_check == WARN_UNUSED; }
enum MooseApp::UNUSED_CHECK _enable_unused_check

◆ useEigenvalue()

bool& MooseApp::useEigenvalue ( )
inline

Returns a writable Boolean indicating whether this app will use an eigenvalue executioner.

Definition at line 389 of file MooseApp.h.

Referenced by CreateProblemDefaultAction::act().

389 { return _use_eigen_value; }
bool _use_eigen_value
Boolean to indicate whether to use an eigenvalue executioner.
Definition: MooseApp.h:1240

◆ useExecutor()

bool MooseApp::useExecutor ( ) const
inline

Definition at line 330 of file MooseApp.h.

330 { return _use_executor; }
const bool _use_executor
Indicates whether we are operating in the new/experimental executor mode instead of using the legacy ...
Definition: MooseApp.h:1231

◆ useMasterMesh()

bool MooseApp::useMasterMesh ( ) const
inline

Returns whether to use the parent app mesh as the mesh for this app.

Definition at line 818 of file MooseApp.h.

Referenced by ExecuteMeshGenerators::act(), SetupMeshCompleteAction::act(), and SetupMeshAction::act().

818 { return _use_master_mesh; }
const bool _use_master_mesh
Whether to use the parent app mesh for this app.
Definition: MooseApp.h:1513

◆ useNonlinear()

bool& MooseApp::useNonlinear ( )
inline

Returns a writable Boolean indicating whether this app will use a Nonlinear or Eigen System.

Definition at line 384 of file MooseApp.h.

Referenced by CreateProblemAction::act(), and CreateProblemDefaultAction::act().

384 { return _use_nonlinear; }
bool _use_nonlinear
Boolean to indicate whether to use a Nonlinear or EigenSystem (inspected by actions) ...
Definition: MooseApp.h:1237

◆ validParams()

InputParameters MooseApp::validParams ( )
static

Definition at line 109 of file MooseApp.C.

110 {
112 
113  MooseApp::addAppParam(params);
114  MooseApp::addInputParam(params);
115 
116  params.addCommandLineParam<bool>("display_version", "-v --version", "Print application version");
117 
118  params.addOptionalValuedCommandLineParam<std::string>(
119  "mesh_only",
120  "--mesh-only <optional path>",
121  "",
122  "Build and output the mesh only (Default: \"<input_file_name>_in.e\")");
123 
124  params.addCommandLineParam<bool>(
125  "show_input", "--show-input", "Shows the parsed input file before running the simulation");
126  params.setGlobalCommandLineParam("show_input");
127  params.addCommandLineParam<bool>(
128  "show_outputs", "--show-outputs", "Shows the output execution time information");
129  params.setGlobalCommandLineParam("show_outputs");
130  params.addCommandLineParam<bool>(
131  "show_controls", "--show-controls", "Shows the Control logic available and executed");
132  params.setGlobalCommandLineParam("show_controls");
133 
134  params.addCommandLineParam<bool>(
135  "no_color", "--no-color", "Disable coloring of all Console outputs");
136  params.setGlobalCommandLineParam("no_color");
137 
138  MooseEnum colors("auto on off", "on");
140  "color", "--color <auto,on,off=on>", colors, "Whether to use color in console output");
141  params.setGlobalCommandLineParam("color");
142 
143  params.addCommandLineParam<bool>("help", "-h --help", "Displays CLI usage statement");
144  params.addCommandLineParam<bool>(
145  "minimal",
146  "--minimal",
147  "Ignore input file and build a minimal application with Transient executioner");
148 
149  params.addCommandLineParam<bool>(
150  "language_server",
151  "--language-server",
152  "Starts a process to communicate with development tools using the language server protocol");
153 
154  params.addCommandLineParam<bool>(
155  "definition", "--definition", "Shows a SON style input definition dump for input validation");
156  params.addCommandLineParam<bool>("dump", "--dump", "Shows a dump of available input file syntax");
157  params.addCommandLineParam<std::string>(
158  "dump_search",
159  "--dump-search <search>",
160  "Shows a dump of available input syntax matching a search");
161  params.addCommandLineParam<bool>("registry", "--registry", "Lists all known objects and actions");
162  params.addCommandLineParam<bool>(
163  "registry_hit", "--registry-hit", "Lists all known objects and actions in hit format");
164  params.addCommandLineParam<bool>(
165  "use_executor", "--executor", "Use the new Executor system instead of Executioners");
166 
167  params.addCommandLineParam<bool>(
168  "show_type", "--show-type", "Return the name of the application object");
169  params.addCommandLineParam<bool>("yaml", "--yaml", "Dumps all input file syntax in YAML format");
170  params.addCommandLineParam<std::string>(
171  "yaml_search", "--yaml-search", "Dumps input file syntax matching a search in YAML format");
172  params.addCommandLineParam<bool>("json", "--json", "Dumps all input file syntax in JSON format");
173  params.addCommandLineParam<std::string>(
174  "json_search", "--json-search", "Dumps input file syntax matching a search in JSON format");
175  params.addCommandLineParam<bool>(
176  "syntax", "--syntax", "Dumps the associated Action syntax paths ONLY");
177  params.addCommandLineParam<bool>(
178  "show_docs", "--docs", "Print url/path to the documentation website");
179  params.addCommandLineParam<bool>(
180  "show_capabilities", "--show-capabilities", "Dumps the capability registry in JSON format.");
181  params.addCommandLineParam<std::string>(
182  "required_capabilities",
183  "--required-capabilities",
184  "A list of conditions that is checked against the registered capabilities (see "
185  "--show-capabilities). The executable will terminate early if the conditions are not met.");
186  params.addCommandLineParam<std::string>(
187  "check_capabilities",
188  "--check-capabilities",
189  "A list of conditions that is checked against the registered capabilities. Will exit based "
190  "on whether or not the capaiblities are fulfilled. Does not check dynamically loaded apps.");
191  params.addCommandLineParam<bool>("check_input",
192  "--check-input",
193  "Check the input file (i.e. requires -i <filename>) and quit");
194  params.setGlobalCommandLineParam("check_input");
195  params.addCommandLineParam<bool>(
196  "show_inputs",
197  "--show-copyable-inputs",
198  "Shows the directories able to be copied into a user-writable location");
199 
200  params.addCommandLineParam<std::string>(
201  "copy_inputs",
202  "--copy-inputs <dir>",
203  "Copies installed inputs (e.g. tests, examples, etc.) to a directory <appname>_<dir>");
204  // TODO: Should this remain a bool? It can't be a regular argument because it contains
205  // values that have dashes in it, so it'll get treated as another arg
206  params.addOptionalValuedCommandLineParam<std::string>(
207  "run",
208  "--run <test harness args>",
209  "",
210  "Runs the inputs in the current directory copied to a "
211  "user-writable location by \"--copy-inputs\"");
212 
213  params.addCommandLineParam<bool>(
214  "list_constructed_objects",
215  "--list-constructed-objects",
216  "List all moose object type names constructed by the master app factory");
217 
218  params.addCommandLineParam<unsigned int>(
219  "n_threads", "--n-threads=<n>", "Runs the specified number of threads per process");
220  // This probably shouldn't be global, but the implications of removing this are currently
221  // unknown and we need to manage it with libmesh better
222  params.setGlobalCommandLineParam("n_threads");
223 
224  params.addCommandLineParam<bool>("allow_unused",
225  "-w --allow-unused",
226  "Warn about unused input file options instead of erroring");
227  params.setGlobalCommandLineParam("allow_unused");
228  params.addCommandLineParam<bool>(
229  "error_unused", "-e --error-unused", "Error when encountering unused input file options");
230  params.setGlobalCommandLineParam("error_unused");
231  params.addCommandLineParam<bool>(
232  "error_override",
233  "-o --error-override",
234  "Error when encountering overridden or parameters supplied multiple times");
235  params.setGlobalCommandLineParam("error_override");
236  params.addCommandLineParam<bool>(
237  "error_deprecated", "--error-deprecated", "Turn deprecated code messages into Errors");
238  params.setGlobalCommandLineParam("error_deprecated");
239 
240  params.addCommandLineParam<bool>("distributed_mesh",
241  "--distributed-mesh",
242  "Forces the use of a distributed finite element mesh");
243  // Would prefer that this parameter isn't global, but we rely on it too much
244  // in tests to be able to go back on that decision now
245  params.setGlobalCommandLineParam("distributed_mesh");
246 
247  params.addCommandLineParam<std::string>(
248  "split_mesh",
249  "--split-mesh <splits>",
250  "Comma-separated list of numbers of chunks to split the mesh into");
251 
252  // TODO: remove the logic now that this is global
253  params.addCommandLineParam<std::string>(
254  "split_file", "--split-file <filename>", "Name of split mesh file(s) to write/read");
255 
256  params.addCommandLineParam<bool>("use_split", "--use-split", "Use split distributed mesh files");
257 
258  params.addCommandLineParam<unsigned int>(
259  "refinements", "-r <num refinements>", "Specify additional initial uniform mesh refinements");
260 
261  params.addOptionalValuedCommandLineParam<std::string>(
262  "recover",
263  "--recover <optional file base>",
264  "",
265  "Continue the calculation. Without <file base>, the most recent recovery file will be used");
266  params.setGlobalCommandLineParam("recover");
267  params.addCommandLineParam<bool>(
268  "force_restart",
269  "--force-restart",
270  "Forcefully load checkpoints despite possible incompatibilities");
271  params.setGlobalCommandLineParam("force_restart");
272 
273  params.addCommandLineParam<bool>("suppress_header",
274  "--suppress-header",
275  false,
276  "Disables the output of the application header.");
277  params.setGlobalCommandLineParam("suppress_header");
278 
279  params.addCommandLineParam<bool>(
280  "test_checkpoint_half_transient",
281  "--test-checkpoint-half-transient",
282  "Run half of a transient with checkpoints enabled; used by the TestHarness");
283  params.setGlobalCommandLineParam("test_checkpoint_half_transient");
284 
285  params.addCommandLineParam<bool>("test_restep",
286  "--test-restep",
287  "Test re-running the middle timestep; used by the TestHarness");
288 
289  params.addCommandLineParam<bool>(
290  "trap_fpe",
291  "--trap-fpe",
292  "Enable floating point exception handling in critical sections of code"
293 #ifdef DEBUG
294  " (automatic due to debug build)"
295 #endif
296  );
297  params.setGlobalCommandLineParam("trap_fpe");
298 
299  params.addCommandLineParam<bool>(
300  "no_trap_fpe",
301  "--no-trap-fpe",
302  "Disable floating point exception handling in critical sections of code"
303 #ifndef DEBUG
304  " (unused due to non-debug build)"
305 #endif
306  );
307 
308  params.setGlobalCommandLineParam("no_trap_fpe");
309 
310  params.addCommandLineParam<bool>(
311  "no_gdb_backtrace", "--no-gdb-backtrace", "Disables gdb backtraces.");
312  params.setGlobalCommandLineParam("no_gdb_backtrace");
313 
314  params.addCommandLineParam<bool>("error", "--error", "Turn all warnings into errors");
315  params.setGlobalCommandLineParam("error");
316 
317  params.addCommandLineParam<bool>("timing",
318  "-t --timing",
319  "Enable all performance logging for timing; disables screen "
320  "output of performance logs for all Console objects");
321  params.setGlobalCommandLineParam("timing");
322  params.addCommandLineParam<bool>(
323  "no_timing", "--no-timing", "Disabled performance logging; overrides -t or --timing");
324  params.setGlobalCommandLineParam("no_timing");
325 
326  params.addCommandLineParam<bool>(
327  "allow_test_objects", "--allow-test-objects", "Register test objects and syntax");
328  params.setGlobalCommandLineParam("allow_test_objects");
329 
330  // Options ignored by MOOSE but picked up by libMesh, these are here so that they are displayed in
331  // the application help
332  params.addCommandLineParam<bool>(
333  "keep_cout",
334  "--keep-cout",
335  "Keep standard output from all processors when running in parallel");
336  params.setGlobalCommandLineParam("keep_cout");
337  params.addCommandLineParam<bool>(
338  "redirect_stdout",
339  "--redirect-stdout",
340  "Keep standard output from all processors when running in parallel");
341  params.setGlobalCommandLineParam("redirect_stdout");
342 
343  params.addCommandLineParam<std::string>(
344  "timpi_sync",
345  "--timpi-sync <type=nbx>",
346  "nbx",
347  "Changes the sync type used in spare parallel communitations within TIMPI");
348  params.setGlobalCommandLineParam("timpi_sync");
349 
350  // Options for debugging
351  params.addCommandLineParam<std::string>("start_in_debugger",
352  "--start-in-debugger <debugger>",
353  "Start the application and attach a debugger; this will "
354  "launch xterm windows using <debugger>");
355 
356  params.addCommandLineParam<unsigned int>(
357  "stop_for_debugger",
358  "--stop-for-debugger <seconds>",
359  "Pauses the application during startup for <seconds> to allow for connection of debuggers");
360 
361  params.addCommandLineParam<bool>(
362  "perf_graph_live_all", "--perf-graph-live-all", "Forces printing of ALL progress messages");
363  params.setGlobalCommandLineParam("perf_graph_live_all");
364 
365  params.addCommandLineParam<bool>(
366  "disable_perf_graph_live", "--disable-perf-graph-live", "Disables PerfGraph live printing");
367  params.setGlobalCommandLineParam("disable_perf_graph_live");
368 
369  params.addParam<bool>(
370  "automatic_automatic_scaling", false, "Whether to turn on automatic scaling by default");
371 
372  const MooseEnum compute_device_type("cpu cuda mps hip ceed-cpu ceed-cuda ceed-hip", "cpu");
374  "compute_device",
375  "--compute-device",
376  compute_device_type,
377  "The device type we want to run accelerated (libtorch, MFEM) computations on.");
378 
379 #ifdef HAVE_GPERFTOOLS
380  params.addCommandLineParam<std::string>(
381  "gperf_profiler_on",
382  "--gperf-profiler-on <ranks>",
383  "To generate profiling report only on comma-separated list of MPI ranks");
384 #endif
385 
386  params.addCommandLineParam<bool>(
387  "show_data_params",
388  "--show-data-params",
389  false,
390  "Show found paths for all DataFileName parameters in the header");
391  params.addCommandLineParam<bool>("show_data_paths",
392  "--show-data-paths",
393  false,
394  "Show registered data paths for searching in the header");
395 
396  params.addPrivateParam<std::shared_ptr<CommandLine>>("_command_line");
397  params.addPrivateParam<std::shared_ptr<Parallel::Communicator>>("_comm");
398  params.addPrivateParam<unsigned int>("_multiapp_level");
399  params.addPrivateParam<unsigned int>("_multiapp_number");
400  params.addPrivateParam<bool>("_use_master_mesh", false);
401  params.addPrivateParam<const MooseMesh *>("_master_mesh");
402  params.addPrivateParam<const MooseMesh *>("_master_displaced_mesh");
403  params.addPrivateParam<std::unique_ptr<Backup> *>("_initial_backup", nullptr);
404  params.addPrivateParam<std::shared_ptr<Parser>>("_parser");
405 #ifdef MOOSE_MFEM_ENABLED
406  params.addPrivateParam<std::shared_ptr<mfem::Device>>("_mfem_device");
407  params.addPrivateParam<std::set<std::string>>("_mfem_devices");
408 #endif
409 
410  params.addParam<bool>(
411  "use_legacy_material_output",
412  true,
413  "Set false to allow material properties to be output on INITIAL, not just TIMESTEP_END.");
414  params.addParam<bool>(
415  "use_legacy_initial_residual_evaluation_behavior",
416  true,
417  "The legacy behavior performs an often times redundant residual evaluation before the "
418  "solution modifying objects are executed prior to the initial (0th nonlinear iteration) "
419  "residual evaluation. The new behavior skips that redundant residual evaluation unless the "
420  "parameter Executioner/use_pre_SMO_residual is set to true.");
421 
422  params.addParam<bool>(
424  false,
425  "Set true to enable data-driven mesh generation, which is an experimental feature");
426 
427  params.addCommandLineParam<bool>(
428  "parse_neml2_only",
429  "--parse-neml2-only",
430  "Executes the [NEML2] block to parse the input file and terminate.");
431 
432  MooseApp::addAppParam(params);
433 
434  params.registerBase("Application");
435 
436  return params;
437 }
void setGlobalCommandLineParam(const std::string &name)
Sets the command line parameter with name as global.
void addPrivateParam(const std::string &name, const T &value)
These method add a parameter to the InputParameters object which can be retrieved like any other para...
static void addInputParam(InputParameters &params)
Definition: MooseApp.C:102
The main MOOSE class responsible for handling user-defined parameters in almost every MOOSE system...
void registerBase(const std::string &value)
This method must be called from every base "Moose System" to create linkage with the Action System...
MooseMesh wraps a libMesh::Mesh object and enhances its capabilities by caching additional data and s...
Definition: MooseMesh.h:88
This is a "smart" enum class intended to replace many of the shortcomings in the C++ enum type It sho...
Definition: MooseEnum.h:33
void addCommandLineParam(const std::string &name, const std::string &syntax, const std::string &doc_string)
static void addAppParam(InputParameters &params)
Definition: MooseApp.C:95
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...
static const std::string allow_data_driven_param
The name of the boolean parameter on the MooseApp that will enable data driven generation.
void addOptionalValuedCommandLineParam(const std::string &name, const std::string &syntax, const T &value, const std::string &doc_string)
Add a command line parameter with an optional value.
static InputParameters validParams()
Definition: MooseBase.C:25

◆ writeRestartableMetaData() [1/2]

std::vector< std::filesystem::path > MooseApp::writeRestartableMetaData ( const RestartableDataMapName name,
const std::filesystem::path &  folder_base 
)

Writes the restartable meta data for name with a folder base of folder_base.

Returns
The files that were written

Definition at line 2585 of file MooseApp.C.

Referenced by MeshOnlyAction::act(), SplitMeshAction::act(), Checkpoint::output(), and writeRestartableMetaData().

2587 {
2588  if (processor_id() != 0)
2589  mooseError("MooseApp::writeRestartableMetaData(): Should only run on processor 0");
2590 
2591  const auto & map_name = getRestartableDataMapName(name);
2592  const auto meta_data_folder_base = metaDataFolderBase(folder_base, map_name);
2593 
2595  return writer.write(meta_data_folder_base);
2596 }
static std::filesystem::path metaDataFolderBase(const std::filesystem::path &folder_base, const std::string &map_suffix)
The file suffix for meta data (header and data)
Definition: MooseApp.C:3079
Writer for restartable data, to be read by the RestartableDataReader.
processor_id_type processor_id() const
Returns the MPI processor ID of the current processor.
Definition: MooseApp.h:404
RestartableDataMap & getRestartableDataMap(const RestartableDataMapName &name)
Return a reference to restartable data for the specific type flag.
Definition: MooseApp.C:3460
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:99
const std::string & getRestartableDataMapName(const RestartableDataMapName &name) const
Definition: MooseApp.C:3487
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:267

◆ writeRestartableMetaData() [2/2]

std::vector< std::filesystem::path > MooseApp::writeRestartableMetaData ( const std::filesystem::path &  folder_base)

Writes all available restartable meta data with a file base of file_base.

Returns
The files that were written

Definition at line 2599 of file MooseApp.C.

2600 {
2601  std::vector<std::filesystem::path> paths;
2602 
2603  if (processor_id() == 0)
2604  for (const auto & name_map_pair : _restartable_meta_data)
2605  {
2606  const auto map_paths = writeRestartableMetaData(name_map_pair.first, folder_base);
2607  paths.insert(paths.end(), map_paths.begin(), map_paths.end());
2608  }
2609 
2610  return paths;
2611 }
std::unordered_map< RestartableDataMapName, std::pair< RestartableDataMap, std::string > > _restartable_meta_data
General storage for custom RestartableData that can be added to from outside applications.
Definition: MooseApp.h:1494
std::vector< std::filesystem::path > writeRestartableMetaData(const RestartableDataMapName &name, const std::filesystem::path &folder_base)
Writes the restartable meta data for name with a folder base of folder_base.
Definition: MooseApp.C:2585
processor_id_type processor_id() const
Returns the MPI processor ID of the current processor.
Definition: MooseApp.h:404

Friends And Related Function Documentation

◆ FEProblemBase

friend class FEProblemBase
friend

Definition at line 1579 of file MooseApp.h.

◆ Restartable

friend class Restartable
friend

Definition at line 1580 of file MooseApp.h.

◆ SubProblem

friend class SubProblem
friend

Definition at line 1581 of file MooseApp.h.

Member Data Documentation

◆ _action_factory

ActionFactory MooseApp::_action_factory
protected

The Factory responsible for building Actions.

Definition at line 1173 of file MooseApp.h.

Referenced by createMinimalApp(), and getActionFactory().

◆ _action_warehouse

ActionWarehouse MooseApp::_action_warehouse
protected

◆ _app

MooseApp& MooseBase::_app
protectedinherited

The MOOSE application this is associated with.

Definition at line 353 of file MooseBase.h.

Referenced by AB2PredictorCorrector::AB2PredictorCorrector(), FEProblemBase::acceptInvalidSolution(), ElementIDOutputAction::act(), CopyNodalVarsAction::act(), CreateExecutionerAction::act(), DeclareLateReportersAction::act(), AddExecutorAction::act(), AutoCheckpointAction::act(), ExecuteMeshGenerators::act(), AddMeshGeneratorAction::act(), ReadExecutorParamsAction::act(), CheckIntegrityAction::act(), SetupMeshCompleteAction::act(), CreateProblemAction::act(), CreateProblemDefaultAction::act(), AdaptivityAction::act(), MeshOnlyAction::act(), SetupMeshAction::act(), CombineComponentsMeshes::act(), SplitMeshAction::act(), AddTimeStepperAction::act(), SetupDebugAction::act(), SetupPredictorAction::act(), SetupTimeStepperAction::act(), ComposeTimeStepperAction::act(), SetupRecoverFileBaseAction::act(), CouplingFunctorCheckAction::act(), AddRelationshipManager::act(), SetAdaptivityOptionsAction::act(), CreateAddedMeshGenerators::act(), DisplayGhostingAction::act(), MaterialOutputAction::act(), ResolveOptionalMaterialPropertiesAction::act(), AddPeriodicBCAction::act(), CommonOutputAction::act(), Action::Action(), FEProblemBase::addAnyRedistributers(), MeshGenerator::addChildMeshGenerator(), FEProblemBase::addMaterialHelper(), ComponentMeshTransformHelper::addMeshGenerators(), CylinderComponent::addMeshGenerators(), BatchMeshGeneratorAction::addMeshGenerators(), MeshGenerator::addMeshSubgenerator(), FEProblemBase::addOutput(), MeshGenerator::addParentMeshGenerator(), CreateDisplacedProblemAction::addProxyRelationshipManagers(), Action::addRelationshipManager(), FEProblemBase::allowOutput(), AStableDirk4::AStableDirk4(), BatchMeshGeneratorAction::BatchMeshGeneratorAction(), FileMesh::buildMesh(), MooseMesh::buildTypedMesh(), MooseMesh::cacheFaceInfoVariableOwnership(), MooseMesh::cacheFVElementalDoFs(), MooseBase::callMooseError(), CheckOutputAction::checkConsoleOutput(), DefaultNonlinearConvergence::checkConvergence(), MeshGenerator::checkGetMesh(), FEProblemBase::checkICRestartError(), CheckOutputAction::checkMaterialOutput(), CheckOutputAction::checkPerfLogOutput(), FEProblemBase::checkProblemIntegrity(), CheckOutputAction::checkVariableOutput(), SingleRankPartitioner::clone(), CopyMeshPartitioner::clone(), RandomPartitioner::clone(), BlockWeightedPartitioner::clone(), GhostEverything::clone(), GhostHigherDLowerDPointNeighbors::clone(), GhostLowerDElems::clone(), LibmeshPartitioner::clone(), PetscExternalPartitioner::clone(), HierarchicalGridPartitioner::clone(), GridPartitioner::clone(), ElementSideNeighborLayers::clone(), ElementPointNeighborLayers::clone(), GhostBoundary::clone(), RedistributeProperties::clone(), ProxyRelationshipManager::clone(), SampledOutput::cloneMesh(), FEProblemBase::computeJacobianTags(), FEProblemBase::computeLinearSystemTags(), FEProblemBase::computeResidualAndJacobian(), FEProblemBase::computeResidualTags(), MooseBase::connectControllableParams(), Console::Console(), TimeStepper::constrainStep(), Control::Control(), CopyMeshPartitioner::CopyMeshPartitioner(), MultiApp::createApp(), MultiApp::createApps(), FEProblemBase::customSetup(), MeshGenerator::declareMeshProperty(), MeshGenerator::declareNullMeshName(), MooseMesh::determineUseDistributedMesh(), DumpObjectsProblem::dumpObjectHelper(), DumpObjectsProblem::DumpObjectsProblem(), DumpObjectsProblem::dumpVariableHelper(), DynamicObjectRegistrationAction::DynamicObjectRegistrationAction(), EigenExecutionerBase::EigenExecutionerBase(), EigenKernel::EigenKernel(), InversePowerMethod::execute(), NonlinearEigen::execute(), PseudoTimestep::execute(), IterationInfo::execute(), MFEMSteady::execute(), PIDTransientControl::execute(), SteadyBase::execute(), TransientBase::execute(), Eigenvalue::execute(), EigenProblem::execute(), Executioner::Executioner(), ExtraIDIntegralReporter::ExtraIDIntegralReporter(), FEProblemBase::FEProblemBase(), FileOutput::FileOutput(), ChangeOverFixedPointPostprocessor::finalize(), RadialAverage::finalize(), FixedPointSolve::FixedPointSolve(), FEProblemBase::forceOutput(), FullSolveMultiApp::FullSolveMultiApp(), FunctorSmootherTempl< T >::FunctorSmootherTempl(), FVAdvection::FVAdvection(), ExtraNodesetGenerator::generate(), FileMeshGenerator::generate(), SideSetsFromNormalsGenerator::generate(), MeshGenerator::generateInternal(), FEProblemBase::getExecutor(), MeshGenerator::getMeshByName(), MooseBase::getMooseApp(), NumRelationshipManagers::getValue(), NumFixedPointIterations::getValue(), GhostingUserObject::GhostingUserObject(), InversePowerMethod::init(), NonlinearEigen::init(), TransientBase::init(), Eigenvalue::init(), MooseMesh::init(), FEProblemBase::init(), TimePeriod::initialSetup(), Console::initialSetup(), FEProblemBase::initialSetup(), AdvancedOutput::initOutputList(), EigenProblem::initPetscOutputAndSomeSolverSettings(), FEProblemBase::initPetscOutputAndSomeSolverSettings(), AdvancedOutput::initPostprocessorOrVectorPostprocessorLists(), MeshGenerator::MeshGenerator(), MFEMProblemSolve::MFEMProblemSolve(), MooseObject::MooseObject(), MultiAppGeneralFieldTransfer::MultiAppGeneralFieldTransfer(), NEML2Action::NEML2Action(), EigenExecutionerBase::normalizeSolution(), NumFailedTimeSteps::NumFailedTimeSteps(), PerfGraphOutput::output(), Tecplot::output(), Exodus::output(), Checkpoint::output(), ControlOutput::outputActiveObjects(), ControlOutput::outputChangedControls(), ControlOutput::outputControls(), Exodus::outputEmptyTimestep(), Console::outputInput(), Exodus::outputInput(), Exodus::outputNodalVariables(), JSONOutput::outputReporters(), SampledOutput::outputStep(), Output::outputStep(), FEProblemBase::outputStep(), JSONOutput::outputSystemInformation(), Console::outputSystemInformation(), OverlayMeshGenerator::OverlayMeshGenerator(), MultiApp::parentOutputPositionChanged(), TransientBase::preExecute(), PhysicsBase::prepareCopyVariablesFromMesh(), Eigenvalue::prepareSolverOptions(), NEML2Action::printSummary(), FEProblemBase::projectSolution(), PhysicsBase::reportPotentiallyMissedParameters(), TiledMesh::safeClone(), FileMesh::safeClone(), ImageMesh::safeClone(), SpiralAnnularMesh::safeClone(), GeneratedMesh::safeClone(), ConcentricCircleMesh::safeClone(), RinglebMesh::safeClone(), AnnularMesh::safeClone(), MeshGeneratorMesh::safeClone(), StitchedMesh::safeClone(), PatternedMesh::safeClone(), MFEMMesh::safeClone(), MultiApp::setAppOutputFileBase(), FileOutput::setFileBaseInternal(), MeshGenerator::setMeshProperty(), MeshGenerator::setMeshPropertyHelper(), FEProblemBase::setRestartFile(), TransientMultiApp::setupApp(), MeshGeneratorComponent::setupComponent(), SetupMeshAction::setupMesh(), TimeSequenceStepperBase::setupSequence(), TransientBase::setupTimeIntegrator(), Output::setWallTimeIntervalFromCommandLineParam(), PhysicsBase::shouldCreateIC(), SideSetExtruderGenerator::SideSetExtruderGenerator(), SolutionInvalidityReporter::SolutionInvalidityReporter(), EigenProblem::solve(), FixedPointSolve::solve(), FEProblemBase::solve(), FEProblemBase::solveLinearSystem(), PetscOutput::solveSetup(), TransientMultiApp::solveStep(), FEProblemBase::subdomainSetup(), FEProblemBase::theWarehouse(), TimeExtremeValue::TimeExtremeValue(), TimeIntervalTimes::TimeIntervalTimes(), TimePeriod::TimePeriod(), FEProblemBase::timestepSetup(), TransientBase::TransientBase(), FEProblemBase::updateMortarMesh(), Console::write(), and FEProblemBase::~FEProblemBase().

◆ _attached_relationship_managers

std::map<Moose::RelationshipManagerType, std::set<const RelationshipManager *> > MooseApp::_attached_relationship_managers
protected

The relationship managers that have been attached (type -> RMs)

Definition at line 1306 of file MooseApp.h.

Referenced by attachRelationshipManagers().

◆ _automatic_automatic_scaling

const bool MooseApp::_automatic_automatic_scaling
private

Whether to turn on automatic scaling by default.

Definition at line 1542 of file MooseApp.h.

Referenced by defaultAutomaticScaling().

◆ _builder

Moose::Builder MooseApp::_builder
protected

Builder for building app related parser tree.

Definition at line 1191 of file MooseApp.h.

Referenced by builder(), errorCheck(), getFileName(), and setupOptions().

◆ _chain_control_system

ChainControlDataSystem MooseApp::_chain_control_system
private

The system that manages the ChainControls.

Definition at line 1525 of file MooseApp.h.

Referenced by getChainControlDataSystem().

◆ _check_input

bool MooseApp::_check_input
protected

true if we want to just check the input file

Definition at line 1299 of file MooseApp.h.

Referenced by checkInput(), errorCheck(), run(), and setupOptions().

◆ _comm

const std::shared_ptr<libMesh::Parallel::Communicator> MooseApp::_comm
protected

The MPI communicator this App is going to use.

Definition at line 1142 of file MooseApp.h.

Referenced by errorCheck(), getCommunicator(), and processor_id().

◆ _command_line

const std::shared_ptr<CommandLine> MooseApp::_command_line
protected

The CommandLine object.

Definition at line 1185 of file MooseApp.h.

Referenced by commandLine(), copyInputs(), executeExecutioner(), setupOptions(), and showInputs().

◆ _console

const ConsoleStream ConsoleStreamInterface::_console
inherited

An instance of helper class to write streams to the Console objects.

Definition at line 31 of file ConsoleStreamInterface.h.

Referenced by IterationAdaptiveDT::acceptStep(), MeshOnlyAction::act(), SetupDebugAction::act(), MaterialOutputAction::act(), Adaptivity::adaptMesh(), FEProblemBase::adaptMesh(), PerfGraph::addToExecutionList(), SimplePredictor::apply(), SystemBase::applyScalingFactors(), MultiApp::backup(), FEProblemBase::backupMultiApps(), CoarsenedPiecewiseLinear::buildCoarsenedGrid(), DefaultSteadyStateConvergence::checkConvergence(), MeshDiagnosticsGenerator::checkElementOverlap(), MeshDiagnosticsGenerator::checkElementTypes(), MeshDiagnosticsGenerator::checkElementVolumes(), FEProblemBase::checkExceptionAndStopSolve(), SolverSystem::checkInvalidSolution(), MeshDiagnosticsGenerator::checkLocalJacobians(), MeshDiagnosticsGenerator::checkNonConformalMesh(), MeshDiagnosticsGenerator::checkNonConformalMeshFromAdaptivity(), MeshDiagnosticsGenerator::checkNonMatchingEdges(), MeshDiagnosticsGenerator::checkNonPlanarSides(), FEProblemBase::checkProblemIntegrity(), ReferenceResidualConvergence::checkRelativeConvergence(), MeshDiagnosticsGenerator::checkSidesetsOrientation(), MeshDiagnosticsGenerator::checkWatertightNodesets(), MeshDiagnosticsGenerator::checkWatertightSidesets(), IterationAdaptiveDT::computeAdaptiveDT(), TransientBase::computeConstrainedDT(), DefaultMultiAppFixedPointConvergence::computeCustomConvergencePostprocessor(), NonlinearSystemBase::computeDamping(), FixedPointIterationAdaptiveDT::computeDT(), IterationAdaptiveDT::computeDT(), IterationAdaptiveDT::computeFailedDT(), IterationAdaptiveDT::computeInitialDT(), IterationAdaptiveDT::computeInterpolationDT(), LinearSystem::computeLinearSystemTags(), FEProblemBase::computeLinearSystemTags(), NonlinearSystemBase::computeScaling(), Problem::console(), IterationAdaptiveDT::constrainStep(), TimeStepper::constrainStep(), MultiApp::createApp(), FEProblemBase::execMultiApps(), FEProblemBase::execMultiAppTransfers(), MFEMSteady::execute(), MessageFromInput::execute(), SteadyBase::execute(), Eigenvalue::execute(), ActionWarehouse::executeActionsWithAction(), ActionWarehouse::executeAllActions(), MeshGeneratorSystem::executeMeshGenerators(), ElementQualityChecker::finalize(), SidesetAroundSubdomainUpdater::finalize(), FEProblemBase::finishMultiAppStep(), MeshRepairGenerator::fixOverlappingNodes(), CoarsenBlockGenerator::generate(), MeshGenerator::generateInternal(), VariableCondensationPreconditioner::getDofToCondense(), InversePowerMethod::init(), NonlinearEigen::init(), FEProblemBase::initialAdaptMesh(), DefaultMultiAppFixedPointConvergence::initialize(), EigenExecutionerBase::inversePowerIteration(), FEProblemBase::joinAndFinalize(), TransientBase::keepGoing(), IterationAdaptiveDT::limitDTByFunction(), IterationAdaptiveDT::limitDTToPostprocessorValue(), FEProblemBase::logAdd(), EigenExecutionerBase::makeBXConsistent(), Console::meshChanged(), MooseBase::mooseDeprecated(), MooseBase::mooseInfo(), MooseBase::mooseWarning(), MooseBase::mooseWarningNonPrefixed(), ReferenceResidualConvergence::nonlinearConvergenceSetup(), ReporterDebugOutput::output(), PerfGraphOutput::output(), SolutionInvalidityOutput::output(), MaterialPropertyDebugOutput::output(), DOFMapOutput::output(), VariableResidualNormsDebugOutput::output(), Console::output(), ControlOutput::outputActiveObjects(), ControlOutput::outputChangedControls(), ControlOutput::outputControls(), Console::outputInput(), Console::outputPostprocessors(), PseudoTimestep::outputPseudoTimestep(), Console::outputReporters(), DefaultMultiAppFixedPointConvergence::outputResidualNorm(), Console::outputScalarVariables(), Console::outputSystemInformation(), FEProblemBase::possiblyRebuildGeomSearchPatches(), EigenExecutionerBase::postExecute(), AB2PredictorCorrector::postSolve(), ActionWarehouse::printActionDependencySets(), BlockRestrictionDebugOutput::printBlockRestrictionMap(), SolutionInvalidity::printDebug(), EigenExecutionerBase::printEigenvalue(), SecantSolve::printFixedPointConvergenceHistory(), SteffensenSolve::printFixedPointConvergenceHistory(), PicardSolve::printFixedPointConvergenceHistory(), FixedPointSolve::printFixedPointConvergenceReason(), PerfGraphLivePrint::printLiveMessage(), MaterialPropertyDebugOutput::printMaterialMap(), PerfGraphLivePrint::printStats(), NEML2Action::printSummary(), AutomaticMortarGeneration::projectPrimaryNodesSinglePair(), AutomaticMortarGeneration::projectSecondaryNodesSinglePair(), CoarsenBlockGenerator::recursiveCoarsen(), SolutionTimeAdaptiveDT::rejectStep(), MultiApp::restore(), FEProblemBase::restoreMultiApps(), FEProblemBase::restoreSolutions(), NonlinearSystemBase::setInitialSolution(), setupOptions(), Checkpoint::shouldOutput(), SubProblem::showFunctorRequestors(), SubProblem::showFunctors(), FullSolveMultiApp::showStatusMessage(), EigenProblem::solve(), FEProblemSolve::solve(), NonlinearSystem::solve(), FixedPointSolve::solve(), LinearSystem::solve(), LStableDirk2::solve(), LStableDirk3::solve(), ImplicitMidpoint::solve(), ExplicitTVDRK2::solve(), LStableDirk4::solve(), AStableDirk4::solve(), ExplicitRK2::solve(), TransientMultiApp::solveStep(), FixedPointSolve::solveStep(), PerfGraphLivePrint::start(), AB2PredictorCorrector::step(), NonlinearEigen::takeStep(), MFEMTransient::takeStep(), TransientBase::takeStep(), TerminateChainControl::terminate(), Convergence::verboseOutput(), Console::writeTimestepInformation(), Console::writeVariableNorms(), and FEProblemBase::~FEProblemBase().

◆ _cpu_profiling

bool MooseApp::_cpu_profiling = false
private

CPU profiling.

Definition at line 1545 of file MooseApp.h.

Referenced by ~MooseApp().

◆ _distributed_mesh_on_command_line

bool MooseApp::_distributed_mesh_on_command_line
protected

This variable indicates that DistributedMesh should be used for the libMesh mesh underlying MooseMesh.

Definition at line 1267 of file MooseApp.h.

Referenced by getDistributedMeshOnCommandLine(), and setupOptions().

◆ _early_exit_param

std::string MooseApp::_early_exit_param
protected

Indicates if simulation is ready to exit, and keeps track of which param caused it to exit.

Definition at line 1255 of file MooseApp.h.

Referenced by errorCheck(), run(), runInputFile(), and setupOptions().

◆ _enable_unused_check

enum MooseApp::UNUSED_CHECK MooseApp::_enable_unused_check
protected

◆ _error_overridden

bool MooseApp::_error_overridden
protected

Indicates whether warnings or errors are displayed when overridden parameters are detected.

Definition at line 1253 of file MooseApp.h.

Referenced by setErrorOverridden().

◆ _ex_reader

std::shared_ptr<libMesh::ExodusII_IO> MooseApp::_ex_reader
protected

The Exodus reader when _initial_from_file is set to true.

Definition at line 1264 of file MooseApp.h.

Referenced by getExReaderForRestart(), and setExReaderForRestart().

◆ _execute_flags

const ExecFlagEnum MooseApp::_execute_flags
private

Execution flags for this App.

Note: These are copied on purpose instead of maintaining a reference to the ExecFlagRegistry registry. In the Multiapp case, the registry may be augmented, changing the flags "known" to the application in the middle of executing the setup. This causes issues with the application having to process flags that aren't specifically registered.

Definition at line 1536 of file MooseApp.h.

Referenced by getExecuteOnEnum().

◆ _executioner

std::shared_ptr<Executioner> MooseApp::_executioner
protected

Pointer to the executioner of this run (typically build by actions)

Definition at line 1212 of file MooseApp.h.

Referenced by attachRelationshipManagers(), errorCheck(), executeExecutioner(), feProblem(), getExecutioner(), removeRelationshipManager(), setExecutioner(), setOutputPosition(), and ~MooseApp().

◆ _executor

std::shared_ptr<Executor> MooseApp::_executor
protected

◆ _executor_params

std::unordered_map<std::string, std::pair<std::string, std::unique_ptr<InputParameters> > > MooseApp::_executor_params
protected

Used in building the Executors Maps the name of the Executor block to the <type, params>

Definition at line 1223 of file MooseApp.h.

Referenced by addExecutorParams(), createExecutors(), and recursivelyCreateExecutors().

◆ _executors

std::map<std::string, std::shared_ptr<Executor> > MooseApp::_executors
protected

Pointers to all of the Executors for this run.

Definition at line 1218 of file MooseApp.h.

Referenced by addExecutor(), createExecutors(), getExecutor(), and recursivelyCreateExecutors().

◆ _exit_code

int MooseApp::_exit_code
protected

The exit code.

Definition at line 1258 of file MooseApp.h.

Referenced by exitCode(), setExitCode(), and setupOptions().

◆ _factory

Factory MooseApp::_factory
protected

◆ _file_base_set_by_user

bool MooseApp::_file_base_set_by_user
protected

Whether or not file base is set through input or setOutputFileBase by MultiApp.

Definition at line 1148 of file MooseApp.h.

Referenced by getCheckpointDirectories(), getOutputFileBase(), setOutputFileBase(), and setupOptions().

◆ _fixed_point_config

FixedPointConfig MooseApp::_fixed_point_config
protected

Multiapp-related fixed point algorithm configuration details primarily intended to be passed to and used by the executioner/executor system.

Definition at line 1227 of file MooseApp.h.

Referenced by fixedPointConfig().

◆ _force_restart

const bool MooseApp::_force_restart
protected

Whether or not we are forcefully attempting to load checkpoints (–force-restart)

Definition at line 1282 of file MooseApp.h.

Referenced by forceRestart().

◆ _global_time_offset

Real MooseApp::_global_time_offset
protected

Offset of the local App time to the "global" problem time.

Definition at line 1163 of file MooseApp.h.

Referenced by getGlobalTimeOffset(), and setGlobalTimeOffset().

◆ _heap_profiling

bool MooseApp::_heap_profiling = false
private

Memory profiling.

Definition at line 1548 of file MooseApp.h.

Referenced by ~MooseApp().

◆ _initial_backup

std::unique_ptr<Backup>* const MooseApp::_initial_backup
private

The backup for use in initial setup; this will get set from the _initial_backup input parameter that typically gets set from a MultiApp that has a backup This is a pointer to a pointer because at the time of construction of the app, the backup will not be filled yet.

Definition at line 1563 of file MooseApp.h.

Referenced by hasInitialBackup(), and restoreFromInitialBackup().

◆ _initial_from_file

bool MooseApp::_initial_from_file
protected

This variable indicates when a request has been made to restart from an Exodus file.

Definition at line 1261 of file MooseApp.h.

Referenced by getExodusFileRestart(), and setExodusFileRestart().

◆ _input_parameter_warehouse

std::unique_ptr<InputParameterWarehouse> MooseApp::_input_parameter_warehouse
protected

Input parameter storage structure; unique_ptr so we can control its destruction order.

Definition at line 1170 of file MooseApp.h.

Referenced by getInputParameterWarehouse(), and ~MooseApp().

◆ _interface_registry

std::map<std::type_index, std::unique_ptr<InterfaceRegistryObjectsBase> > MooseApp::_interface_registry
private

Registration for interface objects.

Definition at line 1557 of file MooseApp.h.

Referenced by getInterfaceObjects(), and registerInterfaceObject().

◆ _lib_handles

std::unordered_map<std::string, DynamicLibraryInfo> MooseApp::_lib_handles
protected

The library archive (name only), registration method and the handle to the method.

Definition at line 1323 of file MooseApp.h.

Referenced by getLoadedLibraryPaths(), loadLibraryAndDependencies(), and ~MooseApp().

◆ _libtorch_device

const torch::DeviceType MooseApp::_libtorch_device
private

The libtorch device this app is using (converted from compute_device)

Definition at line 1567 of file MooseApp.h.

◆ _master_displaced_mesh

const MooseMesh* const MooseApp::_master_displaced_mesh
private

The displaced mesh from master app.

Definition at line 1519 of file MooseApp.h.

Referenced by masterDisplacedMesh().

◆ _master_mesh

const MooseMesh* const MooseApp::_master_mesh
private

The mesh from master app.

Definition at line 1516 of file MooseApp.h.

Referenced by masterMesh().

◆ _mesh_generator_system

MeshGeneratorSystem MooseApp::_mesh_generator_system
private

◆ _mfem_device

std::shared_ptr<mfem::Device> MooseApp::_mfem_device
private

The MFEM Device object.

Definition at line 1572 of file MooseApp.h.

Referenced by getMFEMDevice(), and setMFEMDevice().

◆ _mfem_devices

std::set<std::string> MooseApp::_mfem_devices
private

MFEM supported devices based on user-provided config.

Definition at line 1575 of file MooseApp.h.

Referenced by getMFEMDevices(), and setMFEMDevice().

◆ _multiapp_level

unsigned int MooseApp::_multiapp_level
private

Level of multiapp, the master is level 0. This used by the Console to indent output.

Definition at line 1507 of file MooseApp.h.

Referenced by getOutputFileBase(), isUltimateMaster(), and multiAppLevel().

◆ _multiapp_number

unsigned int MooseApp::_multiapp_number
private

Numbering in all the sub-apps on the same level.

Definition at line 1510 of file MooseApp.h.

Referenced by multiAppNumber().

◆ _name

const std::string& MooseBase::_name
protectedinherited

The name of this class.

Definition at line 359 of file MooseBase.h.

Referenced by AddBCAction::act(), AddConstraintAction::act(), AddFVInterfaceKernelAction::act(), AddKernelAction::act(), AddIndicatorAction::act(), AddPostprocessorAction::act(), AddDGKernelAction::act(), AddDamperAction::act(), AddScalarKernelAction::act(), AddUserObjectAction::act(), AddMeshGeneratorAction::act(), AddInitialConditionAction::act(), AddTransferAction::act(), AddVectorPostprocessorAction::act(), AddInterfaceKernelAction::act(), AddDiracKernelAction::act(), PartitionerAction::act(), AddFVInitialConditionAction::act(), ReadExecutorParamsAction::act(), AddFunctorMaterialAction::act(), AddMarkerAction::act(), AddMaterialAction::act(), AddNodalKernelAction::act(), AddMultiAppAction::act(), AddPositionsAction::act(), AddReporterAction::act(), AddTimesAction::act(), AddFieldSplitAction::act(), AddFVKernelAction::act(), AddFVBCAction::act(), AddHDGKernelAction::act(), AddTimeStepperAction::act(), AddDistributionAction::act(), SetupPreconditionerAction::act(), SetupTimeIntegratorAction::act(), AddFunctionAction::act(), AddConvergenceAction::act(), AddMeshDivisionAction::act(), AddOutputAction::act(), AddLinearFVBCAction::act(), AddLinearFVKernelAction::act(), AddCorrectorAction::act(), AddMeshModifiersAction::act(), AddSamplerAction::act(), AddControlAction::act(), AddMFEMFESpaceAction::act(), AddMFEMSolverAction::act(), AddMFEMSubMeshAction::act(), AddMFEMPreconditionerAction::act(), AddPeriodicBCAction::act(), ADPiecewiseLinearInterpolationMaterial::ADPiecewiseLinearInterpolationMaterial(), BatchMeshGeneratorAction::BatchMeshGeneratorAction(), PiecewiseTabularBase::buildFromFile(), PiecewiseTabularBase::buildFromXY(), PiecewiseLinearBase::buildInterpolation(), CombinerGenerator::CombinerGenerator(), Executor::Executor(), ExtraIDIntegralReporter::ExtraIDIntegralReporter(), QuadraturePointMultiApp::fillPositions(), CentroidMultiApp::fillPositions(), MultiApp::fillPositions(), FunctionDT::FunctionDT(), FillBetweenCurvesGenerator::generate(), FillBetweenPointVectorsGenerator::generate(), FillBetweenSidesetsGenerator::generate(), MooseBase::MooseBase(), NearestPointBase< LayeredSideDiffusiveFluxAverage, SideIntegralVariableUserObject >::name(), ParsedFunctorMaterialTempl< is_ad >::ParsedFunctorMaterialTempl(), PiecewiseBilinear::PiecewiseBilinear(), PiecewiseLinearInterpolationMaterial::PiecewiseLinearInterpolationMaterial(), PiecewiseBase::setData(), and AddVariableAction::varName().

◆ _null_executor

std::shared_ptr<NullExecutor> MooseApp::_null_executor
protected

Used to return an executor that does nothing.

Definition at line 1234 of file MooseApp.h.

Referenced by createExecutors(), getExecutor(), and getNullExecutor().

◆ _output_buffer_cache

std::streambuf* MooseApp::_output_buffer_cache
private

Cache output buffer so the language server can turn it off then back on.

Definition at line 1539 of file MooseApp.h.

Referenced by setupOptions().

◆ _output_file_base

std::string MooseApp::_output_file_base
protected

The output file basename.

Definition at line 1145 of file MooseApp.h.

Referenced by getOutputFileBase(), setOutputFileBase(), and setupOptions().

◆ _output_file_numbers

std::map<std::string, unsigned int> MooseApp::_output_file_numbers
protected

Map of outputer name and file number (used by MultiApps to propagate file numbers down through the multiapps)

Definition at line 1296 of file MooseApp.h.

Referenced by getOutputFileNumbers(), and setOutputFileNumbers().

◆ _output_position

Point MooseApp::_output_position
protected

The output position.

Definition at line 1154 of file MooseApp.h.

Referenced by getOutputPosition(), and setOutputPosition().

◆ _output_position_set

bool MooseApp::_output_position_set
protected

Whether or not an output position has been set for this app.

Definition at line 1151 of file MooseApp.h.

Referenced by hasOutputPosition(), and setOutputPosition().

◆ _output_warehouse

OutputWarehouse MooseApp::_output_warehouse
protected

OutputWarehouse object for this App.

Definition at line 1179 of file MooseApp.h.

Referenced by getOutputWarehouse(), setOutputFileBase(), and setOutputPosition().

◆ _pars

const InputParameters& MooseBase::_pars
protectedinherited

The object's parameters.

Definition at line 362 of file MooseBase.h.

Referenced by AddFVICAction::act(), AddICAction::act(), CreateProblemAction::act(), CreateProblemDefaultAction::act(), SetupMeshAction::act(), ComposeTimeStepperAction::act(), SetupDebugAction::act(), AddAuxKernelAction::act(), AddPeriodicBCAction::act(), CommonOutputAction::act(), FunctorMaterial::addFunctorPropertyByBlocks(), BreakMeshByBlockGeneratorBase::BreakMeshByBlockGeneratorBase(), PiecewiseTabularBase::buildFromFile(), PNGOutput::calculateRescalingValues(), MooseBase::callMooseError(), MooseBase::connectControllableParams(), Console::Console(), copyInputs(), MaterialBase::declareADProperty(), MaterialBase::declareProperty(), FEProblemSolve::FEProblemSolve(), FunctionMaterialBase< is_ad >::FunctionMaterialBase(), FileMeshGenerator::generate(), MooseBase::getBase(), MooseBase::getCheckedPointerParam(), MaterialBase::getGenericZeroMaterialProperty(), MooseBase::getHitNode(), MeshGenerator::getMeshGeneratorNameFromParam(), MeshGenerator::getMeshGeneratorNamesFromParam(), MooseBase::getParam(), MooseBase::hasBase(), MeshGenerator::hasGenerateData(), AddVariableAction::init(), AdvancedOutput::initExecutionTypes(), Console::initialSetup(), MooseBase::isParamSetByUser(), MooseBase::isParamValid(), MultiApp::keepSolutionDuringRestore(), MooseBase::messagePrefix(), MooseBase::MooseBase(), outputMachineReadableData(), MooseBase::paramError(), GlobalParamsAction::parameters(), MooseBase::parameters(), MooseBase::paramInfo(), MooseBase::paramWarning(), MooseMesh::prepare(), Eigenvalue::prepareSolverOptions(), MooseMesh::setCoordSystem(), MooseMesh::setPartitionerHelper(), SetupMeshAction::setupMesh(), TransientBase::setupTimeIntegrator(), showInputs(), and MooseBase::uniqueName().

◆ _parser

const std::shared_ptr<Parser> MooseApp::_parser
protected

Parser for parsing the input file (owns the root hit node)

Definition at line 1182 of file MooseApp.h.

Referenced by getInputFileNames(), getLastInputFileName(), parser(), and run().

◆ _perf_graph

PerfGraph& MooseApp::_perf_graph
protected

The PerfGraph object for this application (recoverable)

Definition at line 1203 of file MooseApp.h.

Referenced by perfGraph(), and setupOptions().

◆ _pg_moose_app

MooseApp& PerfGraphInterface::_pg_moose_app
protectedinherited

The MooseApp that owns the PerfGraph.

Definition at line 124 of file PerfGraphInterface.h.

Referenced by PerfGraphInterface::perfGraph().

◆ _prefix

const std::string PerfGraphInterface::_prefix
protectedinherited

A prefix to use for all sections.

Definition at line 127 of file PerfGraphInterface.h.

Referenced by PerfGraphInterface::timedSectionName().

◆ _rank_map

const RankMap MooseApp::_rank_map
protected

The RankMap is a useful object for determining how the processes are laid out on the physical hardware.

Definition at line 1209 of file MooseApp.h.

Referenced by rankMap().

◆ _rd_reader

RestartableDataReader MooseApp::_rd_reader
private

Definition at line 1527 of file MooseApp.h.

Referenced by finalizeRestore(), and restore().

◆ _ready_to_exit

bool MooseApp::_ready_to_exit
protected

Definition at line 1256 of file MooseApp.h.

Referenced by executeExecutioner(), run(), runInputFile(), and setupOptions().

◆ _recover

bool MooseApp::_recover
protected

Whether or not this is a recovery run.

Definition at line 1270 of file MooseApp.h.

Referenced by isRecovering(), setRecover(), and setupOptions().

◆ _recoverable_data_names

DataNames MooseApp::_recoverable_data_names
protected

Data names that will only be read from the restart file during RECOVERY.

e.g. these names are excluded during restart.

Definition at line 1200 of file MooseApp.h.

Referenced by getRecoverableData(), and registerRestartableNameWithFilter().

◆ _relationship_managers

std::set<std::shared_ptr<RelationshipManager> > MooseApp::_relationship_managers
protected

◆ _restart

bool MooseApp::_restart
protected

Whether or not this is a restart run.

Definition at line 1273 of file MooseApp.h.

Referenced by isRestarting(), and setRestart().

◆ _restart_recover_base

std::string MooseApp::_restart_recover_base
protected

The base name to restart/recover from. If blank then we will find the newest checkpoint file.

Definition at line 1288 of file MooseApp.h.

Referenced by getRecoverFileBase(), getRestartRecoverFileBase(), hasRecoverFileBase(), hasRestartRecoverFileBase(), setRestartRecoverFileBase(), and setupOptions().

◆ _restartable_data

std::vector<RestartableDataMap> MooseApp::_restartable_data
protected

Where the restartable data is held (indexed on tid)

Definition at line 1194 of file MooseApp.h.

Referenced by backup(), getRestartableData(), registerRestartableData(), and ~MooseApp().

◆ _restartable_meta_data

std::unordered_map<RestartableDataMapName, std::pair<RestartableDataMap, std::string> > MooseApp::_restartable_meta_data
private

◆ _solution_invalidity

SolutionInvalidity& MooseApp::_solution_invalidity
protected

The SolutionInvalidity object for this application.

Definition at line 1206 of file MooseApp.h.

Referenced by solutionInvalidity().

◆ _split_mesh

bool MooseApp::_split_mesh
protected

Whether or not we are performing a split mesh operation (–split-mesh)

Definition at line 1276 of file MooseApp.h.

Referenced by isSplitMesh(), and setupOptions().

◆ _start_time

Real MooseApp::_start_time
protected

The time at which to start the simulation.

Definition at line 1160 of file MooseApp.h.

Referenced by getStartTime(), and setStartTime().

◆ _start_time_set

bool MooseApp::_start_time_set
protected

Whether or not an start time has been set.

Definition at line 1157 of file MooseApp.h.

Referenced by hasStartTime(), and setStartTime().

◆ _syntax

Syntax MooseApp::_syntax
protected

Syntax of the input file.

Definition at line 1166 of file MooseApp.h.

Referenced by setupOptions(), and syntax().

◆ _sys_info

SystemInfo MooseApp::_sys_info
protected

System Information.

Definition at line 1188 of file MooseApp.h.

Referenced by getSystemInfo().

◆ _template_to_clones

std::map<const RelationshipManager *, std::map<const MeshBase *, std::unique_ptr<RelationshipManager> > > MooseApp::_template_to_clones
private

Map from a template relationship manager to a map in which the key-value pairs represent the MeshBase object and the clone of the template relationship manager, e.g.

the top-level map key

Definition at line 1554 of file MooseApp.h.

Referenced by createRMFromTemplateAndInit(), getRMClone(), and hasRMClone().

◆ _test_checkpoint_half_transient

const bool MooseApp::_test_checkpoint_half_transient
protected

Whether or not this simulation should only run half its transient (useful for testing recovery)

Definition at line 1291 of file MooseApp.h.

Referenced by testCheckpointHalfTransient().

◆ _test_restep

const bool MooseApp::_test_restep
protected

Whether or not this simulation should fail its middle timestep and repeat (for testing)

Definition at line 1293 of file MooseApp.h.

Referenced by testReStep().

◆ _the_warehouse

std::unique_ptr<TheWarehouse> MooseApp::_the_warehouse
private

The combined warehouse for storing any MooseObject based object.

Definition at line 1504 of file MooseApp.h.

Referenced by theWarehouse(), and ~MooseApp().

◆ _trap_fpe

bool MooseApp::_trap_fpe
protected

Whether or not FPE trapping should be turned on.

Definition at line 1285 of file MooseApp.h.

Referenced by getFPTrapFlag(), and setupOptions().

◆ _type

const std::string MooseApp::_type
protected

The string representation of the type of this object as registered (see registerApp(AppName))

Definition at line 1139 of file MooseApp.h.

◆ _undisp_to_disp_rms

std::unordered_map<RelationshipManager *, std::shared_ptr<libMesh::GhostingFunctor> > MooseApp::_undisp_to_disp_rms
protected

A map from undisplaced relationship managers to their displaced clone (stored as the base GhostingFunctor).

Anytime we clone in attachRelationshipManagers we create a map entry from the cloned undisplaced relationship manager to its displaced clone counterpart. We leverage this map when removing relationship managers/ghosting functors

Definition at line 1313 of file MooseApp.h.

◆ _use_eigen_value

bool MooseApp::_use_eigen_value
protected

Boolean to indicate whether to use an eigenvalue executioner.

Definition at line 1240 of file MooseApp.h.

Referenced by useEigenvalue().

◆ _use_executor

const bool MooseApp::_use_executor
protected

Indicates whether we are operating in the new/experimental executor mode instead of using the legacy executioner system.

Definition at line 1231 of file MooseApp.h.

Referenced by executeExecutioner(), and useExecutor().

◆ _use_master_mesh

const bool MooseApp::_use_master_mesh
private

Whether to use the parent app mesh for this app.

Definition at line 1513 of file MooseApp.h.

Referenced by useMasterMesh().

◆ _use_nonlinear

bool MooseApp::_use_nonlinear
protected

Boolean to indicate whether to use a Nonlinear or EigenSystem (inspected by actions)

Definition at line 1237 of file MooseApp.h.

Referenced by useNonlinear().

◆ _use_split

const bool MooseApp::_use_split
protected

Whether or not we are using a (pre-)split mesh (automatically DistributedMesh)

Definition at line 1279 of file MooseApp.h.

◆ app_param

const std::string MooseBase::app_param = "_moose_app"
staticinherited

◆ MESH_META_DATA

const RestartableDataMapName MooseApp::MESH_META_DATA = "MeshMetaData"
static

◆ MESH_META_DATA_SUFFIX

const RestartableDataMapName MooseApp::MESH_META_DATA_SUFFIX = "mesh"
static

Definition at line 124 of file MooseApp.h.

◆ moose_base_param

const std::string MooseBase::moose_base_param = "_moose_base"
staticinherited

The name of the parameter that contains the moose system base.

Definition at line 61 of file MooseBase.h.

Referenced by InputParameters::getBase(), InputParameters::hasBase(), and InputParameters::registerBase().

◆ name_param

const std::string MooseBase::name_param = "_object_name"
staticinherited

◆ type_param

const std::string MooseBase::type_param = "_type"
staticinherited

◆ unique_name_param

const std::string MooseBase::unique_name_param = "_unique_name"
staticinherited

The name of the parameter that contains the unique object name.

Definition at line 57 of file MooseBase.h.

Referenced by InputParameterWarehouse::addInputParameters(), AppFactory::create(), InputParameterWarehouse::removeInputParameters(), MooseBase::uniqueName(), and MooseBase::validParams().


The documentation for this class was generated from the following files: