From: Mathias Froehlich Date: Tue, 4 Oct 2011 19:07:24 +0000 (+0200) Subject: hla: Remove interface functions that should not be called explicitly. X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=70ac6614e8d8243c6f1aebb1cd5b25160499510d;p=simgear.git hla: Remove interface functions that should not be called explicitly. --- diff --git a/simgear/hla/HLAFederate.hxx b/simgear/hla/HLAFederate.hxx index 0775a566..3083903c 100644 --- a/simgear/hla/HLAFederate.hxx +++ b/simgear/hla/HLAFederate.hxx @@ -186,9 +186,11 @@ public: bool readObjectModelTemplate(const std::string& objectModel, ObjectModelFactory& objectModelFactory); + /// Get the object class of a given name HLAObjectClass* getObjectClass(const std::string& name); const HLAObjectClass* getObjectClass(const std::string& name) const; + /// Get the interaction class of a given name HLAInteractionClass* getInteractionClass(const std::string& name); const HLAInteractionClass* getInteractionClass(const std::string& name) const; diff --git a/simgear/hla/HLAObjectInstance.cxx b/simgear/hla/HLAObjectInstance.cxx index ae726ee4..1644d938 100644 --- a/simgear/hla/HLAObjectInstance.cxx +++ b/simgear/hla/HLAObjectInstance.cxx @@ -409,26 +409,6 @@ HLAObjectInstance::setAttributes(const HLAAttributePathElementMap& attributePath } } -void -HLAObjectInstance::requestAttributeUpdate(unsigned index) -{ - if (!_rtiObjectInstance.valid()) { - SG_LOG(SG_IO, SG_ALERT, "Trying to request attribute update for inactive object!"); - return; - } - _rtiObjectInstance->setRequestAttributeUpdate(index, true); -} - -void -HLAObjectInstance::requestAttributeUpdate() -{ - if (!_rtiObjectInstance.valid()) { - SG_LOG(SG_IO, SG_ALERT, "Trying to request attribute update for inactive object!"); - return; - } - _rtiObjectInstance->setRequestAttributeUpdate(true); -} - void HLAObjectInstance::registerInstance() { @@ -467,16 +447,6 @@ HLAObjectInstance::deleteInstance(const RTIData& tag) _rtiObjectInstance->deleteObjectInstance(tag); } -void -HLAObjectInstance::localDeleteInstance() -{ - if (!_rtiObjectInstance.valid()) { - SG_LOG(SG_IO, SG_ALERT, "Trying to delete inactive object!"); - return; - } - _rtiObjectInstance->localDeleteObjectInstance(); -} - void HLAObjectInstance::updateAttributeValues(const RTIData& tag) { @@ -501,16 +471,6 @@ HLAObjectInstance::updateAttributeValues(const SGTimeStamp& timeStamp, const RTI _rtiObjectInstance->updateAttributeValues(timeStamp, tag); } -void -HLAObjectInstance::reflectQueuedAttributeValues(const SGTimeStamp& timeStamp) -{ - if (!_rtiObjectInstance.valid()) { - SG_LOG(SG_IO, SG_INFO, "Not updating inactive object!"); - return; - } - _rtiObjectInstance->reflectQueuedAttributeValues(timeStamp); -} - void HLAObjectInstance::removeInstance(const RTIData& tag) { diff --git a/simgear/hla/HLAObjectInstance.hxx b/simgear/hla/HLAObjectInstance.hxx index c0420276..974d2a98 100644 --- a/simgear/hla/HLAObjectInstance.hxx +++ b/simgear/hla/HLAObjectInstance.hxx @@ -52,13 +52,8 @@ public: void setAttribute(unsigned index, const HLAPathElementMap& pathElementMap); void setAttributes(const HLAAttributePathElementMap& attributePathElementMap); - // Ask the rti to provide the attribute at index - void requestAttributeUpdate(unsigned index); - void requestAttributeUpdate(); - void registerInstance(); void deleteInstance(const RTIData& tag); - void localDeleteInstance(); class AttributeCallback : public SGReferenced { public: @@ -85,11 +80,6 @@ public: void updateAttributeValues(const RTIData& tag); void updateAttributeValues(const SGTimeStamp& timeStamp, const RTIData& tag); - // Retrieve queued up updates up to and including timestamp, - // Note that this only applies to timestamped updates. - // The unordered updates are reflected as they arrive - void reflectQueuedAttributeValues(const SGTimeStamp& timeStamp); - private: void removeInstance(const RTIData& tag); void reflectAttributeValues(const RTIIndexDataPairList& dataPairList, const RTIData& tag);