//
// Created by huli on 2022/12/30.
//

#include "network_message.h"

Network_message::Network_message()
{

}
Network_message::Network_message(std::string message_buf, int socket_id, std::string ip, int port)
{
	m_message_buf = message_buf;
	m_socket_id = socket_id;
	m_ip = ip;
	m_port = port;
}
Network_message::Network_message(std::string message_buf, int socket_id)
{
	m_message_buf = message_buf;
	m_socket_id = socket_id;
	m_ip.clear();
	m_port = 0;
}


Network_message::~Network_message()
{

}


void Network_message::reset(std::string message_buf, int socket_id, std::string ip, int port)
{
	m_message_buf = message_buf;
	m_socket_id = socket_id;
	m_ip = ip;
	m_port = port;
}
void Network_message::reset(std::string message_buf, int socket_id)
{
	m_message_buf = message_buf;
	m_socket_id = socket_id;
	m_ip.clear();
	m_port = 0;
}







