souffle  2.0.2-371-g6315b36
Public Member Functions | Static Public Member Functions | Private Member Functions | Private Attributes | Friends
souffle::DebugReport Class Reference

Class representing a HTML report, consisting of a list of sections. More...

#include <DebugReport.h>

Collaboration diagram for souffle::DebugReport:
Collaboration graph

Public Member Functions

void addCodeSection (std::string id, std::string title, std::string_view language, std::string_view prev, std::string_view curr)
 
void addSection (DebugReportSection section)
 
void addSection (std::string id, std::string title, std::string_view code)
 
void endSection (std::string currentSectionName, std::string currentSectionTitle)
 
void flush ()
 
void print (std::ostream &out) const
 Outputs a complete HTML document to the given stream, consisting of an index of all of the sections of the report, followed by the content of each section. More...
 
void startSection ()
 
 ~DebugReport ()
 

Static Public Member Functions

static DebugReportSection getCodeSection (const std::string &id, std::string title, std::string code)
 Generate a debug report section for code (preserving formatting), with the given id and title. More...
 

Private Member Functions

bool empty () const
 

Private Attributes

std::stack< std::vector< DebugReportSection > > currentSubsections
 
uint32_t nextUniqueId = 0
 
std::vector< DebugReportSectionsections
 

Friends

std::ostream & operator<< (std::ostream &out, const DebugReport &report)
 

Detailed Description

Class representing a HTML report, consisting of a list of sections.

Definition at line 87 of file DebugReport.h.

Constructor & Destructor Documentation

◆ ~DebugReport()

souffle::DebugReport::~DebugReport ( )

Member Function Documentation

◆ addCodeSection()

void souffle::DebugReport::addCodeSection ( std::string  id,
std::string  title,
std::string_view  language,
std::string_view  prev,
std::string_view  curr 
)

◆ addSection() [1/2]

void souffle::DebugReport::addSection ( DebugReportSection  section)
inline

Definition at line 93 of file DebugReport.h.

96  {

Referenced by souffle::ram::TranslationUnit::getAnalysis().

◆ addSection() [2/2]

void souffle::DebugReport::addSection ( std::string  id,
std::string  title,
std::string_view  code 
)

◆ empty()

bool souffle::DebugReport::empty ( ) const
inlineprivate

Definition at line 130 of file DebugReport.h.

◆ endSection()

void souffle::DebugReport::endSection ( std::string  currentSectionName,
std::string  currentSectionTitle 
)

◆ flush()

void souffle::DebugReport::flush ( )

◆ getCodeSection()

static DebugReportSection souffle::DebugReport::getCodeSection ( const std::string &  id,
std::string  title,
std::string  code 
)
static

Generate a debug report section for code (preserving formatting), with the given id and title.

◆ print()

void souffle::DebugReport::print ( std::ostream &  out) const

Outputs a complete HTML document to the given stream, consisting of an index of all of the sections of the report, followed by the content of each section.

◆ startSection()

void souffle::DebugReport::startSection ( )
inline

Definition at line 102 of file DebugReport.h.

Friends And Related Function Documentation

◆ operator<<

std::ostream& operator<< ( std::ostream &  out,
const DebugReport report 
)
friend

Definition at line 120 of file DebugReport.h.

124  {

Field Documentation

◆ currentSubsections

std::stack<std::vector<DebugReportSection> > souffle::DebugReport::currentSubsections
private

Definition at line 127 of file DebugReport.h.

◆ nextUniqueId

uint32_t souffle::DebugReport::nextUniqueId = 0
private

Definition at line 128 of file DebugReport.h.

◆ sections

std::vector<DebugReportSection> souffle::DebugReport::sections
private

Definition at line 126 of file DebugReport.h.


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