00001 /******************************************************************************* 00002 ** Copyright (c) 1997 MaK Technologies, Inc. 00003 ** All rights reserved. 00004 *******************************************************************************/ 00005 00008 00009 #pragma once 00010 00011 #if DtHLA 00012 00013 #include "loggerControlDefines.h" 00014 #include <vl/hIntWEncDec.h> 00015 #include "lcPdu.h" 00016 00017 class DtLgrControlInteraction; 00018 class DT_DLL_LOGGERCONTROL DtExerciseConn; 00019 00020 00022 typedef void (*DtLgrControlInteractionCb)( DtLgrControlInteraction* inter, 00023 void* usr ); 00024 00028 class DT_DLL_LOGGERCONTROL DtLgrControlInteraction : public DtInteractionWithEncDec 00029 { 00030 public: 00031 00033 DtLgrControlInteraction(); 00034 00036 virtual ~DtLgrControlInteraction(); 00037 00039 DtLgrControlInteraction( const DtLgrControlInteraction& src ); 00040 00042 DtLgrControlInteraction& operator=( const DtLgrControlInteraction& src ); 00043 00045 virtual void printData() const; 00046 00048 virtual inline const DtLgrControlPdu* lcPdu() const { return myLcPdu; } 00049 virtual void setLcPdu( const DtLgrControlPdu& pdu ); 00050 virtual void setFromNetPacket( const DtNetPacket* pack ); 00051 00053 virtual inline const char* name() const { return "DtLgrControlInteraction"; } 00054 00055 public: 00056 00059 static DtInteraction* create(); 00060 00063 static void addCallback( DtExerciseConn* conn, 00064 DtLgrControlInteractionCb cb, void* usr ); 00065 static void removeCallback( DtExerciseConn* conn, 00066 DtLgrControlInteractionCb cb, void* usr ); 00067 00068 protected: 00069 virtual char* interactionClassToUse(DtExerciseConn* exConn) const; 00070 virtual DtInteractionDecoder* createDecoder(DtExerciseConn* exConn) const; 00071 virtual DtInteractionEncoder* createEncoder(DtExerciseConn* exConn) const; 00072 00073 00074 protected: 00075 DtLgrControlPdu* myLcPdu; 00076 }; 00077 00078 #endif //! DtHLA