The FortranCodeParser
Class Reference
Declaration
Included Headers
Base class
class | CodeParserInterface |
Abstract interface for code parsers. More... | |
Derived Classes
class | FortranCodeParserFixed |
class | FortranCodeParserFree |
Public Constructors Index
FortranCodeParser (FortranFormat format=FortranFormat::Unknown) | |
Public Destructor Index
~FortranCodeParser () override | |
Public Member Functions Index
void | parseCode (OutputCodeList &codeOutIntf, const QCString &scopeName, const QCString &input, SrcLangExt lang, bool stripCodeComments, bool isExampleBlock, const QCString &exampleName=QCString(), const FileDef *fileDef=nullptr, int startLine=-1, int endLine=-1, bool inlineFragment=FALSE, const MemberDef *memberDef=nullptr, bool showLineNumbers=TRUE, const Definition *searchCtx=nullptr, bool collectXRefs=TRUE) override |
Parses a source file or fragment with the goal to produce highlighted and cross-referenced output. More... | |
void | resetCodeParserState () override |
Resets the state of the code parser. More... | |
Private Member Attributes Index
std::unique_ptr< Private > | p |
Definition at line 29 of file fortrancode.h.
Public Constructors
FortranCodeParser()
|
Declaration at line 32 of file fortrancode.h, definition at line 1460 of file fortrancode.l.
References Debug::isFlagSet, Debug::Lex_fortrancode, p and resetCodeParserState.
Referenced by FortranCodeParserFixed::FortranCodeParserFixed and FortranCodeParserFree::FortranCodeParserFree.
Public Destructor
~FortranCodeParser()
|
Declaration at line 33 of file fortrancode.h, definition at line 1470 of file fortrancode.l.
Reference p.
Public Member Functions
parseCode()
| virtual |
Parses a source file or fragment with the goal to produce highlighted and cross-referenced output.
- Parameters
-
[in] codeOutList interface for writing the result.
[in] scopeName Name of scope to which the code belongs.
[in] input Actual code in the form of a string
[in] lang The programming language of the code fragment.
[in] stripCodeComments signals whether or not for the code block the doxygen comments should be stripped.
[in] isExampleBlock TRUE iff the code is part of an example.
[in] exampleName Name of the example.
[in] fileDef File definition to which the code is associated.
[in] startLine Starting line in case of a code fragment.
[in] endLine Ending line of the code fragment.
[in] inlineFragment Code fragment that is to be shown inline as part of the documentation.
[in] memberDef Member definition to which the code is associated (non null in case of an inline fragment for a member).
[in] showLineNumbers if set to TRUE and also fileDef is not 0, line numbers will be added to the source fragment
[in] searchCtx context under which search data has to be stored.
[in] collectXRefs collect cross-reference relations.
Declaration at line 36 of file fortrancode.h, definition at line 1485 of file fortrancode.l.
References checkContLines, Config_getBool, Config_getInt, convertNameToFile, countLines, createFileDef, QCString::data, endCodeLine, FALSE, FileDef::fileName, QCString::isEmpty, Debug::Lex_fortrancode, p, qPrint, recognizeFixedForm, setCurrentDoc, startCodeLine and OutputCodeList::stripCodeComments.
resetCodeParserState()
| virtual |
Resets the state of the code parser.
Since multiple code fragments can together form a single example, an explicit function is used to reset the code parser state.
- See Also
Declaration at line 52 of file fortrancode.h, definition at line 1475 of file fortrancode.l.
Referenced by FortranCodeParser.
Private Member Attributes
p
|
Definition at line 56 of file fortrancode.h.
Referenced by FortranCodeParser, parseCode, resetCodeParserState and ~FortranCodeParser.
The documentation for this class was generated from the following files:
Generated via doxygen2docusaurus by Doxygen 1.14.0.