浏览该文件的文档.
57 const std::shared_ptr<Entry> &root,
119 bool inlineFragment=
FALSE,
121 bool showLineNumbers=
TRUE,
123 bool collectXRefs=
TRUE
192 const auto &parserIt =
m_parsers.find(parserName.
str());
242 if (ext.
isEmpty()) ext=
".no_extension";
bool registerExtension(const QCString &extension, const QCString &parserName)
Registers a file extension with a parser with name parserName.
virtual void parseInput(const QCString &fileName, const char *fileBuf, const std::shared_ptr< Entry > &root, ClangTUParser *clangParser)=0
Parses a single input file with the goal to build an Entry tree.
ParserManager(OutlineParserFactory outlineParserFactory, CodeParserFactory codeParserFactory)
Create the parser manager
The common base class of all entity definitions found in the sources.
This file contains a number of basic enums and types.
ParserPair m_defaultParsers
uint length() const
Returns the length of the string, not counting the 0-terminator.
bool isEmpty() const
Returns TRUE iff the string is empty
ParserPair & getParsers(const QCString &extension)
Abstract interface for code parsers.
std::map< std::string, ParserPair > m_parsers
SrcLangExt
Language as given by extension
virtual void parsePrototype(const QCString &text)=0
Callback function called by the comment block scanner.
A model of a class/file/namespace member symbol.
QCString left(size_t len) const
std::unique_ptr< OutlineParserInterface > getOutlineParser(const QCString &extension)
Gets the interface to the parser associated with a given extension.
virtual bool needsPreprocessing(const QCString &extension) const =0
Returns TRUE if the language identified by extension needs the C preprocessor to be run before feed t...
CodeParserFactory & getCodeParserFactory(const QCString &extension)
Get the factory for create code parser objects with a given extension.
std::function< std::unique_ptr< CodeParserInterface >()> CodeParserFactory
virtual ~CodeParserInterface()
std::unique_ptr< CodeParserInterface > getCodeParser(const QCString &extension)
Gets the interface to the parser associated with a given extension.
virtual 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)=0
Parses a source file or fragment with the goal to produce highlighted and cross-referenced output.
Represents an unstructured piece of information, about an entity found in the sources.
virtual ~OutlineParserInterface()
std::function< std::unique_ptr< OutlineParserInterface >()> OutlineParserFactory
Output interface for code parser.
void registerParser(const QCString &name, OutlineParserFactory outlineParserFactory, CodeParserFactory codeParserFactory)
Registers an additional parser.
Abstract interface for outline parsers.
Manages programming language parsers.
const char * data() const
Returns a pointer to the contents of the string in the form of a 0-terminated C string
std::map< std::string, ParserPair & > m_extensions
Clang parser object for a single translation unit, which consists of a source file and the directly o...
A model of a file symbol.
virtual void resetCodeParserState()=0
Resets the state of the code parser.
CodeParserFactory codeParserFactory
OutlineParserFactory outlineParserFactory
QCString getParserName(const QCString &extension)
Gets the name of the parser associated with given extension.
ParserPair(OutlineParserFactory opf, CodeParserFactory cpf, const QCString &pn)
This is an alternative implementation of QCString.