-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy patharff_instance.h
More file actions
executable file
·64 lines (52 loc) · 1.29 KB
/
Copy patharff_instance.h
File metadata and controls
executable file
·64 lines (52 loc) · 1.29 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
#ifndef __INCLUDED_ARFF_INSTANCE_H__
#define __INCLUDED_ARFF_INSTANCE_H__
/**
* @file arff_instance.h
* @brief Contains the 'ArffInstance' class
*/
#include <vector>
#include "arff_utils.h"
#include "arff_value.h"
/**
* @class ArffInstance arff_instance.h
* @brief Class to represent one single instance of data
*/
class ArffInstance
{
public:
/**
* @brief Constructor
*/
ArffInstance();
/**
* @brief Destructor
*/
~ArffInstance();
/**
* @brief Number of elements in the instance
* @return number
*/
int32 size()const;
/**
* @brief Add an instance data into the list
* @param val the data to be added
*
* Note that this pointer will be owned by this class from here onwards!
*/
void add(ArffValue* val);
/**
* @brief Get an instance data at the given location
* @param idx location (starts from 0)
* @return data
*
* Note that this pointer will still be owned by this class!
*/
ArffValue* get(int idx) const;
private:
/** instance size */
int32 m_size;
/** instance data */
std::vector<ArffValue*> m_data;
};
/* DO NOT WRITE ANYTHING BELOW THIS LINE!!! */
#endif // __INCLUDED_ARFF_INSTANCE_H__