LLDB  mainline
Classes | Public Types | Public Member Functions | Protected Attributes | Private Member Functions | List of all members
lldb_private::SourceManager Class Reference

#include <SourceManager.h>

Collaboration diagram for lldb_private::SourceManager:
Collaboration graph


class  File
class  SourceFileCache

Public Types

typedef std::shared_ptr< FileFileSP

Public Member Functions

 SourceManager (const lldb::DebuggerSP &debugger_sp)
 SourceManager (const lldb::TargetSP &target_sp)
 ~SourceManager ()
FileSP GetLastFile ()
size_t DisplaySourceLinesWithLineNumbers (const FileSpec &file, uint32_t line, uint32_t column, uint32_t context_before, uint32_t context_after, const char *current_line_cstr, Stream *s, const SymbolContextList *bp_locs=nullptr)
size_t DisplaySourceLinesWithLineNumbersUsingLastFile (uint32_t start_line, uint32_t count, uint32_t curr_line, uint32_t column, const char *current_line_cstr, Stream *s, const SymbolContextList *bp_locs=nullptr)
size_t DisplayMoreWithLineNumbers (Stream *s, uint32_t count, bool reverse, const SymbolContextList *bp_locs=nullptr)
bool SetDefaultFileAndLine (const FileSpec &file_spec, uint32_t line)
bool GetDefaultFileAndLine (FileSpec &file_spec, uint32_t &line)
bool DefaultFileAndLineSet ()
void FindLinesMatchingRegex (FileSpec &file_spec, RegularExpression &regex, uint32_t start_line, uint32_t end_line, std::vector< uint32_t > &match_lines)
FileSP GetFile (const FileSpec &file_spec)

Protected Attributes

FileSpec m_last_file_spec
uint32_t m_last_line
uint32_t m_last_count
bool m_default_set
lldb::TargetWP m_target_wp
lldb::DebuggerWP m_debugger_wp

Private Member Functions

 SourceManager (const SourceManager &)=delete
const SourceManageroperator= (const SourceManager &)=delete

Detailed Description

Definition at line 31 of file SourceManager.h.

Member Typedef Documentation

◆ FileSP

typedef std::shared_ptr<File> lldb_private::SourceManager::FileSP

Definition at line 91 of file SourceManager.h.

Constructor & Destructor Documentation

◆ SourceManager() [1/3]

lldb_private::SourceManager::SourceManager ( const lldb::DebuggerSP &  debugger_sp)

Referenced by is_newline_char().

◆ SourceManager() [2/3]

lldb_private::SourceManager::SourceManager ( const lldb::TargetSP &  target_sp)

◆ ~SourceManager()

SourceManager::~SourceManager ( )

Definition at line 64 of file SourceManager.cpp.

◆ SourceManager() [3/3]

lldb_private::SourceManager::SourceManager ( const SourceManager )

Member Function Documentation

◆ DefaultFileAndLineSet()

bool lldb_private::SourceManager::DefaultFileAndLineSet ( )

◆ DisplayMoreWithLineNumbers()

size_t SourceManager::DisplayMoreWithLineNumbers ( Stream s,
uint32_t  count,
bool  reverse,
const SymbolContextList bp_locs = nullptr 

Definition at line 265 of file SourceManager.cpp.

References UINT32_MAX.

Referenced by CommandObjectSourceList::DoExecute(), and GetLastFile().

◆ DisplaySourceLinesWithLineNumbers()

size_t SourceManager::DisplaySourceLinesWithLineNumbers ( const FileSpec file,
uint32_t  line,
uint32_t  column,
uint32_t  context_before,
uint32_t  context_after,
const char *  current_line_cstr,
Stream s,
const SymbolContextList bp_locs = nullptr 

◆ DisplaySourceLinesWithLineNumbersUsingLastFile()

size_t SourceManager::DisplaySourceLinesWithLineNumbersUsingLastFile ( uint32_t  start_line,
uint32_t  count,
uint32_t  curr_line,
uint32_t  column,
const char *  current_line_cstr,
Stream s,
const SymbolContextList bp_locs = nullptr 

◆ FindLinesMatchingRegex()

void SourceManager::FindLinesMatchingRegex ( FileSpec file_spec,
RegularExpression regex,
uint32_t  start_line,
uint32_t  end_line,
std::vector< uint32_t > &  match_lines 

Definition at line 368 of file SourceManager.cpp.

◆ GetDefaultFileAndLine()

bool SourceManager::GetDefaultFileAndLine ( FileSpec file_spec,
uint32_t line 

◆ GetFile()

SourceManager::FileSP SourceManager::GetFile ( const FileSpec file_spec)

Definition at line 66 of file SourceManager.cpp.

References lldb_private::FileSystem::Instance().

Referenced by DefaultFileAndLineSet(), and GetLastFile().

◆ GetLastFile()

FileSP lldb_private::SourceManager::GetLastFile ( )

◆ operator=()

const SourceManager& lldb_private::SourceManager::operator= ( const SourceManager )

◆ SetDefaultFileAndLine()

bool SourceManager::SetDefaultFileAndLine ( const FileSpec file_spec,
uint32_t  line 

Member Data Documentation

◆ m_debugger_wp

lldb::DebuggerWP lldb_private::SourceManager::m_debugger_wp

Definition at line 160 of file SourceManager.h.

◆ m_default_set

bool lldb_private::SourceManager::m_default_set

Definition at line 158 of file SourceManager.h.

◆ m_last_count

uint32_t lldb_private::SourceManager::m_last_count

Definition at line 157 of file SourceManager.h.

◆ m_last_file_spec

FileSpec lldb_private::SourceManager::m_last_file_spec

Definition at line 155 of file SourceManager.h.

Referenced by DefaultFileAndLineSet(), and GetLastFile().

◆ m_last_line

uint32_t lldb_private::SourceManager::m_last_line

Definition at line 156 of file SourceManager.h.

◆ m_target_wp

lldb::TargetWP lldb_private::SourceManager::m_target_wp

Definition at line 159 of file SourceManager.h.

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