AstNode Class Reference

#include <AstNode.h>


Detailed Description

Definition at line 23 of file AstNode.h.


Public Member Functions

 AstNode (const std::string &_type="", const std::string &_value="")
 AstNode (const AstNode &n)
 ~AstNode ()
AstNodeoperator= (const AstNode &n)
bool operator== (const AstNode &n) const
void setValue (const std::string &v)
void setType (const std::string &t)
std::string getValue () const
std::string getType () const

Private Attributes

std::string type
std::string value

Friends

std::ostream & operator<< (std::ostream &stream, const AstNode &node)

Constructor & Destructor Documentation

AstNode::AstNode ( const std::string &  _type = "",
const std::string &  _value = "" 
) [inline]

Definition at line 28 of file AstNode.h.

00029       : type(_type), value(_value) {}

AstNode::AstNode ( const AstNode n  )  [inline]

Definition at line 30 of file AstNode.h.

00030                               {
00031         if (this != &n)
00032             *this = n;
00033     }

AstNode::~AstNode (  )  [inline]

Definition at line 34 of file AstNode.h.

00034 {}


Member Function Documentation

AstNode& AstNode::operator= ( const AstNode n  )  [inline]

Definition at line 36 of file AstNode.h.

References type, and value.

00036                                          {
00037         if (this != &n) {
00038             type = n.type;
00039             value= n.value;
00040         }
00041         return *this;
00042     }

bool AstNode::operator== ( const AstNode n  )  const [inline]

Definition at line 44 of file AstNode.h.

00044                                             {
00045         return this == &n;
00046     }

void AstNode::setValue ( const std::string &  v  )  [inline]

Definition at line 48 of file AstNode.h.

References value.

00048 { value = v; }

void AstNode::setType ( const std::string &  t  )  [inline]

Definition at line 49 of file AstNode.h.

References type.

00049 { type  = t; }

std::string AstNode::getValue (  )  const [inline]

Definition at line 50 of file AstNode.h.

References value.

00050 { return value; }

std::string AstNode::getType (  )  const [inline]

Definition at line 51 of file AstNode.h.

References type.

00051 { return type; }


Friends And Related Function Documentation

std::ostream& operator<< ( std::ostream &  stream,
const AstNode node 
) [friend]


Field Documentation

std::string AstNode::type [private]

Definition at line 25 of file AstNode.h.

Referenced by getType(), operator<<(), operator=(), and setType().

std::string AstNode::value [private]

Definition at line 26 of file AstNode.h.

Referenced by getValue(), operator<<(), operator=(), and setValue().


The documentation for this class was generated from the following file:
Generated on Wed Feb 27 20:31:38 2008 for php.ast.svn.src. by  doxygen 1.5.3