forked from douglascraigschmidt/CPlusPlus
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathComponent_Node.cpp
More file actions
44 lines (35 loc) · 750 Bytes
/
Copy pathComponent_Node.cpp
File metadata and controls
44 lines (35 loc) · 750 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
/* -*- C++ -*- */
#ifndef _COMPONENT_NODE_CPP_
#define _COMPONENT_NODE_CPP_
#include <stdexcept>
#include "Component_Node.h"
#include "Visitor.h"
// Dtor
Component_Node::~Component_Node (void)
{
}
int
Component_Node::item (void) const
{
throw Invalid_Function_Call ("Component_Node::item() called improperly");
return 0;
}
// default left is to return a null pointer
Component_Node *
Component_Node::left (void) const
{
return 0;
}
// default right is to return a null pointer
Component_Node *
Component_Node::right (void) const
{
return 0;
}
// accept a visitor
void
Component_Node::accept (Visitor &visitor) const
{
throw Invalid_Function_Call ("Component_Node::accept() called improperly");
}
#endif /* _COMPONENT_NODE_CPP_ */