LLDB mainline
Public Member Functions | Protected Member Functions | Private Member Functions | Private Attributes | Friends | List of all members
lldb::SBSymbol Class Reference

#include <SBSymbol.h>

Public Member Functions

 SBSymbol ()
 
 ~SBSymbol ()
 
 SBSymbol (const lldb::SBSymbol &rhs)
 
const lldb::SBSymboloperator= (const lldb::SBSymbol &rhs)
 
 operator bool () const
 
bool IsValid () const
 
const char * GetName () const
 
const char * GetDisplayName () const
 
const char * GetMangledName () const
 
lldb::SBInstructionList GetInstructions (lldb::SBTarget target)
 
lldb::SBInstructionList GetInstructions (lldb::SBTarget target, const char *flavor_string)
 
SBAddress GetStartAddress ()
 Get the start address of this symbol.
 
SBAddress GetEndAddress ()
 Get the end address of this symbol.
 
uint64_t GetValue ()
 Get the raw value of a symbol.
 
uint64_t GetSize ()
 Get the size of the symbol.
 
uint32_t GetPrologueByteSize ()
 
SymbolType GetType ()
 
bool operator== (const lldb::SBSymbol &rhs) const
 
bool operator!= (const lldb::SBSymbol &rhs) const
 
bool GetDescription (lldb::SBStream &description)
 
bool IsExternal ()
 
bool IsSynthetic ()
 

Protected Member Functions

lldb_private::Symbolget ()
 
void reset (lldb_private::Symbol *)
 

Private Member Functions

 SBSymbol (lldb_private::Symbol *lldb_object_ptr)
 
void SetSymbol (lldb_private::Symbol *lldb_object_ptr)
 

Private Attributes

lldb_private::Symbolm_opaque_ptr = nullptr
 

Friends

class SBAddress
 
class SBFrame
 
class SBModule
 
class SBSymbolContext
 

Detailed Description

Definition at line 19 of file SBSymbol.h.

Constructor & Destructor Documentation

◆ SBSymbol() [1/3]

SBSymbol::SBSymbol ( )

Definition at line 21 of file SBSymbol.cpp.

References LLDB_INSTRUMENT_VA.

◆ ~SBSymbol()

SBSymbol::~SBSymbol ( )

Definition at line 37 of file SBSymbol.cpp.

References m_opaque_ptr.

◆ SBSymbol() [2/3]

SBSymbol::SBSymbol ( const lldb::SBSymbol rhs)

Definition at line 26 of file SBSymbol.cpp.

References LLDB_INSTRUMENT_VA.

◆ SBSymbol() [3/3]

SBSymbol::SBSymbol ( lldb_private::Symbol lldb_object_ptr)
private

Definition at line 23 of file SBSymbol.cpp.

Member Function Documentation

◆ get()

lldb_private::Symbol * SBSymbol::get ( )
protected

Definition at line 137 of file SBSymbol.cpp.

References m_opaque_ptr.

Referenced by lldb::SBSymbolContext::SetSymbol().

◆ GetDescription()

bool SBSymbol::GetDescription ( lldb::SBStream description)

◆ GetDisplayName()

const char * SBSymbol::GetDisplayName ( ) const

◆ GetEndAddress()

SBAddress SBSymbol::GetEndAddress ( )

Get the end address of this symbol.

Returns
If the symbol's value is not an address, an invalid SBAddress object will be returned. If the symbol's value is an address, a valid SBAddress object will be returned.

Definition at line 151 of file SBSymbol.cpp.

References lldb_private::Symbol::GetAddressRef(), lldb_private::Symbol::GetByteSize(), LLDB_INSTRUMENT_VA, m_opaque_ptr, lldb::SBAddress::SetAddress(), lldb_private::Address::Slide(), and lldb_private::Symbol::ValueIsAddress().

◆ GetInstructions() [1/2]

SBInstructionList SBSymbol::GetInstructions ( lldb::SBTarget  target)

Definition at line 107 of file SBSymbol.cpp.

References GetInstructions(), and LLDB_INSTRUMENT_VA.

Referenced by GetInstructions().

◆ GetInstructions() [2/2]

SBInstructionList SBSymbol::GetInstructions ( lldb::SBTarget  target,
const char *  flavor_string 
)

◆ GetMangledName()

const char * SBSymbol::GetMangledName ( ) const

◆ GetName()

const char * SBSymbol::GetName ( ) const

◆ GetPrologueByteSize()

uint32_t SBSymbol::GetPrologueByteSize ( )

◆ GetSize()

uint64_t SBSymbol::GetSize ( )

Get the size of the symbol.

This accessor allows direct access to the symbol's size from the symbol table regardless of what the value is (address or integer value).

Returns
Returns the size of a symbol from the symbol table.

Definition at line 172 of file SBSymbol.cpp.

References lldb_private::Symbol::GetByteSize(), lldb_private::Symbol::GetByteSizeIsValid(), LLDB_INSTRUMENT_VA, and m_opaque_ptr.

◆ GetStartAddress()

SBAddress SBSymbol::GetStartAddress ( )

Get the start address of this symbol.

Returns
If the symbol's value is not an address, an invalid SBAddress object will be returned. If the symbol's value is an address, a valid SBAddress object will be returned.

Definition at line 141 of file SBSymbol.cpp.

References lldb_private::Symbol::GetAddressRef(), LLDB_INSTRUMENT_VA, m_opaque_ptr, lldb::SBAddress::SetAddress(), and lldb_private::Symbol::ValueIsAddress().

◆ GetType()

SymbolType SBSymbol::GetType ( )

◆ GetValue()

uint64_t SBSymbol::GetValue ( )

Get the raw value of a symbol.

This accessor allows direct access to the symbol's value from the symbol table regardless of what the value is. The value can be a file address or it can be an integer value that depends on what the symbol's type is. Some symbol values are not addresses, but absolute values or integer values that can be mean different things. The GetStartAddress() accessor will only return a valid SBAddress if the symbol's value is an address, so this accessor provides a way to access the symbol's value when the value is not an address.

Returns
Returns the raw integer value of a symbol from the symbol table.

Definition at line 165 of file SBSymbol.cpp.

References lldb_private::Symbol::GetRawValue(), LLDB_INSTRUMENT_VA, and m_opaque_ptr.

◆ IsExternal()

bool SBSymbol::IsExternal ( )

◆ IsSynthetic()

bool SBSymbol::IsSynthetic ( )

◆ IsValid()

bool SBSymbol::IsValid ( ) const

Definition at line 43 of file SBSymbol.cpp.

References LLDB_INSTRUMENT_VA.

◆ operator bool()

SBSymbol::operator bool ( ) const
explicit

Definition at line 47 of file SBSymbol.cpp.

References LLDB_INSTRUMENT_VA.

◆ operator!=()

bool SBSymbol::operator!= ( const lldb::SBSymbol rhs) const

Definition at line 88 of file SBSymbol.cpp.

References LLDB_INSTRUMENT_VA, and m_opaque_ptr.

◆ operator=()

const SBSymbol & SBSymbol::operator= ( const lldb::SBSymbol rhs)

Definition at line 30 of file SBSymbol.cpp.

References LLDB_INSTRUMENT_VA, and m_opaque_ptr.

◆ operator==()

bool SBSymbol::operator== ( const lldb::SBSymbol rhs) const

Definition at line 82 of file SBSymbol.cpp.

References LLDB_INSTRUMENT_VA, and m_opaque_ptr.

◆ reset()

void SBSymbol::reset ( lldb_private::Symbol symbol)
protected

Definition at line 139 of file SBSymbol.cpp.

References m_opaque_ptr.

Referenced by lldb::SBAddress::GetSymbol(), and lldb::SBFrame::GetSymbol().

◆ SetSymbol()

void SBSymbol::SetSymbol ( lldb_private::Symbol lldb_object_ptr)
private

Definition at line 39 of file SBSymbol.cpp.

References m_opaque_ptr.

Referenced by lldb::SBModule::FindSymbol(), and lldb::SBModule::GetSymbolAtIndex().

Friends And Related Function Documentation

◆ SBAddress

friend class SBAddress
friend

Definition at line 108 of file SBSymbol.h.

◆ SBFrame

friend class SBFrame
friend

Definition at line 109 of file SBSymbol.h.

◆ SBModule

friend class SBModule
friend

Definition at line 110 of file SBSymbol.h.

◆ SBSymbolContext

friend class SBSymbolContext
friend

Definition at line 111 of file SBSymbol.h.

Member Data Documentation

◆ m_opaque_ptr

lldb_private::Symbol* lldb::SBSymbol::m_opaque_ptr = nullptr
private

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