<commit_before>
#include "NFCNet.h"
#include <thread>
#include <string>
#include <processthreadsapi.h>
#pragma comment(lib,"ws2_32.lib")
#pragma comment(lib,"NFNet_d.lib")

class TestServerClass
{
public:
	TestServerClass()
	{
		pNet = new NFCNet(this, &TestServerClass::ReciveHandler, &TestServerClass::EventHandler);
		pNet->Initialization(1000, 8088);
	}

	void ReciveHandler(const int nSockIndex, const int nMsgID, const char* msg, const uint32_t nLen)
	{
		std::string str;
		str.assign(msg, nLen);

		//pNet->SendMsgWithOutHead(nMsgID, msg, nLen, nSockIndex);
		std::cout << " fd: " << nSockIndex << " msg_id: " << nMsgID /*<<  " data: " << str*/ << " thread_id: " << GetCurrentThreadId() << std::endl;
	}

	void EventHandler(const int nSockIndex, const NF_NET_EVENT e, NFINet* p)
	{
		std::cout << " fd: " << nSockIndex << " event_id: " << e << " thread_id: " << std::this_thread::get_id() << std::endl;
	}

	void Execute()
	{
		pNet->Execute();
	}

protected:
	NFINet* pNet;
};

int main(int argc, char** argv)
{
	TestServerClass x;

	while (1)
	{
		x.Execute();
	}

	return 0;
}
<commit_msg>Add sending message to client in server<commit_after>
#include "NFCNet.h"
#include <thread>
#include <string>
#include <processthreadsapi.h>
#pragma comment(lib,"ws2_32.lib")
#pragma comment(lib,"NFNet_d.lib")

class TestServerClass
{
public:
	TestServerClass()
	{
		pNet = new NFCNet(this, &TestServerClass::ReciveHandler, &TestServerClass::EventHandler);
		pNet->Initialization(1000, 8088);
	}

	void ReciveHandler(const int nSockIndex, const int nMsgID, const char* msg, const uint32_t nLen)
	{
		std::string str;
		str.assign(msg, nLen);

		pNet->SendMsgWithOutHead(nMsgID, msg, nLen, nSockIndex);
		std::cout << " fd: " << nSockIndex << " msg_id: " << nMsgID /*<<  " data: " << str*/ << " thread_id: " << GetCurrentThreadId() << std::endl;
	}

	void EventHandler(const int nSockIndex, const NF_NET_EVENT e, NFINet* p)
	{
		std::cout << " fd: " << nSockIndex << " event_id: " << e << " thread_id: " << std::this_thread::get_id() << std::endl;
	}

	void Execute()
	{
		pNet->Execute();
	}

protected:
	NFINet* pNet;
};

int main(int argc, char** argv)
{
	TestServerClass x;

	while (1)
	{
		x.Execute();
	}

	return 0;
}

{'fraction_non_alphanumeric': 0.16695501730103807, 'fraction_numerical': 0.012975778546712802, 'mean_word_length': 3.808731808731809, 'pattern_counts': {'":': 0, '<': 73, '<?xml version=': 0, '>': 15, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4981514', 'n_tokens_mistral': 940, 'n_tokens_neox': 883, 'n_words': 186}