metadata.h

来自「一个简单灵活的数据挖掘实验平台」· C头文件 代码 · 共 33 行

H
33
字号
#ifndef _METADATA_H
#define _METADATA_H
#include <string>
#include <vector>
#include "Attribute.h"
using namespace std;
class MetaData
{
public:
	MetaData();
	MetaData(const MetaData& md);
	~MetaData();

	string get_name() const;
	void set_name(const string& name);
	int size() const;
	
	//: gets the attribute by index
	Attribute operator[](int index) const;

	//: if index is with out the range of attributes index, append it the the end by default
	void insert(Attribute* attr,int index);
	void append(Attribute* attr);

	vector<Attribute*> target() const;
	void add_target(Attribute* attr);
	void add_target(int index);
private:
	string _name; //:name of the relation table the mining data specification belongs to
	vector<Attribute*> _attributes;
	vector<Attribute*> _target;
};
#endif

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?