FlightGear next
|
#include <AIFlightPlan.hxx>
Public Member Functions | |
FGAIFlightPlan () | |
FGAIFlightPlan (const std::string &filename) | |
FGAIFlightPlan (FGAIAircraft *, const std::string &p, double course, time_t start, time_t remainingTime, FGAirport *dep, FGAirport *arr, bool firstLeg, double radius, double alt, double lat, double lon, double speed, const std::string &fltType, const std::string &acType, const std::string &airline) | |
virtual | ~FGAIFlightPlan () |
bool | readFlightplan (const SGPath &file) |
read a flight-plan from a file. | |
bool | readFlightplan (std::istream &stream, const sg_location &loc=sg_location{}) |
FGAIWaypoint * | getPreviousWaypoint (void) const |
FGAIWaypoint * | getCurrentWaypoint (void) const |
FGAIWaypoint * | getNextWaypoint (void) const |
int | getNextTurnAngle (void) const |
void | IncrementWaypoint (bool erase) |
void | DecrementWaypoint () |
double | getDistanceToGo (double lat, double lon, FGAIWaypoint *wp) const |
int | getLeg () const |
void | setLeadDistance (double speed, double bearing, FGAIWaypoint *current, FGAIWaypoint *next) |
Set lead_distance_ft. | |
void | setLeadDistance (double distance_ft) |
Set lead_distance_ft. | |
double | getLeadDistance (void) const |
double | getBearing (FGAIWaypoint *previous, FGAIWaypoint *next) const |
double | getBearing (const SGGeod &aPos, FGAIWaypoint *next) const |
double | checkTrackLength (const std::string &wptName) const |
time_t | getStartTime () const |
time_t | getArrivalTime () const |
bool | create (FGAIAircraft *, FGAirport *dep, FGAirport *arr, int leg, double alt, double speed, double lat, double lon, bool firstLeg, double radius, const std::string &fltType, const std::string &aircraftType, const std::string &airline, double distance) |
bool | createPushBack (FGAIAircraft *, bool, FGAirport *, double radius, const std::string &, const std::string &, const std::string &) |
bool | createTakeOff (FGAIAircraft *, bool, FGAirport *, const SGGeod &pos, double speed, const std::string &flightType) |
void | setLeg (int val) |
void | setTime (time_t st) |
double | getLeadInAngle () const |
const std::string & | getRunway () const |
void | setRepeat (bool r) |
bool | getRepeat (void) const |
void | restart (void) |
int | getNrOfWayPoints () |
int | getRouteIndex (int i) const |
const std::string & | getRunway () |
bool | isActive (time_t time) |
void | incrementLeg () |
void | setRunway (const std::string &rwy) |
const char * | getRunwayClassFromTrafficType (const std::string &fltType) |
void | addWaypoint (FGAIWaypoint *wpt) |
void | setName (const std::string &n) |
const std::string & | getName () |
void | setSID (FGAIFlightPlan *fp) |
FGAIFlightPlan * | getSID () |
FGAIWaypoint * | getWayPoint (int i) |
FGAIWaypoint * | getLastWaypoint () const |
void | shortenToFirst (unsigned int number, const std::string &name) |
void | setGate (const ParkingAssignment &pka) |
FGParking * | getParkingGate () const |
FGAirportRef | departureAirport () const |
FGAirportRef | arrivalAirport () const |
bool | empty () const |
wpt_vector_iterator | getFirstWayPoint () |
wpt_vector_iterator | getLastWayPoint () |
bool | isValidPlan () |
Static Public Member Functions | |
static FGAIFlightPlan * | createDummyUserPlan () |
create a nearly empty FlightPlan for the user aircraft, based on the current position and route-manager data. | |
Definition at line 123 of file AIFlightPlan.hxx.
FGAIFlightPlan::FGAIFlightPlan | ( | ) |
Definition at line 95 of file AIFlightPlan.cxx.
|
explicit |
FGAIFlightPlan::FGAIFlightPlan | ( | FGAIAircraft * | , |
const std::string & | p, | ||
double | course, | ||
time_t | start, | ||
time_t | remainingTime, | ||
FGAirport * | dep, | ||
FGAirport * | arr, | ||
bool | firstLeg, | ||
double | radius, | ||
double | alt, | ||
double | lat, | ||
double | lon, | ||
double | speed, | ||
const std::string & | fltType, | ||
const std::string & | acType, | ||
const std::string & | airline ) |
|
virtual |
Definition at line 167 of file AIFlightPlan.cxx.
void FGAIFlightPlan::addWaypoint | ( | FGAIWaypoint * | wpt | ) |
Definition at line 549 of file AIFlightPlan.cxx.
FGAirportRef FGAIFlightPlan::arrivalAirport | ( | ) | const |
Definition at line 635 of file AIFlightPlan.cxx.
double FGAIFlightPlan::checkTrackLength | ( | const std::string & | wptName | ) | const |
Definition at line 592 of file AIFlightPlan.cxx.
bool FGAIFlightPlan::create | ( | FGAIAircraft * | , |
FGAirport * | dep, | ||
FGAirport * | arr, | ||
int | leg, | ||
double | alt, | ||
double | speed, | ||
double | lat, | ||
double | lon, | ||
bool | firstLeg, | ||
double | radius, | ||
const std::string & | fltType, | ||
const std::string & | aircraftType, | ||
const std::string & | airline, | ||
double | distance ) |
Definition at line 50 of file AIFlightPlanCreate.cxx.
|
static |
create a nearly empty FlightPlan for the user aircraft, based on the current position and route-manager data.
Definition at line 640 of file AIFlightPlan.cxx.
bool FGAIFlightPlan::createPushBack | ( | FGAIAircraft * | , |
bool | , | ||
FGAirport * | , | ||
double | radius, | ||
const std::string & | , | ||
const std::string & | , | ||
const std::string & | ) |
Definition at line 45 of file AIFlightPlanCreatePushBack.cxx.
bool FGAIFlightPlan::createTakeOff | ( | FGAIAircraft * | , |
bool | , | ||
FGAirport * | , | ||
const SGGeod & | pos, | ||
double | speed, | ||
const std::string & | flightType ) |
Definition at line 595 of file AIFlightPlanCreate.cxx.
void FGAIFlightPlan::DecrementWaypoint | ( | ) |
Definition at line 398 of file AIFlightPlan.cxx.
FGAirportRef FGAIFlightPlan::departureAirport | ( | ) | const |
Definition at line 630 of file AIFlightPlan.cxx.
bool FGAIFlightPlan::empty | ( | ) | const |
Definition at line 647 of file AIFlightPlan.cxx.
|
inline |
Definition at line 180 of file AIFlightPlan.hxx.
double FGAIFlightPlan::getBearing | ( | const SGGeod & | aPos, |
FGAIWaypoint * | next ) const |
Definition at line 506 of file AIFlightPlan.cxx.
double FGAIFlightPlan::getBearing | ( | FGAIWaypoint * | previous, |
FGAIWaypoint * | next ) const |
Definition at line 501 of file AIFlightPlan.cxx.
FGAIWaypoint * FGAIFlightPlan::getCurrentWaypoint | ( | void | ) | const |
Definition at line 331 of file AIFlightPlan.cxx.
double FGAIFlightPlan::getDistanceToGo | ( | double | lat, |
double | lon, | ||
FGAIWaypoint * | wp ) const |
Definition at line 418 of file AIFlightPlan.cxx.
|
inline |
Definition at line 323 of file AIFlightPlan.hxx.
|
inline |
Definition at line 324 of file AIFlightPlan.hxx.
FGAIWaypoint * FGAIFlightPlan::getLastWaypoint | ( | ) | const |
Definition at line 310 of file AIFlightPlan.cxx.
|
inline |
Definition at line 174 of file AIFlightPlan.hxx.
|
inline |
Definition at line 194 of file AIFlightPlan.hxx.
|
inline |
Definition at line 168 of file AIFlightPlan.hxx.
|
inline |
Definition at line 219 of file AIFlightPlan.hxx.
int FGAIFlightPlan::getNextTurnAngle | ( | void | ) | const |
Definition at line 351 of file AIFlightPlan.cxx.
FGAIWaypoint * FGAIFlightPlan::getNextWaypoint | ( | void | ) | const |
Definition at line 338 of file AIFlightPlan.cxx.
|
inline |
Definition at line 200 of file AIFlightPlan.hxx.
FGParking * FGAIFlightPlan::getParkingGate | ( | ) | const |
Definition at line 625 of file AIFlightPlan.cxx.
FGAIWaypoint * FGAIFlightPlan::getPreviousWaypoint | ( | void | ) | const |
Definition at line 318 of file AIFlightPlan.cxx.
|
inline |
Definition at line 198 of file AIFlightPlan.hxx.
int FGAIFlightPlan::getRouteIndex | ( | int | i | ) | const |
Definition at line 584 of file AIFlightPlan.cxx.
|
inline |
Definition at line 204 of file AIFlightPlan.hxx.
const std::string & FGAIFlightPlan::getRunway | ( | ) | const |
const char * FGAIFlightPlan::getRunwayClassFromTrafficType | ( | const std::string & | fltType | ) |
fltType | a string describing the type of traffic, normally used for gate assignments |
Currently valid traffic types for gate assignment:
Valid runway classes:
Definition at line 1250 of file AIFlightPlanCreate.cxx.
|
inline |
Definition at line 222 of file AIFlightPlan.hxx.
|
inline |
Definition at line 179 of file AIFlightPlan.hxx.
|
inline |
Definition at line 223 of file AIFlightPlan.hxx.
|
inline |
Definition at line 207 of file AIFlightPlan.hxx.
void FGAIFlightPlan::IncrementWaypoint | ( | bool | erase | ) |
Definition at line 357 of file AIFlightPlan.cxx.
|
inline |
Definition at line 205 of file AIFlightPlan.hxx.
|
inline |
Definition at line 325 of file AIFlightPlan.hxx.
bool FGAIFlightPlan::readFlightplan | ( | const SGPath & | file | ) |
read a flight-plan from a file.
All current contents of the flight-plan are replaced, and the current waypoint is reset to the beginning
Definition at line 226 of file AIFlightPlan.cxx.
bool FGAIFlightPlan::readFlightplan | ( | std::istream & | stream, |
const sg_location & | loc = sg_location{} ) |
Definition at line 232 of file AIFlightPlan.cxx.
void FGAIFlightPlan::restart | ( | void | ) |
Definition at line 579 of file AIFlightPlan.cxx.
void FGAIFlightPlan::setGate | ( | const ParkingAssignment & | pka | ) |
Definition at line 620 of file AIFlightPlan.cxx.
void FGAIFlightPlan::setLeadDistance | ( | double | distance_ft | ) |
Set lead_distance_ft.
Definition at line 492 of file AIFlightPlan.cxx.
void FGAIFlightPlan::setLeadDistance | ( | double | speed, |
double | bearing, | ||
FGAIWaypoint * | current, | ||
FGAIWaypoint * | next ) |
Set lead_distance_ft.
sets distance in feet from a lead point to the current waypoint basically a catch radius, that triggers the advancement of WPs
Definition at line 427 of file AIFlightPlan.cxx.
|
inline |
Definition at line 187 of file AIFlightPlan.hxx.
|
inline |
Definition at line 218 of file AIFlightPlan.hxx.
|
inline |
Definition at line 197 of file AIFlightPlan.hxx.
|
inline |
Definition at line 213 of file AIFlightPlan.hxx.
|
inline |
Definition at line 221 of file AIFlightPlan.hxx.
|
inline |
Definition at line 192 of file AIFlightPlan.hxx.
void FGAIFlightPlan::shortenToFirst | ( | unsigned int | number, |
const std::string & | name ) |
Definition at line 612 of file AIFlightPlan.cxx.