PEBL 2.2
Psychology Experiment Building Language - Cross-platform psychological experiment development system
PCallStack Class Reference

#include <PError.h>

Public Member Functions

 PCallStack ()
 
 ~PCallStack ()
 
void Push (const PNode *node)
 
void Pop ()
 
int Size ()
 
std::ostream & PrintCallStack (std::ostream &out) const
 

Detailed Description

Definition at line 106 of file PError.h.

Constructor & Destructor Documentation

◆ PCallStack()

PCallStack::PCallStack ( )
inline

Definition at line 109 of file PError.h.

109{};

◆ ~PCallStack()

PCallStack::~PCallStack ( )
inline

Definition at line 110 of file PError.h.

110{};

Member Function Documentation

◆ Pop()

void PCallStack::Pop ( )
inline

Definition at line 112 of file PError.h.

112{mNodes.pop_back();};

Referenced by Evaluator::Evaluate1().

◆ PrintCallStack()

std::ostream & PCallStack::PrintCallStack ( std::ostream &  out) const
inline

Definition at line 114 of file PError.h.

115 {
116 std::string indent = "";
117 std::list<const PNode*>::const_iterator i = mNodes.begin();
118
119 while(i != mNodes.end())
120 {
121 out << indent << "Called from function ["<< (*i)->GetFunctionName()<< "] on line ["<<(*i)->GetLineNumber() << "] of file [" << (*i)->GetFilename() << "]\n";
122 indent = indent + " ";
123 i++;
124 }
125 return out;
126 }

◆ Push()

void PCallStack::Push ( const PNode node)
inline

Definition at line 111 of file PError.h.

111{mNodes.push_back(node);};

Referenced by Evaluator::Evaluate1(), Evaluator::Evaluator(), and Evaluator::Evaluator().

◆ Size()

int PCallStack::Size ( )
inline

Definition at line 113 of file PError.h.

113{return (int)(mNodes.size());};

Referenced by Evaluator::Evaluate1().


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