Files
Upsilon/apps/node.h
Émilie Feral ac0fdeeca8 [apps] create an abstract class for node
Change-Id: I3a946df720c37ec2b087cf6131ea886da3e26c95
2016-11-10 17:26:07 +01:00

22 lines
407 B
C++

#ifndef APPS_NODE_H
#define APPS_NODE_H
class Node {
public:
constexpr Node(const char * label = nullptr, int numberOfChildren = 0) :
m_label(label),
m_numberOfChildren(numberOfChildren)
{
};
virtual const Node * children(int index) const = 0;
const char * label() const;
int numberOfChildren();
bool isNull();
protected:
const char * m_label;
int m_numberOfChildren;
};
#endif