Line data Source code
1 : //* This file is part of the MOOSE framework 2 : //* https://mooseframework.inl.gov 3 : //* 4 : //* All rights reserved, see COPYRIGHT for full restrictions 5 : //* https://github.com/idaholab/moose/blob/master/COPYRIGHT 6 : //* 7 : //* Licensed under LGPL 2.1, please see LICENSE for details 8 : //* https://www.gnu.org/licenses/lgpl-2.1.html 9 : 10 : #include "ChemicalReactionsApp.h" 11 : #include "Moose.h" 12 : #include "AppFactory.h" 13 : #include "MooseSyntax.h" 14 : #include "Capabilities.h" 15 : 16 : InputParameters 17 503 : ChemicalReactionsApp::validParams() 18 : { 19 503 : InputParameters params = MooseApp::validParams(); 20 : 21 503 : params.set<bool>("automatic_automatic_scaling") = false; 22 503 : params.set<bool>("use_legacy_material_output") = false; 23 503 : params.set<bool>("use_legacy_initial_residual_evaluation_behavior") = false; 24 : 25 503 : return params; 26 0 : } 27 : 28 : registerKnownLabel("ChemicalReactionsApp"); 29 : 30 503 : ChemicalReactionsApp::ChemicalReactionsApp(const InputParameters & parameters) 31 503 : : MooseApp(parameters) 32 : { 33 503 : ChemicalReactionsApp::registerAll(_factory, _action_factory, _syntax); 34 503 : } 35 : 36 454 : ChemicalReactionsApp::~ChemicalReactionsApp() {} 37 : 38 : void 39 779 : ChemicalReactionsApp::registerAll(Factory & f, ActionFactory & af, Syntax & syntax) 40 : { 41 779 : Registry::registerObjectsTo(f, {"ChemicalReactionsApp"}); 42 779 : Registry::registerActionsTo(af, {"ChemicalReactionsApp"}); 43 : 44 1558 : registerSyntax("AddPrimarySpeciesAction", "ReactionNetwork/AqueousEquilibriumReactions"); 45 1558 : registerSyntax("AddPrimarySpeciesAction", "ReactionNetwork/SolidKineticReactions"); 46 1558 : registerSyntax("AddSecondarySpeciesAction", "ReactionNetwork/AqueousEquilibriumReactions"); 47 1558 : registerSyntax("AddSecondarySpeciesAction", "ReactionNetwork/SolidKineticReactions"); 48 1558 : registerSyntax("AddCoupledEqSpeciesAction", "ReactionNetwork/AqueousEquilibriumReactions"); 49 1558 : registerSyntax("AddCoupledSolidKinSpeciesAction", "ReactionNetwork/SolidKineticReactions"); 50 1558 : registerSyntax("CommonChemicalCompositionAction", "ChemicalComposition"); 51 1558 : registerSyntax("ChemicalCompositionAction", "ChemicalComposition/*"); 52 : 53 : // Physics syntax 54 1558 : registerSyntax("AqueousReactionsEquilibriumPhysics", "Physics/AqueousReactionsEquilibrium/*"); 55 779 : } 56 : 57 : void 58 778 : ChemicalReactionsApp::registerApps() 59 : { 60 778 : const std::string doc = "Thermochimica Gibbs energy minimization library support "; 61 : #ifdef THERMOCHIMICA_ENABLED 62 778 : addBoolCapability("thermochimica", true, doc + "is available."); 63 : #else 64 : addBoolCapability("thermochimica", false, doc + "is not available."); 65 : #endif 66 : 67 1556 : registerApp(ChemicalReactionsApp); 68 778 : } 69 : 70 : extern "C" void 71 0 : ChemicalReactionsApp__registerAll(Factory & f, ActionFactory & af, Syntax & s) 72 : { 73 0 : ChemicalReactionsApp::registerAll(f, af, s); 74 0 : } 75 : 76 : // External entry point for dynamic application loading 77 : extern "C" void 78 0 : ChemicalReactionsApp__registerApps() 79 : { 80 0 : ChemicalReactionsApp::registerApps(); 81 0 : }