Doxygen
Loading...
Searching...
No Matches
ClangTUParser Class Reference

Clang parser object for a single translation unit, which consists of a source file and the directly or indirectly included headers. More...

#include <src/clangparser.h>

Classes

class  Private
 

Public Member Functions

 ClangTUParser (const ClangParser &parser, const FileDef *fd)
 
virtual ~ClangTUParser ()
 
void parse ()
 Parse the file given at construction time as a translation unit This file should already be preprocessed by doxygen preprocessor at the time of calling.
 
void switchToFile (const FileDef *fd)
 Switches to another file within the translation unit started with start().
 
StringVector filesInSameTU () const
 Returns the list of files for this translation unit.
 
std::string lookup (uint32_t line, const char *symbol)
 Looks for symbol which should be found at line.
 
void writeSources (OutputCodeList &ol, const FileDef *fd)
 writes the syntax highlighted source code for a file
 

Private Member Functions

void detectFunctionBody (const char *s)
 
void writeLineNumber (OutputCodeList &ol, const FileDef *fd, uint32_t line, bool writeLineAnchor)
 
void codifyLines (OutputCodeList &ol, const FileDef *fd, const char *text, uint32_t &line, uint32_t &column, const char *fontClass=nullptr)
 
void writeMultiLineCodeLink (OutputCodeList &ol, const FileDef *fd, uint32_t &line, uint32_t &column, const Definition *d, const char *text)
 
void linkIdentifier (OutputCodeList &ol, const FileDef *fd, uint32_t &line, uint32_t &column, const char *text, int tokenIndex)
 
void linkMacro (OutputCodeList &ol, const FileDef *fd, uint32_t &line, uint32_t &column, const char *text)
 
void linkInclude (OutputCodeList &ol, const FileDef *fd, uint32_t &line, uint32_t &column, const char *text)
 
void codeFolding (OutputCodeList &ol, const Definition *d, uint32_t line)
 
void endCodeFold (OutputCodeList &ol, uint32_t line)
 

Private Attributes

std::unique_ptr< Privatep
 

Detailed Description

Clang parser object for a single translation unit, which consists of a source file and the directly or indirectly included headers.

Definition at line 24 of file clangparser.h.

Constructor & Destructor Documentation

◆ ClangTUParser()

ClangTUParser::ClangTUParser ( const ClangParser & parser,
const FileDef * fd )

Definition at line 968 of file clangparser.cpp.

968 : p(std::make_unique<Private>())
969{
970}
std::unique_ptr< Private > p
Definition clangparser.h:75

References p.

◆ ~ClangTUParser()

ClangTUParser::~ClangTUParser ( )
virtual

Definition at line 972 of file clangparser.cpp.

973{
974}

Member Function Documentation

◆ codeFolding()

void ClangTUParser::codeFolding ( OutputCodeList & ol,
const Definition * d,
uint32_t line )
private

◆ codifyLines()

void ClangTUParser::codifyLines ( OutputCodeList & ol,
const FileDef * fd,
const char * text,
uint32_t & line,
uint32_t & column,
const char * fontClass = nullptr )
private

◆ detectFunctionBody()

void ClangTUParser::detectFunctionBody ( const char * s)
private

◆ endCodeFold()

void ClangTUParser::endCodeFold ( OutputCodeList & ol,
uint32_t line )
private

◆ filesInSameTU()

StringVector ClangTUParser::filesInSameTU ( ) const

Returns the list of files for this translation unit.

◆ linkIdentifier()

void ClangTUParser::linkIdentifier ( OutputCodeList & ol,
const FileDef * fd,
uint32_t & line,
uint32_t & column,
const char * text,
int tokenIndex )
private

◆ linkInclude()

void ClangTUParser::linkInclude ( OutputCodeList & ol,
const FileDef * fd,
uint32_t & line,
uint32_t & column,
const char * text )
private

◆ linkMacro()

void ClangTUParser::linkMacro ( OutputCodeList & ol,
const FileDef * fd,
uint32_t & line,
uint32_t & column,
const char * text )
private

◆ lookup()

std::string ClangTUParser::lookup ( uint32_t line,
const char * symbol )

Looks for symbol which should be found at line.

returns a clang unique reference to the symbol.

Definition at line 976 of file clangparser.cpp.

977{
978 return std::string();
979}

◆ parse()

void ClangTUParser::parse ( )

Parse the file given at construction time as a translation unit This file should already be preprocessed by doxygen preprocessor at the time of calling.

Definition at line 964 of file clangparser.cpp.

965{
966}

Referenced by parseFile().

◆ switchToFile()

void ClangTUParser::switchToFile ( const FileDef * fd)

Switches to another file within the translation unit started with start().

Parameters
[in]fdThe file definition with the name of the file to switch to.

Definition at line 960 of file clangparser.cpp.

961{
962}

Referenced by parseFile().

◆ writeLineNumber()

void ClangTUParser::writeLineNumber ( OutputCodeList & ol,
const FileDef * fd,
uint32_t line,
bool writeLineAnchor )
private

◆ writeMultiLineCodeLink()

void ClangTUParser::writeMultiLineCodeLink ( OutputCodeList & ol,
const FileDef * fd,
uint32_t & line,
uint32_t & column,
const Definition * d,
const char * text )
private

◆ writeSources()

void ClangTUParser::writeSources ( OutputCodeList & ol,
const FileDef * fd )

writes the syntax highlighted source code for a file

Parameters
[out]olThe output generator list to write to.
[in]fdThe file to write sources for.

Member Data Documentation

◆ p

std::unique_ptr<Private> ClangTUParser::p
private

Definition at line 75 of file clangparser.h.

Referenced by ClangTUParser().


The documentation for this class was generated from the following files: