MCPcopy Create free account
hub / github.com/JSBSim-Team/jsbsim / PreLoad

Method PreLoad

src/math/FGModelFunctions.cpp:71–88  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

69//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
70
71void FGModelFunctions::PreLoad(Element* el, FGFDMExec* fdmex, string prefix)
72{
73 // Load model post-functions, if any
74
75 Element *function = el->FindElement("function");
76
77 while (function) {
78 string fType = function->GetAttributeValue("type");
79 if (fType.empty() || fType == "pre")
80 PreFunctions.push_back(std::make_shared<FGFunction>(fdmex, function, prefix));
81 else if (fType == "template") {
82 string name = function->GetAttributeValue("name");
83 fdmex->AddTemplateFunc(name, function);
84 }
85
86 function = el->FindNextElement("function");
87 }
88}
89
90//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
91

Callers 1

LoadMethod · 0.80

Calls 4

FindElementMethod · 0.80
GetAttributeValueMethod · 0.80
emptyMethod · 0.80
FindNextElementMethod · 0.80

Tested by

no test coverage detected