LLDB  mainline
Classes | Public Types | Public Member Functions | Static Public Attributes | Private Types | Private Member Functions | Private Attributes | Friends | List of all members
lldb_private::TypeCategoryImpl Class Reference

#include <TypeCategory.h>

Collaboration diagram for lldb_private::TypeCategoryImpl:
Collaboration graph
[legend]

Classes

class  ForEachCallbacks
 

Public Types

typedef uint16_t FormatCategoryItems
 
typedef std::shared_ptr< TypeCategoryImplSharedPointer
 

Public Member Functions

 TypeCategoryImpl (IFormatChangeListener *clist, ConstString name)
 
template<typename T >
void ForEach (const ForEachCallbacks< T > &foreach)
 
FormatContainer::SubcontainerSP GetTypeFormatsContainer ()
 
FormatContainer::SubcontainerSP GetRegexTypeFormatsContainer ()
 
FormatContainerGetFormatContainer ()
 
SummaryContainer::SubcontainerSP GetTypeSummariesContainer ()
 
SummaryContainer::SubcontainerSP GetRegexTypeSummariesContainer ()
 
SummaryContainerGetSummaryContainer ()
 
FilterContainer::SubcontainerSP GetTypeFiltersContainer ()
 
FilterContainer::SubcontainerSP GetRegexTypeFiltersContainer ()
 
FilterContainerGetFilterContainer ()
 
FormatContainer::MapValueType GetFormatForType (lldb::TypeNameSpecifierImplSP type_sp)
 
SummaryContainer::MapValueType GetSummaryForType (lldb::TypeNameSpecifierImplSP type_sp)
 
FilterContainer::MapValueType GetFilterForType (lldb::TypeNameSpecifierImplSP type_sp)
 
SynthContainer::MapValueType GetSyntheticForType (lldb::TypeNameSpecifierImplSP type_sp)
 
void AddTypeFormat (lldb::TypeNameSpecifierImplSP type_sp, lldb::TypeFormatImplSP format_sp)
 
void AddTypeSummary (lldb::TypeNameSpecifierImplSP type_sp, lldb::TypeSummaryImplSP summary_sp)
 
void AddTypeFilter (lldb::TypeNameSpecifierImplSP type_sp, lldb::TypeFilterImplSP filter_sp)
 
void AddTypeSynthetic (lldb::TypeNameSpecifierImplSP type_sp, lldb::SyntheticChildrenSP synth_sp)
 
bool DeleteTypeFormat (lldb::TypeNameSpecifierImplSP type_sp)
 
bool DeleteTypeSummary (lldb::TypeNameSpecifierImplSP type_sp)
 
bool DeleteTypeFilter (lldb::TypeNameSpecifierImplSP type_sp)
 
bool DeleteTypeSynthetic (lldb::TypeNameSpecifierImplSP type_sp)
 
uint32_t GetNumFormats ()
 
uint32_t GetNumSummaries ()
 
uint32_t GetNumFilters ()
 
uint32_t GetNumSynthetics ()
 
lldb::TypeNameSpecifierImplSP GetTypeNameSpecifierForFormatAtIndex (size_t index)
 
lldb::TypeNameSpecifierImplSP GetTypeNameSpecifierForSummaryAtIndex (size_t index)
 
lldb::TypeNameSpecifierImplSP GetTypeNameSpecifierForFilterAtIndex (size_t index)
 
lldb::TypeNameSpecifierImplSP GetTypeNameSpecifierForSyntheticAtIndex (size_t index)
 
FormatContainer::MapValueType GetFormatAtIndex (size_t index)
 
SummaryContainer::MapValueType GetSummaryAtIndex (size_t index)
 
FilterContainer::MapValueType GetFilterAtIndex (size_t index)
 
SynthContainer::MapValueType GetSyntheticAtIndex (size_t index)
 
SynthContainer::SubcontainerSP GetTypeSyntheticsContainer ()
 
SynthContainer::SubcontainerSP GetRegexTypeSyntheticsContainer ()
 
SynthContainerGetSyntheticsContainer ()
 
bool IsEnabled () const
 
uint32_t GetEnabledPosition ()
 
bool Get (lldb::LanguageType lang, const FormattersMatchVector &candidates, lldb::TypeFormatImplSP &entry)
 
bool Get (lldb::LanguageType lang, const FormattersMatchVector &candidates, lldb::TypeSummaryImplSP &entry)
 
bool Get (lldb::LanguageType lang, const FormattersMatchVector &candidates, lldb::SyntheticChildrenSP &entry)
 
void Clear (FormatCategoryItems items=ALL_ITEM_TYPES)
 
bool Delete (ConstString name, FormatCategoryItems items=ALL_ITEM_TYPES)
 
uint32_t GetCount (FormatCategoryItems items=ALL_ITEM_TYPES)
 
const char * GetName ()
 
size_t GetNumLanguages ()
 
lldb::LanguageType GetLanguageAtIndex (size_t idx)
 
void AddLanguage (lldb::LanguageType lang)
 
std::string GetDescription ()
 
bool AnyMatches (ConstString type_name, FormatCategoryItems items=ALL_ITEM_TYPES, bool only_enabled=true, const char **matching_category=nullptr, FormatCategoryItems *matching_type=nullptr)
 

Static Public Attributes

static const uint16_t ALL_ITEM_TYPES = UINT16_MAX
 

Private Types

typedef TieredFormatterContainer< TypeFormatImplFormatContainer
 
typedef TieredFormatterContainer< TypeSummaryImplSummaryContainer
 
typedef TieredFormatterContainer< TypeFilterImplFilterContainer
 
typedef TieredFormatterContainer< SyntheticChildrenSynthContainer
 

Private Member Functions

void Enable (bool value, uint32_t position)
 
void Disable ()
 
bool IsApplicable (lldb::LanguageType lang)
 
uint32_t GetLastEnabledPosition ()
 
void SetEnabledPosition (uint32_t p)
 

Private Attributes

FormatContainer m_format_cont
 
SummaryContainer m_summary_cont
 
FilterContainer m_filter_cont
 
SynthContainer m_synth_cont
 
bool m_enabled
 
IFormatChangeListenerm_change_listener
 
std::recursive_mutex m_mutex
 
ConstString m_name
 
std::vector< lldb::LanguageTypem_languages
 
uint32_t m_enabled_position = 0
 

Friends

class FormatManager
 
class LanguageCategory
 
class TypeCategoryMap
 
class FormattersContainer< TypeFormatImpl >
 
class FormattersContainer< TypeSummaryImpl >
 
class FormattersContainer< TypeFilterImpl >
 
class FormattersContainer< ScriptedSyntheticChildren >
 

Detailed Description

Definition at line 138 of file TypeCategory.h.

Member Typedef Documentation

◆ FilterContainer

Definition at line 142 of file TypeCategory.h.

◆ FormatCategoryItems

Definition at line 146 of file TypeCategory.h.

◆ FormatContainer

Definition at line 140 of file TypeCategory.h.

◆ SharedPointer

Definition at line 422 of file TypeCategory.h.

◆ SummaryContainer

Definition at line 141 of file TypeCategory.h.

◆ SynthContainer

Definition at line 143 of file TypeCategory.h.

Constructor & Destructor Documentation

◆ TypeCategoryImpl()

TypeCategoryImpl::TypeCategoryImpl ( IFormatChangeListener clist,
ConstString  name 
)

Definition at line 16 of file TypeCategory.cpp.

Member Function Documentation

◆ AddLanguage()

void TypeCategoryImpl::AddLanguage ( lldb::LanguageType  lang)

Definition at line 81 of file TypeCategory.cpp.

References m_languages.

◆ AddTypeFilter()

void lldb_private::TypeCategoryImpl::AddTypeFilter ( lldb::TypeNameSpecifierImplSP  type_sp,
lldb::TypeFilterImplSP  filter_sp 
)
inline

◆ AddTypeFormat()

void lldb_private::TypeCategoryImpl::AddTypeFormat ( lldb::TypeNameSpecifierImplSP  type_sp,
lldb::TypeFormatImplSP  format_sp 
)
inline

◆ AddTypeSummary()

void lldb_private::TypeCategoryImpl::AddTypeSummary ( lldb::TypeNameSpecifierImplSP  type_sp,
lldb::TypeSummaryImplSP  summary_sp 
)
inline

◆ AddTypeSynthetic()

void lldb_private::TypeCategoryImpl::AddTypeSynthetic ( lldb::TypeNameSpecifierImplSP  type_sp,
lldb::SyntheticChildrenSP  synth_sp 
)
inline

◆ AnyMatches()

bool TypeCategoryImpl::AnyMatches ( ConstString  type_name,
FormatCategoryItems  items = ALL_ITEM_TYPES,
bool  only_enabled = true,
const char **  matching_category = nullptr,
FormatCategoryItems matching_type = nullptr 
)

◆ Clear()

void TypeCategoryImpl::Clear ( FormatCategoryItems  items = ALL_ITEM_TYPES)

◆ Delete()

bool TypeCategoryImpl::Delete ( ConstString  name,
FormatCategoryItems  items = ALL_ITEM_TYPES 
)

◆ DeleteTypeFilter()

bool lldb_private::TypeCategoryImpl::DeleteTypeFilter ( lldb::TypeNameSpecifierImplSP  type_sp)
inline

◆ DeleteTypeFormat()

bool lldb_private::TypeCategoryImpl::DeleteTypeFormat ( lldb::TypeNameSpecifierImplSP  type_sp)
inline

◆ DeleteTypeSummary()

bool lldb_private::TypeCategoryImpl::DeleteTypeSummary ( lldb::TypeNameSpecifierImplSP  type_sp)
inline

◆ DeleteTypeSynthetic()

bool lldb_private::TypeCategoryImpl::DeleteTypeSynthetic ( lldb::TypeNameSpecifierImplSP  type_sp)
inline

◆ Disable()

void lldb_private::TypeCategoryImpl::Disable ( )
inlineprivate

Definition at line 444 of file TypeCategory.h.

References Enable(), and UINT32_MAX.

◆ Enable()

void TypeCategoryImpl::Enable ( bool  value,
uint32_t  position 
)
private

◆ ForEach()

template<typename T >
void lldb_private::TypeCategoryImpl::ForEach ( const ForEachCallbacks< T > &  foreach)
inline

◆ Get() [1/3]

bool TypeCategoryImpl::Get ( lldb::LanguageType  lang,
const FormattersMatchVector candidates,
lldb::SyntheticChildrenSP &  entry 
)

◆ Get() [2/3]

bool TypeCategoryImpl::Get ( lldb::LanguageType  lang,
const FormattersMatchVector candidates,
lldb::TypeFormatImplSP &  entry 
)

◆ Get() [3/3]

bool TypeCategoryImpl::Get ( lldb::LanguageType  lang,
const FormattersMatchVector candidates,
lldb::TypeSummaryImplSP &  entry 
)

◆ GetCount()

uint32_t TypeCategoryImpl::GetCount ( FormatCategoryItems  items = ALL_ITEM_TYPES)

◆ GetDescription()

std::string TypeCategoryImpl::GetDescription ( )

◆ GetEnabledPosition()

uint32_t lldb_private::TypeCategoryImpl::GetEnabledPosition ( )
inline

Definition at line 384 of file TypeCategory.h.

References m_enabled, m_enabled_position, and UINT32_MAX.

◆ GetFilterAtIndex()

TypeCategoryImpl::FilterContainer::MapValueType TypeCategoryImpl::GetFilterAtIndex ( size_t  index)

◆ GetFilterContainer()

FilterContainer& lldb_private::TypeCategoryImpl::GetFilterContainer ( )
inline

Definition at line 293 of file TypeCategory.h.

References m_filter_cont.

◆ GetFilterForType()

TypeCategoryImpl::FilterContainer::MapValueType TypeCategoryImpl::GetFilterForType ( lldb::TypeNameSpecifierImplSP  type_sp)

◆ GetFormatAtIndex()

TypeCategoryImpl::FormatContainer::MapValueType TypeCategoryImpl::GetFormatAtIndex ( size_t  index)

◆ GetFormatContainer()

FormatContainer& lldb_private::TypeCategoryImpl::GetFormatContainer ( )
inline

Definition at line 273 of file TypeCategory.h.

References m_format_cont.

◆ GetFormatForType()

TypeCategoryImpl::FormatContainer::MapValueType TypeCategoryImpl::GetFormatForType ( lldb::TypeNameSpecifierImplSP  type_sp)

◆ GetLanguageAtIndex()

lldb::LanguageType TypeCategoryImpl::GetLanguageAtIndex ( size_t  idx)

Definition at line 75 of file TypeCategory.cpp.

References lldb::eLanguageTypeUnknown, and m_languages.

Referenced by GetDescription(), and IsApplicable().

◆ GetLastEnabledPosition()

uint32_t lldb_private::TypeCategoryImpl::GetLastEnabledPosition ( )
inlineprivate

Definition at line 448 of file TypeCategory.h.

References m_enabled_position.

◆ GetName()

const char* lldb_private::TypeCategoryImpl::GetName ( )
inline

Definition at line 406 of file TypeCategory.h.

References lldb_private::ConstString::GetCString(), and m_name.

Referenced by GetDescription().

◆ GetNumFilters()

uint32_t lldb_private::TypeCategoryImpl::GetNumFilters ( )
inline

◆ GetNumFormats()

uint32_t lldb_private::TypeCategoryImpl::GetNumFormats ( )
inline

◆ GetNumLanguages()

size_t TypeCategoryImpl::GetNumLanguages ( )

Definition at line 69 of file TypeCategory.cpp.

References m_languages.

Referenced by GetDescription(), and IsApplicable().

◆ GetNumSummaries()

uint32_t lldb_private::TypeCategoryImpl::GetNumSummaries ( )
inline

◆ GetNumSynthetics()

uint32_t lldb_private::TypeCategoryImpl::GetNumSynthetics ( )
inline

◆ GetRegexTypeFiltersContainer()

FilterContainer::SubcontainerSP lldb_private::TypeCategoryImpl::GetRegexTypeFiltersContainer ( )
inline

◆ GetRegexTypeFormatsContainer()

FormatContainer::SubcontainerSP lldb_private::TypeCategoryImpl::GetRegexTypeFormatsContainer ( )
inline

◆ GetRegexTypeSummariesContainer()

SummaryContainer::SubcontainerSP lldb_private::TypeCategoryImpl::GetRegexTypeSummariesContainer ( )
inline

◆ GetRegexTypeSyntheticsContainer()

SynthContainer::SubcontainerSP lldb_private::TypeCategoryImpl::GetRegexTypeSyntheticsContainer ( )
inline

◆ GetSummaryAtIndex()

TypeCategoryImpl::SummaryContainer::MapValueType TypeCategoryImpl::GetSummaryAtIndex ( size_t  index)

◆ GetSummaryContainer()

SummaryContainer& lldb_private::TypeCategoryImpl::GetSummaryContainer ( )
inline

Definition at line 283 of file TypeCategory.h.

References m_summary_cont.

◆ GetSummaryForType()

TypeCategoryImpl::SummaryContainer::MapValueType TypeCategoryImpl::GetSummaryForType ( lldb::TypeNameSpecifierImplSP  type_sp)

◆ GetSyntheticAtIndex()

TypeCategoryImpl::SynthContainer::MapValueType TypeCategoryImpl::GetSyntheticAtIndex ( size_t  index)

◆ GetSyntheticForType()

TypeCategoryImpl::SynthContainer::MapValueType TypeCategoryImpl::GetSyntheticForType ( lldb::TypeNameSpecifierImplSP  type_sp)

◆ GetSyntheticsContainer()

SynthContainer& lldb_private::TypeCategoryImpl::GetSyntheticsContainer ( )
inline

Definition at line 379 of file TypeCategory.h.

References m_synth_cont.

◆ GetTypeFiltersContainer()

FilterContainer::SubcontainerSP lldb_private::TypeCategoryImpl::GetTypeFiltersContainer ( )
inline

◆ GetTypeFormatsContainer()

FormatContainer::SubcontainerSP lldb_private::TypeCategoryImpl::GetTypeFormatsContainer ( )
inline

◆ GetTypeNameSpecifierForFilterAtIndex()

lldb::TypeNameSpecifierImplSP TypeCategoryImpl::GetTypeNameSpecifierForFilterAtIndex ( size_t  index)

◆ GetTypeNameSpecifierForFormatAtIndex()

lldb::TypeNameSpecifierImplSP TypeCategoryImpl::GetTypeNameSpecifierForFormatAtIndex ( size_t  index)

◆ GetTypeNameSpecifierForSummaryAtIndex()

lldb::TypeNameSpecifierImplSP TypeCategoryImpl::GetTypeNameSpecifierForSummaryAtIndex ( size_t  index)

◆ GetTypeNameSpecifierForSyntheticAtIndex()

lldb::TypeNameSpecifierImplSP TypeCategoryImpl::GetTypeNameSpecifierForSyntheticAtIndex ( size_t  index)

◆ GetTypeSummariesContainer()

SummaryContainer::SubcontainerSP lldb_private::TypeCategoryImpl::GetTypeSummariesContainer ( )
inline

◆ GetTypeSyntheticsContainer()

SynthContainer::SubcontainerSP lldb_private::TypeCategoryImpl::GetTypeSyntheticsContainer ( )
inline

◆ IsApplicable()

bool TypeCategoryImpl::IsApplicable ( lldb::LanguageType  lang)
private

Definition at line 60 of file TypeCategory.cpp.

References GetLanguageAtIndex(), and GetNumLanguages().

Referenced by Get().

◆ IsEnabled()

bool lldb_private::TypeCategoryImpl::IsEnabled ( ) const
inline

Definition at line 382 of file TypeCategory.h.

References m_enabled.

Referenced by AnyMatches(), Get(), and GetDescription().

◆ SetEnabledPosition()

void lldb_private::TypeCategoryImpl::SetEnabledPosition ( uint32_t  p)
inlineprivate

Definition at line 450 of file TypeCategory.h.

References m_enabled_position.

Friends And Related Function Documentation

◆ FormatManager

friend class FormatManager
friend

Definition at line 452 of file TypeCategory.h.

◆ FormattersContainer< ScriptedSyntheticChildren >

Definition at line 462 of file TypeCategory.h.

◆ FormattersContainer< TypeFilterImpl >

friend class FormattersContainer< TypeFilterImpl >
friend

Definition at line 460 of file TypeCategory.h.

◆ FormattersContainer< TypeFormatImpl >

friend class FormattersContainer< TypeFormatImpl >
friend

Definition at line 456 of file TypeCategory.h.

◆ FormattersContainer< TypeSummaryImpl >

friend class FormattersContainer< TypeSummaryImpl >
friend

Definition at line 458 of file TypeCategory.h.

◆ LanguageCategory

friend class LanguageCategory
friend

Definition at line 453 of file TypeCategory.h.

◆ TypeCategoryMap

friend class TypeCategoryMap
friend

Definition at line 454 of file TypeCategory.h.

Member Data Documentation

◆ ALL_ITEM_TYPES

const uint16_t lldb_private::TypeCategoryImpl::ALL_ITEM_TYPES = UINT16_MAX
static

Definition at line 147 of file TypeCategory.h.

◆ m_change_listener

IFormatChangeListener* lldb_private::TypeCategoryImpl::m_change_listener
private

Definition at line 432 of file TypeCategory.h.

Referenced by Enable().

◆ m_enabled

bool lldb_private::TypeCategoryImpl::m_enabled
private

Definition at line 430 of file TypeCategory.h.

Referenced by Enable(), GetEnabledPosition(), and IsEnabled().

◆ m_enabled_position

uint32_t lldb_private::TypeCategoryImpl::m_enabled_position = 0
private

◆ m_filter_cont

FilterContainer lldb_private::TypeCategoryImpl::m_filter_cont
private

◆ m_format_cont

FormatContainer lldb_private::TypeCategoryImpl::m_format_cont
private

◆ m_languages

std::vector<lldb::LanguageType> lldb_private::TypeCategoryImpl::m_languages
private

Definition at line 438 of file TypeCategory.h.

Referenced by AddLanguage(), GetLanguageAtIndex(), and GetNumLanguages().

◆ m_mutex

std::recursive_mutex lldb_private::TypeCategoryImpl::m_mutex
private

Definition at line 434 of file TypeCategory.h.

Referenced by Enable().

◆ m_name

ConstString lldb_private::TypeCategoryImpl::m_name
private

Definition at line 436 of file TypeCategory.h.

Referenced by AnyMatches(), and GetName().

◆ m_summary_cont

SummaryContainer lldb_private::TypeCategoryImpl::m_summary_cont
private

◆ m_synth_cont

SynthContainer lldb_private::TypeCategoryImpl::m_synth_cont
private

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