-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathAttribute.java
More file actions
83 lines (68 loc) · 1.23 KB
/
Attribute.java
File metadata and controls
83 lines (68 loc) · 1.23 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
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
import java.util.Set;
/**
* Attribute class, for handling our attributes (e.g. Patrons, Wait time, etc.)
* The value corresponding to an Attribute is a string
*/
/**
* @author Chris Erlendson
*
*/
public class Attribute {
/* numerical reference to attribute (4 refers to Patrons, for example) */
private int col;
/* refers to value this attribute took on (e.g. "None", "Some", or "Full") */
private String value;
/* refers to what the class is; will mostly be null unless leaf node in tree */
private String classifier;
private Set<String> posValues;
public Attribute()
{
}
public Attribute(String v)
{
value = v;
classifier = null;
}
public Attribute(String v, String cls)
{
value = v;
classifier = cls;
}
public int getCol()
{
return col;
}
public void setCol(int c)
{
col = c;
}
public String getValue()
{
return value;
}
public String setValue(String v)
{
value = v;
return value;
}
public Set<String> getPosValues()
{
return posValues;
}
public void setPosValues(Set<String> values)
{
posValues = values;
}
public String getCls()
{
return classifier;
}
public void setCls(String cls)
{
classifier = cls;
}
public String toString()
{
return value;
}
}