SGSubsystem classes: Addition of staticSubsystemClassId() to all subsystems.

This commit is contained in:
Edward d'Auvergne 2018-05-04 14:28:15 +02:00
parent 991fafb839
commit c8625ce599
5 changed files with 15 additions and 0 deletions

View File

@ -38,6 +38,9 @@ public:
// Subsystem API.
void update(double delta_time_sec) override;
// Subsystem identification.
static const char* staticSubsystemClassId() { return "interpolator"; }
// Simple method that interpolates a double property value from
// its current value (default of zero) to the specified target
// over the specified time.

View File

@ -50,6 +50,9 @@ public:
void unbind() override;
void update(double) override;
// Subsystem identification.
static const char* staticSubsystemClassId() { return "terrasync"; }
/// notify terrasync that the sim was repositioned, as opposed to
/// us travelling in a direction. Avoid last_lat / last_lon blocking
/// certain tiles when we reposition.

View File

@ -43,6 +43,9 @@ public:
void unbind() override;
void update(double dt) override;
// Subsystem identification.
static const char* staticSubsystemClassId() { return "performance-mon"; }
private:
static void subSystemMgrHook(void* userData, const std::string& name, SampleStatistic* timeStat);

View File

@ -82,6 +82,9 @@ public:
void unbind() override;
void update(double delta_time_sec) override;
// Subsystem identification.
static const char* staticSubsystemClassId() { return "events"; }
void setRealtimeProperty(SGPropertyNode* node) { _rtProp = node; }
/**

View File

@ -525,6 +525,9 @@ public:
void update(double delta_time_sec) override;
bool is_suspended() const override;
// Subsystem identification.
static const char* staticSubsystemClassId() { return "subsystem-mgr"; }
virtual void add (const char * name,
SGSubsystem * subsystem,
GroupType group = GENERAL,