Imported Upstream version 1.9.8
[platform/upstream/doxygen.git] / src / code.h
1 /******************************************************************************
2  *
3  *
4  *
5  * Copyright (C) 1997-2015 by Dimitri van Heesch.
6  *
7  * Permission to use, copy, modify, and distribute this software and its
8  * documentation under the terms of the GNU General Public License is hereby
9  * granted. No representations are made about the suitability of this software
10  * for any purpose. It is provided "as is" without express or implied warranty.
11  * See the GNU General Public License for more details.
12  *
13  * Documents produced by Doxygen are derivative works derived from the
14  * input used in their production; they are not affected by this license.
15  *
16  */
17
18 #ifndef CODE_H
19 #define CODE_H
20
21 #include "parserintf.h"
22
23 class FileDef;
24 class MemberDef;
25 class QCString;
26 class Definition;
27
28 class CCodeParser : public CodeParserInterface
29 {
30   public:
31     CCodeParser();
32     virtual ~CCodeParser();
33     void parseCode(OutputCodeList &codeOutIntf,
34                    const QCString &scopeName,
35                    const QCString &input,
36                    SrcLangExt lang,
37                    bool isExampleBlock,
38                    const QCString &exampleName=QCString(),
39                    const FileDef *fileDef=0,
40                    int startLine=-1,
41                    int endLine=-1,
42                    bool inlineFragment=FALSE,
43                    const MemberDef *memberDef=0,
44                    bool showLineNumbers=TRUE,
45                    const Definition *searchCtx=0,
46                    bool collectXRefs=TRUE
47                   );
48     void resetCodeParserState();
49     void setInsideCodeLine(bool inp);
50     bool insideCodeLine() const;
51   private:
52     struct Private;
53     std::unique_ptr<Private> p;
54 };
55
56 #endif