MAK RTIspy API Documentation for HLA 1.3
desRespMsg.h
Go to the documentation of this file.
00001 /*********************************************************************
00002 ** Copyright (c) 1998 MaK Technologies, Inc.
00003 ** All rights reserved.
00004 *********************************************************************/
00005 /*********************************************************************
00006 ** $RCSfile: desRespMsg.h,v $ $Revision: 1.16 $ $State: Exp $
00007 *********************************************************************/
00008 
00011 
00012 #ifndef DtDestroyResponseMsg_H_
00013 #define DtDestroyResponseMsg_H_
00014 
00015 #include "rtiMsg.h"
00016 #include "netRtiMsgHdr.h"
00017 #include "netDeRespMsg.h"
00018 
00019 class DtConnectionMgr;
00020 class DtDestroyResponseMsg;
00021 typedef void (*DtDestroyResponseCb)(const DtDestroyResponseMsg& inter, void* usr);
00022 
00023 enum DtDestroyResponseFlag
00024 {
00025    DtDRExecDestroyed,
00026    DtDRExecDoesNotExist,
00027    DtDRFederatesJoined,
00028    DtDRWaiting   
00029 };
00030 
00031 class DT_DLL_LRC DtDestroyResponseMsg : public DtRtiMsg
00032 {
00033 public:
00034 
00036    DtDestroyResponseMsg(DtBufferPtr buffer = DtUSE_INTERNAL_BUFFER);
00037 
00038    DtDestroyResponseMsg(const char* fedExName,
00039       DtDestroyResponseFlag flag,
00040       DtBufferPtr buffer = DtUSE_INTERNAL_BUFFER);
00041 
00043    DtDestroyResponseMsg(const DtNetDestroyResponseMsg* netRepMsg,
00044       DtBufferPtr buffer = DtUSE_INTERNAL_BUFFER);
00045 
00047    virtual DtRtiMsg* clone(bool copy = true) const; 
00048 
00050    virtual ~DtDestroyResponseMsg();
00051 
00053    virtual void set(const char* fedExName, DtDestroyResponseFlag flag);
00054 
00056    void setResponseFlag(DtDestroyResponseFlag flag);
00057    DtDestroyResponseFlag responseFlag() const;
00058 
00060    virtual void setFullFedExName(const MAKRti::DtString& name);
00061    virtual const MAKRti::DtString fullFedExName() const;
00062 
00064    virtual void printData(DtLogicalTimeFactory* logicalTimeFactory) const;
00065 
00066 public:
00067 
00069    static DtRtiMsg* create(const DtNetMsgHeader* initial,
00070       DtBufferPtr buffer = DtUSE_INTERNAL_BUFFER);
00071 
00073    static DtRtiMsg* create(DtBufferPtr buffer = DtUSE_INTERNAL_BUFFER);
00074 
00076    static void addCallback(DtConnectionMgr *conn,
00077       DtDestroyResponseCb cb, void *usr);
00078    static void removeCallback(DtConnectionMgr *conn,
00079       DtDestroyResponseCb cb, void *usr);
00080 
00081 protected:
00082 
00084    virtual DtNetDestroyResponseMsg* netDestroyResponseMsg();
00085    virtual const DtNetDestroyResponseMsg* netDestroyResponseMsg() const;
00086 
00088    virtual DtRtiMsgKind internalDtRtiMsgKind();
00089 
00091    virtual int minSize() const;
00092 
00094    virtual DtDestroyResponseMsg* self() const;
00095 };
00096 
00097 
00098 inline DtDestroyResponseMsg* DtDestroyResponseMsg::self() const
00099 {
00100    return const_cast<DtDestroyResponseMsg*>( this );
00101 }
00102 
00103 #endif
00104 

Document ID: Generated on Thu Jun 14 14:15:04 EDT 2012 from SVN revision 116116
Copyright © 2005-2012 VT MÄK Inc. All Rights Reserved (www.mak.com)