]> git.mxchange.org Git - flightgear.git/commitdiff
More name changing.
authorcurt <curt>
Fri, 21 Apr 2000 16:42:01 +0000 (16:42 +0000)
committercurt <curt>
Fri, 21 Apr 2000 16:42:01 +0000 (16:42 +0000)
src/Navaids/nav.hxx
src/Navaids/navlist.cxx
src/Navaids/navlist.hxx
src/Navaids/testnavs.cxx

index b6a110ab7478df836c62f02b52cb96b21c939dbe..265bc5911594c15b371c30c3f14fe050dcc36165 100644 (file)
@@ -1,4 +1,4 @@
-// navaid.hxx -- navaid class
+// nav.hxx -- vor/dme/ndb class
 //
 // Written by Curtis Olson, started April 2000.
 //
@@ -21,8 +21,8 @@
 // $Id$
 
 
-#ifndef _FG_NAVAID_HXX
-#define _FG_NAVAID_HXX
+#ifndef _FG_NAV_HXX
+#define _FG_NAV_HXX
 
 
 #include <simgear/compiler.h>
@@ -43,7 +43,7 @@ FG_USING_STD(istream);
 #endif
 
 
-class FGNavaid {
+class FGNav {
 
     char type;
     double lon, lat;
@@ -55,8 +55,8 @@ class FGNavaid {
 
 public:
 
-    inline FGNavaid(void) {}
-    inline ~FGNavaid(void) {}
+    inline FGNav(void) {}
+    inline ~FGNav(void) {}
 
     inline char get_type() const { return type; }
     inline double get_lon() const { return lon; }
@@ -76,12 +76,12 @@ public:
     inline void set_dme( bool b ) { dme = b; }
     inline void set_ident( char *i ) { strncpy( ident, i, 5 ); }
 
-    friend istream& operator>> ( istream&, FGNavaid& );
+    friend istream& operator>> ( istream&, FGNav& );
 };
 
 
 inline istream&
-operator >> ( istream& in, FGNavaid& n )
+operator >> ( istream& in, FGNav& n )
 {
     double f;
     char c;
@@ -99,4 +99,4 @@ operator >> ( istream& in, FGNavaid& n )
 }
 
 
-#endif // _FG_NAVAID_HXX
+#endif // _FG_NAV_HXX
index a23bef3a552474ca8f31b2cb8d4d9097115df5c0..18f0cb2cc6dfd5b00484dd89ad926cd503c37a78 100644 (file)
 
 
 // Constructor
-FGNavaids::FGNavaids( void ) {
+FGNavList::FGNavList( void ) {
 }
 
 
 // Destructor
-FGNavaids::~FGNavaids( void ) {
+FGNavList::~FGNavList( void ) {
 }
 
 
 // load the navaids and build the map
-bool FGNavaids::init( FGPath path ) {
-    FGNavaid n;
+bool FGNavList::init( FGPath path ) {
+    FGNav n;
 
     navaids.erase( navaids.begin(), navaids.end() );
 
@@ -92,8 +92,8 @@ bool FGNavaids::init( FGPath path ) {
 
 // query the database for the specified frequency, lon and lat are in
 // degrees, elev is in meters
-bool FGNavaids::query( double lon, double lat, double elev, double freq,
-                      FGNavaid *n, double *heading, double *dist )
+bool FGNavList::query( double lon, double lat, double elev, double freq,
+                      FGNav *n, double *heading, double *dist )
 {
     nav_list_type stations = navaids[(int)(freq*100.0)];
 
index 85312ef8e579ac70670f5a34d2e3303f988f41c6..1ae80e5b04c2b9c42766c877d5f625dc6795225f 100644 (file)
@@ -1,4 +1,4 @@
-// navaids.hxx -- navaids management class
+// navlist.hxx -- navaids management class
 //
 // Written by Curtis Olson, started April 2000.
 //
@@ -21,8 +21,8 @@
 // $Id$
 
 
-#ifndef _FG_NAVAIDS_HXX
-#define _FG_NAVAIDS_HXX
+#ifndef _FG_NAVLIST_HXX
+#define _FG_NAVLIST_HXX
 
 
 #include <simgear/compiler.h>
@@ -37,10 +37,10 @@ FG_USING_STD(map);
 FG_USING_STD(vector);
 
 
-class FGNavaids {
+class FGNavList {
 
     // convenience types
-    typedef vector < FGNavaid > nav_list_type;
+    typedef vector < FGNav > nav_list_type;
     typedef nav_list_type::iterator nav_list_iterator;
     typedef nav_list_type::const_iterator nav_list_const_iterator;
 
@@ -52,8 +52,8 @@ class FGNavaids {
 
 public:
 
-    FGNavaids();
-    ~FGNavaids();
+    FGNavList();
+    ~FGNavList();
 
     // load the navaids and build the map
     bool init( FGPath path );
@@ -61,8 +61,8 @@ public:
     // query the database for the specified frequency, lon and lat are
     // in degrees, elev is in meters
     bool query( double lon, double lat, double elev, double freq,
-               FGNavaid *n, double *heading, double *dist);
+               FGNav *n, double *heading, double *dist);
 };
 
 
-#endif // _FG_NAVAIDS_HXX
+#endif // _FG_NAVLIST_HXX
index 59a5c678cca95490d64c192cf187a48e49409acb..81990f55c051b2ef61ff78cdfab613216780ab9b 100644 (file)
@@ -3,13 +3,13 @@
 #include "navlist.hxx"
 
 int main() {
-    FGNavaids navs;
+    FGNavList navs;
 
     FGPath p( "/export/data2/curt/FlightGear/Navaids/default.nav" );
    
     navs.init( p );
 
-    FGNavaid n;
+    FGNav n;
     double heading, dist;
     if ( navs.query( -93.2, 45.14, 3000, 117.30,
                     &n, &heading, &dist) ) {