![]() |
JSBSim Flight Dynamics Model 1.0 (23 February 2013)
An Open Source Flight Dynamics and Control Software Library in C++
|
Base class for all scheduled JSBSim models. More...
#include <FGModel.h>
Inheritance diagram for FGModel:
Collaboration diagram for FGModel:Public Member Functions | |
| FGModel (FGFDMExec *) | |
| Constructor. | |
| virtual | ~FGModel () |
| Destructor. | |
| FGFDMExec * | GetExec (void) |
| virtual int | GetRate (void) |
| virtual bool | InitModel (void) |
| virtual bool | Run (bool Holding) |
| Runs the model; called by the Executive. | |
| void | SetPropertyManager (FGPropertyManager *fgpm) |
| virtual void | SetRate (int tt) |
Public Attributes | |
| std::string | Name |
Protected Member Functions | |
| virtual void | Debug (int from) |
| virtual bool | Load (Element *el) |
| Loads this model. | |
Protected Attributes | |
| int | exe_ctr |
| FGFDMExec * | FDMExec |
| FGPropertyManager * | PropertyManager |
| int | rate |
| virtual bool Load | ( | Element * | el | ) | [inline, protected, virtual] |
| el | a pointer to the element |
Reimplemented in FGAerodynamics, FGAircraft, FGBuoyantForces, FGExternalReactions, FGGroundReactions, FGInput, FGMassBalance, FGOutput, FGPropulsion, FGOutputFile, FGOutputSocket, FGOutputTextFile, and FGOutputType.
Definition at line 111 of file FGModel.h.
Referenced by FGOutputType::Load().
{return FGModelFunctions::Load(el, PropertyManager);}
Here is the caller graph for this function:| bool Run | ( | bool | Holding | ) | [virtual] |
Can pass in a value indicating if the executive is directing the simulation to Hold.
| Holding | if true, the executive has been directed to hold the sim from advancing time. Some models may ignore this flag, such as the Input model, which may need to be active to listen on a socket for the "Resume" command to be given. The Holding flag is not used in the base FGModel class. |
Reimplemented in FGAccelerations, FGAerodynamics, FGAircraft, FGAtmosphere, FGAuxiliary, FGBuoyantForces, FGExternalReactions, FGFCS, FGGroundReactions, FGInertial, FGInput, FGMassBalance, FGOutput, FGPropagate, FGPropagate, FGPropulsion, FGOutputType, MSIS, and FGWinds.
Definition at line 92 of file FGModel.cpp.
Referenced by FGPropulsion::GetSteadyState(), FGWinds::Run(), FGPropulsion::Run(), FGPropagate::Run(), FGOutputType::Run(), FGOutput::Run(), MSIS::Run(), FGMassBalance::Run(), FGInput::Run(), FGInertial::Run(), FGGroundReactions::Run(), FGFCS::Run(), FGExternalReactions::Run(), FGBuoyantForces::Run(), FGAuxiliary::Run(), FGAtmosphere::Run(), FGAircraft::Run(), FGAerodynamics::Run(), and FGAccelerations::Run().
{
if (debug_lvl & 4) cout << "Entering Run() for model " << Name << endl;
if (rate == 1) return false; // Fast exit if nothing to do
if (exe_ctr >= rate) exe_ctr = 0;
if (exe_ctr++ == 1) return false;
else return true;
}
Here is the caller graph for this function: