]> git.mxchange.org Git - flightgear.git/blobdiff - src/FDM/JSBSim/FGGroundReactions.h
Curt Olson:
[flightgear.git] / src / FDM / JSBSim / FGGroundReactions.h
index e24d1727732320fbd32303891963836feac4dcb8..1a34dae3b049588ca3b51b85d15f7ae1e95cb35a 100644 (file)
@@ -27,10 +27,6 @@ HISTORY
 --------------------------------------------------------------------------------
 09/13/00   JSB   Created
 
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-COMMENTS, REFERENCES,  and NOTES
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 SENTRY
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
@@ -61,6 +57,19 @@ INCLUDES
 
 #define ID_GROUNDREACTIONS "$Id$"
 
+/*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+FORWARD DECLARATIONS
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
+
+namespace JSBSim {
+
+/*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+CLASS DOCUMENTATION
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
+
+/** Manages ground reactions modeling.
+  */
+
 /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 CLASS DECLARATION
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/
@@ -69,26 +78,37 @@ class FGGroundReactions : public FGModel
 {
 public:
   FGGroundReactions(FGFDMExec*);
-  ~FGGroundReactions() {};
+  ~FGGroundReactions(void);
 
   bool Run(void);
   bool Load(FGConfigFile* AC_cfg);
   FGColumnVector3& GetForces(void) {return vForces;}
+  double GetForces(int idx) const {return vForces(idx);}
   FGColumnVector3& GetMoments(void) {return vMoments;}
+  double GetMoments(int idx) const {return vMoments(idx);}
   string GetGroundReactionStrings(void);
   string GetGroundReactionValues(void);
+  
+  inline int GetNumGearUnits(void) const { return lGear.size(); }
+
+  /** Gets a gear instance
+      @param gear index of gear instance
+      @return a pointer to the FGLGear instance of the gear unit requested */
+  inline FGLGear* GetGearUnit(int gear) { return &(lGear[gear]); }
+  
+  void bind(void);
+  void unbind(void);
 
 private:
   vector <FGLGear> lGear;
-  bool GearUp;
   FGColumnVector3 vForces;
   FGColumnVector3 vMoments;
   FGColumnVector3 vMaxStaticGrip;
   FGColumnVector3 vMaxMomentResist;
 
-  void Debug(void);
+  void Debug(int from);
 };
-
+}
 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 #endif