-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDuple.java
More file actions
35 lines (29 loc) · 778 Bytes
/
Duple.java
File metadata and controls
35 lines (29 loc) · 778 Bytes
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
/* This class stored a pair of values:
- front is a reference to the first node in a linked list
- count is the number of nodes in the list
This class allows method findMatching in class QuadrantTree to
return two values: a list and the number of nodes in the list */
public class Duple {
private ListNode<QTreeNode> front;
private int count;
public Duple () {
front = null;
count = 0;
}
public Duple (ListNode<QTreeNode> first, int size) {
front = first;
count = size;
}
public ListNode<QTreeNode> getFront() {
return front;
}
public int getCount() {
return count;
}
public void setFront (ListNode<QTreeNode> first) {
front = first;
}
public void setCount (int total) {
count = total;
}
}