Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018 #include "ProtocolMessage.h"
00019 #include <string.h>
00020
00021
00022
00023
00024
00025
00026
00027 CProtocolMessage::CProtocolMessage() :
00028 m_uiMessageId(0),
00029 m_ucMessageLength(0),
00030 m_ucMessageState(0),
00031 m_bRTRFlag(false),
00032 m_fTime(0.0),
00033 m_iModuleId(0)
00034 {
00035 }
00036
00037 CProtocolMessage::CProtocolMessage(const CProtocolMessage& rclProtocolMessage) :
00038 m_uiMessageId(rclProtocolMessage.m_uiMessageId),
00039 m_ucMessageLength(rclProtocolMessage.m_ucMessageLength),
00040 m_ucMessageState(rclProtocolMessage.m_ucMessageState),
00041 m_bRTRFlag(rclProtocolMessage.m_bRTRFlag),
00042 m_fTime(rclProtocolMessage.m_fTime),
00043 m_iModuleId(rclProtocolMessage.m_iModuleId)
00044 {
00045 memcpy(m_aucMessageData, rclProtocolMessage.m_aucMessageData, m_ucMessageLength);
00046 }
00047
00048 CProtocolMessage::~CProtocolMessage()
00049 {
00050 }
00051
00052
00053
00054
00055
00056
00057
00058 CProtocolMessage& CProtocolMessage::operator=(const CProtocolMessage& rclProtocolMessage)
00059 {
00060 m_uiMessageId = rclProtocolMessage.m_uiMessageId;
00061 m_ucMessageLength = rclProtocolMessage.m_ucMessageLength;
00062 m_ucMessageState = rclProtocolMessage.m_ucMessageState;
00063 m_bRTRFlag = rclProtocolMessage.m_bRTRFlag;
00064 m_fTime = rclProtocolMessage.m_fTime;
00065 m_iModuleId = rclProtocolMessage.m_iModuleId;
00066 memcpy(m_aucMessageData, rclProtocolMessage.m_aucMessageData, m_ucMessageLength);
00067 return *this;
00068 }
00069