-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathCategoryNode.cpp
More file actions
53 lines (41 loc) · 954 Bytes
/
CategoryNode.cpp
File metadata and controls
53 lines (41 loc) · 954 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
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
#include "CategoryNdoe.h"
CategoryNode::CategoryNode() {
this->data = new Category;
this->prev = NULL;
this->next = NULL;
this->productHead = NULL;
this->productTail = NULL;
}
Category* CategoryNode::getData() {
return data;
}
CategoryNode* CategoryNode::getPrev() {
return prev;
}
CategoryNode* CategoryNode::getNext() {
return next;
}
ProductNode* CategoryNode::getProductHead() {
return productHead;
}
ProductNode* CategoryNode::getProductTail() {
return productTail;
}
void CategoryNode::setData(Category* date) {
this->data = data;
}
void CategoryNode::setPrev(CategoryNode* ctg) {
prev = ctg;
}
void CategoryNode::setNext(CategoryNode* ctg) {
next = ctg;
}
void CategoryNode::setProductHead(ProductNode* product) {
productHead = product;
}
void CategoryNode::setProductTail(ProductNode* product) {
productTail = product;
}
void CategoryNode::show() {
cout << "CATEGORY " << "[" << this->data->getCtg() << "]" << endl;
}