merge the formfield patch from ooo-build
[ooovba.git] / autodoc / source / parser / cpp / tokintpr.hxx
blobab42f54deb61b4d5bb1d3058cbad65b7f1751243
1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 *
5 * Copyright 2008 by Sun Microsystems, Inc.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * $RCSfile: tokintpr.hxx,v $
10 * $Revision: 1.4 $
12 * This file is part of OpenOffice.org.
14 * OpenOffice.org is free software: you can redistribute it and/or modify
15 * it under the terms of the GNU Lesser General Public License version 3
16 * only, as published by the Free Software Foundation.
18 * OpenOffice.org is distributed in the hope that it will be useful,
19 * but WITHOUT ANY WARRANTY; without even the implied warranty of
20 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 * GNU Lesser General Public License version 3 for more details
22 * (a copy is included in the LICENSE file that accompanied this code).
24 * You should have received a copy of the GNU Lesser General Public License
25 * version 3 along with OpenOffice.org. If not, see
26 * <http://www.openoffice.org/license.html>
27 * for a copy of the LGPLv3 License.
29 ************************************************************************/
31 #ifndef ADC_CPP_TOKINTPR_HXX
32 #define ADC_CPP_TOKINTPR_HXX
36 // USED SERVICES
37 // BASE CLASSES
38 #include <all_toks.hxx>
39 // COMPONENTS
40 // PARAMETERS
42 namespace cpp {
46 #define DECL_TOK_HANDLER(token) \
47 void Hdl_##token( \
48 const Tok_##token & i_rTok ) { Call_Handler(i_rTok); }
50 class TokenInterpreter
52 public:
53 virtual ~TokenInterpreter() {}
55 DECL_TOK_HANDLER(Identifier)
56 DECL_TOK_HANDLER(Operator)
57 DECL_TOK_HANDLER(operator)
58 DECL_TOK_HANDLER(class)
59 DECL_TOK_HANDLER(struct)
60 DECL_TOK_HANDLER(union)
61 DECL_TOK_HANDLER(enum)
62 DECL_TOK_HANDLER(typedef)
63 DECL_TOK_HANDLER(public)
64 DECL_TOK_HANDLER(protected)
65 DECL_TOK_HANDLER(private)
66 DECL_TOK_HANDLER(template)
67 DECL_TOK_HANDLER(virtual)
68 DECL_TOK_HANDLER(friend)
69 DECL_TOK_HANDLER(Tilde)
70 DECL_TOK_HANDLER(const)
71 DECL_TOK_HANDLER(volatile)
72 DECL_TOK_HANDLER(extern)
73 DECL_TOK_HANDLER(static)
74 DECL_TOK_HANDLER(mutable)
75 DECL_TOK_HANDLER(register)
76 DECL_TOK_HANDLER(inline)
77 DECL_TOK_HANDLER(explicit)
78 DECL_TOK_HANDLER(namespace)
79 DECL_TOK_HANDLER(using)
80 DECL_TOK_HANDLER(throw)
81 DECL_TOK_HANDLER(SwBracket_Left)
82 DECL_TOK_HANDLER(SwBracket_Right)
83 DECL_TOK_HANDLER(ArrayBracket_Left)
84 DECL_TOK_HANDLER(ArrayBracket_Right)
85 DECL_TOK_HANDLER(Bracket_Left)
86 DECL_TOK_HANDLER(Bracket_Right)
87 DECL_TOK_HANDLER(DoubleColon)
88 DECL_TOK_HANDLER(Semicolon)
89 DECL_TOK_HANDLER(Comma)
90 DECL_TOK_HANDLER(Colon)
91 DECL_TOK_HANDLER(Assign)
92 DECL_TOK_HANDLER(Less)
93 DECL_TOK_HANDLER(Greater)
94 DECL_TOK_HANDLER(Asterix)
95 DECL_TOK_HANDLER(AmpersAnd)
96 DECL_TOK_HANDLER(Ellipse)
97 DECL_TOK_HANDLER(typename)
98 DECL_TOK_HANDLER(DefineName)
99 DECL_TOK_HANDLER(MacroName)
100 DECL_TOK_HANDLER(MacroParameter)
101 DECL_TOK_HANDLER(PreProDefinition)
102 DECL_TOK_HANDLER(BuiltInType)
103 DECL_TOK_HANDLER(TypeSpecializer)
104 DECL_TOK_HANDLER(Constant)
106 protected:
107 virtual void Call_Handler(
108 const cpp::Token & i_rTok ) = 0;
111 #undef DECL_TOK_HANDLER
114 // IMPLEMENTATION
117 } // namespace cpp
120 #endif