LLDB mainline
Public Member Functions | Private Member Functions | Private Attributes | List of all members
MapIterator Class Reference

Public Member Functions

 MapIterator (ValueObject *entry, size_t depth=0)
 
 MapIterator ()=default
 
ValueObjectSP value ()
 
ValueObjectSP advance (size_t count)
 

Private Member Functions

void next ()
 Mimicks libc++'s __tree_next algorithm, which libc++ uses in its __tree_iteartor::operator++.
 
MapEntry tree_min (MapEntry x)
 Mimicks libc++'s __tree_min algorithm.
 
bool is_left_child (const MapEntry &x)
 

Private Attributes

MapEntry m_entry
 
size_t m_max_depth = 0
 
bool m_error = false
 

Detailed Description

Definition at line 103 of file LibCxxMap.cpp.

Constructor & Destructor Documentation

◆ MapIterator() [1/2]

MapIterator::MapIterator ( ValueObject entry,
size_t  depth = 0 
)
inline

Definition at line 105 of file LibCxxMap.cpp.

◆ MapIterator() [2/2]

MapIterator::MapIterator ( )
default

Member Function Documentation

◆ advance()

ValueObjectSP MapIterator::advance ( size_t  count)
inline

◆ is_left_child()

bool MapIterator::is_left_child ( const MapEntry x)
inlineprivate

◆ next()

void MapIterator::next ( )
inlineprivate

Mimicks libc++'s __tree_next algorithm, which libc++ uses in its __tree_iteartor::operator++.

Definition at line 129 of file LibCxxMap.cpp.

References MapEntry::error(), is_left_child(), m_entry, m_error, m_max_depth, MapEntry::null(), MapEntry::parent(), MapEntry::right(), MapEntry::SetEntry(), and tree_min().

Referenced by advance().

◆ tree_min()

MapEntry MapIterator::tree_min ( MapEntry  x)
inlineprivate

Mimicks libc++'s __tree_min algorithm.

Definition at line 154 of file LibCxxMap.cpp.

References MapEntry::error(), MapEntry::left(), m_error, m_max_depth, MapEntry::null(), and MapEntry::SetEntry().

Referenced by next().

◆ value()

ValueObjectSP MapIterator::value ( )
inline

Definition at line 110 of file LibCxxMap.cpp.

References MapEntry::GetEntry(), and m_entry.

Member Data Documentation

◆ m_entry

MapEntry MapIterator::m_entry
private

Definition at line 181 of file LibCxxMap.cpp.

Referenced by advance(), next(), and value().

◆ m_error

bool MapIterator::m_error = false
private

Definition at line 183 of file LibCxxMap.cpp.

Referenced by advance(), next(), and tree_min().

◆ m_max_depth

size_t MapIterator::m_max_depth = 0
private

Definition at line 182 of file LibCxxMap.cpp.

Referenced by advance(), next(), and tree_min().


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