blob: 8a28d7a64a9f5fd871d7a54e350a3ebb250c8e31 (
plain)
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
|
/**********************************************
License: BSD
Project Webpage: http://cajun-jsonapi.sourceforge.net/
Author: Terry Caton
***********************************************/
#pragma once
#include "elements.h"
namespace json
{
class Visitor
{
public:
virtual ~Visitor() {}
virtual void Visit(Array& array) = 0;
virtual void Visit(Object& object) = 0;
virtual void Visit(Number& number) = 0;
virtual void Visit(String& string) = 0;
virtual void Visit(Boolean& boolean) = 0;
virtual void Visit(Null& null) = 0;
};
class ConstVisitor
{
public:
virtual ~ConstVisitor() {}
virtual void Visit(const Array& array) = 0;
virtual void Visit(const Object& object) = 0;
virtual void Visit(const Number& number) = 0;
virtual void Visit(const String& string) = 0;
virtual void Visit(const Boolean& boolean) = 0;
virtual void Visit(const Null& null) = 0;
};
} // End namespace
|