MAK RTIspy API Documentation for HLA 1.3
wwwFederateStateRspMsg.h
Go to the documentation of this file.
00001 /*********************************************************************
00002 ** Copyright (c) 2006 MaK Technologies, Inc.
00003 ** All rights reserved.
00004 *********************************************************************/
00005 /*********************************************************************
00006 ** $RCSfile: wwwFederateStateRspMsg.h,v $ $Revision: 1.8 $ $State: Exp $
00007 *********************************************************************/
00008 
00011 
00012 #ifndef DtWwwFederateStateRspMsg_H_
00013 #define DtWwwFederateStateRspMsg_H_
00014 
00015 #include "rtiMsConfig.h"
00016 #include "rtiMsg.h"
00017 #include "netWwwFederateStateMsg.h"
00018 
00019 class DtConnectionMgr;
00020 class DtWwwFederateStateRspMsg;
00021 class DtLogicalTimeFactory;
00022 typedef void (*DtWwwFederateStateResponseCb)(const DtWwwFederateStateRspMsg& inter, void* usr);
00023 
00024 
00025 class DT_DLL_LRC DtWwwFederateStateRspMsg : public DtRtiMsg
00026 {
00027 
00028 public:
00029    
00031    DtWwwFederateStateRspMsg(DtBufferPtr buffer = DtUSE_INTERNAL_BUFFER);
00032 
00034    DtWwwFederateStateRspMsg( unsigned long connId, unsigned long federationHandle,
00035       unsigned long federateHandle, unsigned long responseType, const MAKRti::DtString& xml,
00036       bool replaceExistingNotAppend = true, bool isStateFragment = false,
00037       DtBufferPtr buffer = DtUSE_INTERNAL_BUFFER );
00038 
00040    DtWwwFederateStateRspMsg(const DtNetWwwFederateStateMsg* netRep,
00041       DtBufferPtr buffer = DtUSE_INTERNAL_BUFFER);
00042 
00044    virtual ~DtWwwFederateStateRspMsg();
00045 
00047    virtual DtRtiMsg* clone(bool copy = true) const; 
00048 
00050    virtual unsigned long sourceConnectionId() const;
00051    virtual void setSourceConnectionId( unsigned long connId );
00052    
00054    virtual unsigned long sourceFederateHandle() const;
00055    virtual void setSourceFederateHandle( unsigned long handle );
00056    
00058    virtual unsigned long responseType() const;
00059    virtual void setResponseType( unsigned long responseType );
00060 
00062    virtual const MAKRti::DtString& payload() const; 
00063    virtual void setPayload( const MAKRti::DtString& xml );
00064 
00068    virtual bool isReplacementNotAppend() const;
00069    virtual void setIsReplacementNotAppend( bool replacesExistingState = true );
00070 
00074    virtual bool isComplete() const;
00075    virtual void setIsComplete( bool complete = true );
00076 
00078    virtual void printData(DtLogicalTimeFactory* logicalTimeFactory) const;
00079 
00080 
00081 public:
00082 
00084    static DtRtiMsg* create(const DtNetMsgHeader* initial,
00085       DtBufferPtr buffer = DtUSE_INTERNAL_BUFFER);
00086 
00087    static DtRtiMsg* create(DtBufferPtr buffer = DtUSE_INTERNAL_BUFFER);
00088 
00090    static void addCallback(DtConnectionMgr* conn, DtWwwFederateStateResponseCb cb, void* usr);
00091    static void removeCallback(DtConnectionMgr* conn, DtWwwFederateStateResponseCb cb, void* usr);
00092 
00093 protected:
00094 
00096    virtual DtNetWwwFederateStateMsg* netWwwFederateStateMsg();
00097    virtual const DtNetWwwFederateStateMsg* netWwwFederateStateMsg() const;
00098 
00100    virtual DtRtiMsgKind internalDtRtiMsgKind();
00101 
00103    virtual char* netMsgPayload();
00104 
00106    virtual int minSize() const;
00107 
00108 protected:
00109    
00111    MAKRti::DtString myXmlResponse;
00112 
00113 };
00114 
00115 #endif  //! DtWwwFederateStateRspMsg_H_
00116 

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)