KiCad PCB EDA Suite
Loading...
Searching...
No Matches
SEXPR::SEXPR_LIST Class Reference

#include <sexpr.h>

Inheritance diagram for SEXPR::SEXPR_LIST:
SEXPR::SEXPR

Public Member Functions

 SEXPR_LIST ()
 
 SEXPR_LIST (int aLineNumber)
 
template<typename... Args>
 SEXPR_LIST (const Args &... args)
 
template<typename... Args>
size_t Scan (const Args &... args)
 
template<typename... Args>
void AddChildren (const Args &... args)
 
virtual ~SEXPR_LIST ()
 
bool IsList () const
 
bool IsSymbol () const
 
bool IsString () const
 
bool IsDouble () const
 
bool IsInteger () const
 
void AddChild (SEXPR *aChild)
 
SEXPR_VECTOR const * GetChildren () const
 
SEXPRGetChild (size_t aIndex) const
 
size_t GetNumberOfChildren () const
 
int64_t GetLongInteger () const
 
int32_t GetInteger () const
 
float GetFloat () const
 
double GetDouble () const
 
std::string const & GetString () const
 
std::string const & GetSymbol () const
 
SEXPR_LISTGetList ()
 
std::string AsString (size_t aLevel=0) const
 
size_t GetLineNumber () const
 

Public Attributes

SEXPR_VECTOR m_children
 

Protected Attributes

SEXPR_TYPE m_type
 
size_t m_lineNumber
 

Private Member Functions

size_t doScan (const SEXPR_SCAN_ARG *args, size_t num_args)
 
void doAddChildren (const SEXPR_CHILDREN_ARG *args, size_t num_args)
 

Private Attributes

int m_inStreamChild
 

Friends

SEXPR_LISToperator<< (SEXPR_LIST &list, double value)
 
SEXPR_LISToperator<< (SEXPR_LIST &list, float value)
 
SEXPR_LISToperator<< (SEXPR_LIST &list, int64_t value)
 
SEXPR_LISToperator<< (SEXPR_LIST &list, int32_t value)
 
SEXPR_LISToperator<< (SEXPR_LIST &list, std::string value)
 
SEXPR_LISToperator<< (SEXPR_LIST &list, const _OUT_STRING setting)
 
SEXPR_LISToperator<< (SEXPR_LIST &list, const ISEXPRABLE &obj)
 
SEXPR_LISToperator<< (SEXPR_LIST &list, SEXPR_LIST *list2)
 
SEXPR_LISToperator<< (SEXPR_LIST &list, SEXPR *obj)
 
SEXPR_LISToperator>> (SEXPR_LIST &input, ISEXPRABLE &obj)
 
SEXPR_LISToperator>> (SEXPR_LIST &input, std::string &str)
 
SEXPR_LISToperator>> (SEXPR_LIST &input, int32_t &inte)
 
SEXPR_LISToperator>> (SEXPR_LIST &input, int64_t &inte)
 
SEXPR_LISToperator>> (SEXPR_LIST &input, float &inte)
 
SEXPR_LISToperator>> (SEXPR_LIST &input, double &inte)
 
SEXPR_LISToperator>> (SEXPR_LIST &input, const _IN_STRING is)
 

Detailed Description

Definition at line 242 of file sexpr.h.

Constructor & Destructor Documentation

◆ SEXPR_LIST() [1/3]

SEXPR::SEXPR_LIST::SEXPR_LIST ( )
inline

◆ SEXPR_LIST() [2/3]

SEXPR::SEXPR_LIST::SEXPR_LIST ( int aLineNumber)
inline

Definition at line 247 of file sexpr.h.

References m_inStreamChild, and SEXPR::SEXPR_TYPE_LIST.

◆ SEXPR_LIST() [3/3]

template<typename... Args>
SEXPR::SEXPR_LIST::SEXPR_LIST ( const Args &... args)
inline

Definition at line 251 of file sexpr.h.

References AddChildren(), m_inStreamChild, and SEXPR::SEXPR_TYPE_LIST.

◆ ~SEXPR_LIST()

SEXPR::SEXPR_LIST::~SEXPR_LIST ( )
virtual

Definition at line 206 of file sexpr.cpp.

References m_children.

Member Function Documentation

◆ AddChild()

◆ AddChildren()

template<typename... Args>
void SEXPR::SEXPR_LIST::AddChildren ( const Args &... args)
inline

Definition at line 267 of file sexpr.h.

References doAddChildren().

Referenced by SEXPR_LIST().

◆ AsString()

std::string SEXPR::SEXPR::AsString ( size_t aLevel = 0) const
inherited

◆ doAddChildren()

◆ doScan()

◆ GetChild()

◆ GetChildren()

SEXPR_VECTOR const * SEXPR::SEXPR::GetChildren ( ) const
inherited

Definition at line 39 of file sexpr.cpp.

References m_type, and SEXPR::SEXPR_TYPE_LIST.

Referenced by AsString().

◆ GetDouble()

double SEXPR::SEXPR::GetDouble ( ) const
inherited

◆ GetFloat()

float SEXPR::SEXPR::GetFloat ( ) const
inherited

Definition at line 124 of file sexpr.cpp.

References GetDouble().

◆ GetInteger()

int32_t SEXPR::SEXPR::GetInteger ( ) const
inherited

Definition at line 91 of file sexpr.cpp.

References GetLongInteger().

Referenced by AsString().

◆ GetLineNumber()

size_t SEXPR::SEXPR::GetLineNumber ( ) const
inlineinherited

Definition at line 66 of file sexpr.h.

References m_lineNumber.

Referenced by GetSymbol().

◆ GetList()

SEXPR_LIST * SEXPR::SEXPR::GetList ( )
inherited

Definition at line 142 of file sexpr.cpp.

References m_type, and SEXPR::SEXPR_TYPE_LIST.

◆ GetLongInteger()

int64_t SEXPR::SEXPR::GetLongInteger ( ) const
inherited

Definition at line 96 of file sexpr.cpp.

References m_type, and SEXPR::SEXPR_TYPE_ATOM_INTEGER.

Referenced by GetInteger(), and KI_TEST::SexprIsIntegerWithValue().

◆ GetNumberOfChildren()

size_t SEXPR::SEXPR::GetNumberOfChildren ( ) const
inherited

Definition at line 71 of file sexpr.cpp.

References m_type, and SEXPR::SEXPR_TYPE_LIST.

Referenced by KI_TEST::SexprIsListOfLength(), and traverseSEXPR().

◆ GetString()

std::string const & SEXPR::SEXPR::GetString ( ) const
inherited

Definition at line 81 of file sexpr.cpp.

References m_type, and SEXPR::SEXPR_TYPE_ATOM_STRING.

Referenced by AsString(), and KI_TEST::SexprIsStringWithValue().

◆ GetSymbol()

std::string const & SEXPR::SEXPR::GetSymbol ( ) const
inherited

Definition at line 129 of file sexpr.cpp.

References GetLineNumber(), m_type, and SEXPR::SEXPR_TYPE_ATOM_SYMBOL.

Referenced by AsString(), and KI_TEST::SexprIsSymbolWithValue().

◆ IsDouble()

bool SEXPR::SEXPR::IsDouble ( ) const
inlineinherited

Definition at line 52 of file sexpr.h.

References m_type, and SEXPR::SEXPR_TYPE_ATOM_DOUBLE.

Referenced by AsString(), and KI_TEST::getType().

◆ IsInteger()

bool SEXPR::SEXPR::IsInteger ( ) const
inlineinherited

Definition at line 53 of file sexpr.h.

References m_type, and SEXPR::SEXPR_TYPE_ATOM_INTEGER.

Referenced by AsString(), and KI_TEST::getType().

◆ IsList()

bool SEXPR::SEXPR::IsList ( ) const
inlineinherited

Definition at line 49 of file sexpr.h.

References m_type, and SEXPR::SEXPR_TYPE_LIST.

Referenced by AsString(), KI_TEST::getType(), and traverseSEXPR().

◆ IsString()

bool SEXPR::SEXPR::IsString ( ) const
inlineinherited

Definition at line 51 of file sexpr.h.

References m_type, and SEXPR::SEXPR_TYPE_ATOM_STRING.

Referenced by AsString(), and KI_TEST::getType().

◆ IsSymbol()

bool SEXPR::SEXPR::IsSymbol ( ) const
inlineinherited

Definition at line 50 of file sexpr.h.

References m_type, and SEXPR::SEXPR_TYPE_ATOM_SYMBOL.

Referenced by AsString(), and KI_TEST::getType().

◆ Scan()

template<typename... Args>
size_t SEXPR::SEXPR_LIST::Scan ( const Args &... args)
inline

Definition at line 260 of file sexpr.h.

References doScan().

Friends And Related Symbol Documentation

◆ operator<< [1/9]

SEXPR_LIST & operator<< ( SEXPR_LIST & list,
const _OUT_STRING setting )
friend

Definition at line 260 of file sexpr.cpp.

References SEXPR::_OUT_STRING::_String, SEXPR::_OUT_STRING::_Symbol, res, and SEXPR_LIST().

◆ operator<< [2/9]

SEXPR_LIST & operator<< ( SEXPR_LIST & list,
const ISEXPRABLE & obj )
friend

◆ operator<< [3/9]

SEXPR_LIST & operator<< ( SEXPR_LIST & list,
double value )
friend

Definition at line 242 of file sexpr.cpp.

References SEXPR::SEXPR::AddChild(), and SEXPR_LIST().

◆ operator<< [4/9]

SEXPR_LIST & operator<< ( SEXPR_LIST & list,
float value )
friend

Definition at line 236 of file sexpr.cpp.

References SEXPR::SEXPR::AddChild(), and SEXPR_LIST().

◆ operator<< [5/9]

SEXPR_LIST & operator<< ( SEXPR_LIST & list,
int32_t value )
friend

Definition at line 230 of file sexpr.cpp.

References SEXPR::SEXPR::AddChild(), and SEXPR_LIST().

◆ operator<< [6/9]

SEXPR_LIST & operator<< ( SEXPR_LIST & list,
int64_t value )
friend

Definition at line 224 of file sexpr.cpp.

References SEXPR::SEXPR::AddChild(), and SEXPR_LIST().

◆ operator<< [7/9]

SEXPR_LIST & operator<< ( SEXPR_LIST & list,
SEXPR * obj )
friend

Definition at line 254 of file sexpr.cpp.

References SEXPR::SEXPR::AddChild(), and SEXPR_LIST().

◆ operator<< [8/9]

SEXPR_LIST & operator<< ( SEXPR_LIST & list,
SEXPR_LIST * list2 )
friend

Definition at line 401 of file sexpr.cpp.

References SEXPR::SEXPR::AddChild(), and SEXPR_LIST().

◆ operator<< [9/9]

SEXPR_LIST & operator<< ( SEXPR_LIST & list,
std::string value )
friend

Definition at line 248 of file sexpr.cpp.

References SEXPR::SEXPR::AddChild(), and SEXPR_LIST().

◆ operator>> [1/7]

SEXPR_LIST & operator>> ( SEXPR_LIST & input,
const _IN_STRING is )
friend

◆ operator>> [2/7]

SEXPR_LIST & operator>> ( SEXPR_LIST & input,
double & inte )
friend

Definition at line 352 of file sexpr.cpp.

References SEXPR::SEXPR::GetChild(), m_inStreamChild, and SEXPR_LIST().

◆ operator>> [3/7]

SEXPR_LIST & operator>> ( SEXPR_LIST & input,
float & inte )
friend

Definition at line 336 of file sexpr.cpp.

References SEXPR::SEXPR::GetChild(), m_inStreamChild, and SEXPR_LIST().

◆ operator>> [4/7]

SEXPR_LIST & operator>> ( SEXPR_LIST & input,
int32_t & inte )
friend

Definition at line 285 of file sexpr.cpp.

References SEXPR::SEXPR::GetChild(), m_inStreamChild, and SEXPR_LIST().

◆ operator>> [5/7]

SEXPR_LIST & operator>> ( SEXPR_LIST & input,
int64_t & inte )
friend

Definition at line 319 of file sexpr.cpp.

References SEXPR::SEXPR::GetChild(), m_inStreamChild, and SEXPR_LIST().

◆ operator>> [6/7]

SEXPR_LIST & operator>> ( SEXPR_LIST & input,
ISEXPRABLE & obj )
friend

Definition at line 278 of file sexpr.cpp.

References SEXPR::ISEXPRABLE::DeserializeSEXPR(), and SEXPR_LIST().

◆ operator>> [7/7]

SEXPR_LIST & operator>> ( SEXPR_LIST & input,
std::string & str )
friend

Definition at line 302 of file sexpr.cpp.

References SEXPR::SEXPR::GetChild(), m_inStreamChild, and SEXPR_LIST().

Member Data Documentation

◆ m_children

SEXPR_VECTOR SEXPR::SEXPR_LIST::m_children

Definition at line 257 of file sexpr.h.

Referenced by SEXPR::SEXPR::AddChild(), and ~SEXPR_LIST().

◆ m_inStreamChild

int SEXPR::SEXPR_LIST::m_inStreamChild
private

◆ m_lineNumber

size_t SEXPR::SEXPR::m_lineNumber
protectedinherited

Definition at line 72 of file sexpr.h.

Referenced by GetLineNumber(), SEXPR(), and SEXPR().

◆ m_type


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