#ifndef __loc_tool_hpp__
#define __loc_tool_hpp__
#include "loc_message.h"
struct ant;
struct message_locinfo;
/*
struct loc_tool
{
	//将基础信息送入工具类，目前考虑各种算法输出不同的实时日志
	virtual void on_loc_message(ant*a, const message_locinfo&m){};
	virtual std::vector<point> calc_location(const std::vector<loc_message>&locm)=0;
	virtual int index()
	{
		return -1;
	}
	virtual ~loc_tool(){}
};

struct loc_tool_tdoa_3_base:loc_tool
{
	virtual std::vector<point> calc_location(const std::vector<loc_message>&locm);
	virtual int index();
};

struct loc_tool_tdoa_2_base:loc_tool
{
	virtual std::vector<point> calc_location(const std::vector<loc_message>&locm);
	virtual int index();
};

struct loc_tool_tdoa_1_base:loc_tool
{
	virtual std::vector<point> calc_location(const std::vector<loc_message>&locm);
	virtual int index();
};

struct loc_tool_tof_3_base:loc_tool
{
	virtual std::vector<point> calc_location(const std::vector<loc_message>&locm);
	virtual int index();
};

struct loc_tool_tof_2_base:loc_tool
{
	virtual std::vector<point> calc_location(const std::vector<loc_message>&locm);
	virtual int index();
};

struct loc_tool_tof_1_base:loc_tool
{
	virtual std::vector<point> calc_location(const std::vector<loc_message>&locm);
	virtual void on_loc_message(ant*a, const message_locinfo&m);
	virtual int index();
};

struct loc_tool_main:loc_tool
{
	loc_tool* g_tool[6];

	loc_tool_main();
	~loc_tool_main();
	void set_tool(loc_tool*tool);
	loc_tool* get_tool(int index);

	void on_loc_message(ant*a, const message_locinfo&m);
	std::vector<point> calc_location(const std::vector<loc_message>&locm);
};
*/
struct loc_tool
{
	virtual std::vector<point> calc_location(std::vector<loc_message>&locm)=0;
	virtual int index()
	{
		return -1;
	}
	virtual ~loc_tool(){}
};

struct loc_tool_tdoa_3_base:loc_tool
{
	virtual std::vector<point> calc_location(std::vector<loc_message>&locm);
	virtual int index();
};

struct loc_tool_tdoa_2_base:loc_tool
{
	virtual std::vector<point> calc_location(std::vector<loc_message>&locm);
	virtual int index();
};

struct loc_tool_tdoa_1_base:loc_tool
{
	virtual std::vector<point> calc_location(std::vector<loc_message>&locm);
	virtual int index();
};

struct loc_tool_tof_3_base:loc_tool
{
	virtual std::vector<point> calc_location(std::vector<loc_message>&locm);
	virtual int index();
};

struct loc_tool_tof_2_base:loc_tool
{
	virtual std::vector<point> calc_location(std::vector<loc_message>&locm);
	virtual int index();
};

struct loc_tool_tof_1_base:loc_tool
{
	virtual std::vector<point> calc_location(std::vector<loc_message>&locm);
	virtual int index();
};

struct loc_tool_main:loc_tool
{
	static loc_tool* g_tool[6];
	loc_tool_main();
	~loc_tool_main();
	static void set_tool(loc_tool*tool);
	std::vector<point> calc_location( std::vector<loc_message>&locm);
};


#endif

