VR-Forces 4.0.4 Class Documentation
include/vrvCore/DtAgentUpdateResolverInterface.h
Go to the documentation of this file.
00001 /******************************************************************************
00002 ** Copyright (c) 2008 MAK Technologies, Inc.
00003 ** All rights reserved.
00004 ******************************************************************************/
00005 /******************************************************************************
00006 ** $RCSfile: DtAgentUpdateResolverInterface.h,v $ $Revision: 1.9 $ $State: Exp $
00007 ******************************************************************************/
00008 
00011 
00012 #ifndef DtSceneObjectAbstractUpdater_H_
00013 #define DtSceneObjectAbstractUpdater_H_
00014 
00015 #include <vrvCore/vrvCore.h>
00016 
00017 namespace makVrv
00018 {
00019    class DtMessage;
00020 
00023    class DT_DLL_VRVCORE DtAgentUpdateResolverInterface
00024    {
00025    public:
00026 
00028       virtual ~DtAgentUpdateResolverInterface()
00029       {
00030       }
00031 
00037       template <class ObjectType>
00038       ObjectType* castObjectTypeFromUpdater(const std::string& className)
00039       {
00040          if(canCastToObject(className))
00041             {
00042                return (ObjectType*)objectMemoryAddress();
00043             }
00044          else
00045          {
00046             return 0;
00047          }
00048       }
00049 
00050 
00052       virtual void handleUpdateMessage(DtMessage& message) = 0;
00053 
00055       virtual const std::string& className() const = 0;
00056 
00058       virtual bool canCastToObject(const std::string& className) = 0;
00059 
00062       virtual void* objectMemoryAddress() const = 0;
00063 
00064    };
00065 
00066 }
00067 
00068 #endif
00069 

Document ID: Generated on Fri Jun 29 16:33:32 EDT 2012 from SVN revision 116588
Copyright © 2005-2012 VT MÄK Inc. All Rights Reserved (www.mak.com)