doxygen
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 
29 {
30  public:
31  CCodeParser();
32  virtual ~CCodeParser();
33  void parseCode(CodeOutputInterface &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 setStartCodeLine(const bool inp);
50  private:
51  struct Private;
52  std::unique_ptr<Private> p;
53 };
54 
55 #endif
The common base class of all entity definitions found in the sources.
Definition: definition.h:76
A model of a class/file/namespace member symbol.
Definition: memberdef.h:45
A model of a file symbol.
Definition: filedef.h:73
void parseCode(CodeOutputInterface &codeOutIntf, const QCString &scopeName, const QCString &input, SrcLangExt lang, bool isExampleBlock, const QCString &exampleName=QCString(), const FileDef *fileDef=0, int startLine=-1, int endLine=-1, bool inlineFragment=FALSE, const MemberDef *memberDef=0, bool showLineNumbers=TRUE, const Definition *searchCtx=0, bool collectXRefs=TRUE)
Parses a source file or fragment with the goal to produce highlighted and cross-referenced output...
SrcLangExt
Language as given by extension.
Definition: types.h:41
Definition: code.h:28
This is an alternative implementation of QCString.
Definition: qcstring.h:108
Output interface for code parser.
Definition: outputgen.h:61
void resetCodeParserState()
Resets the state of the code parser.
Abstract interface for code parsers.
Definition: parserintf.h:83