<?php /** * class VariableValue * Represents a variable value. */ class VariableValue extends Leaf { /** * Variable Value */ private $value; private $comment; public function __construct($value, $comment) { $this->value = $value; $this->comment = $comment; } public function getValue() { return $this->value; } public function getComment() { return $this->comment; } public function addToComment($add) { if(trim($this->comment) == "") $this->comment = ""; else $this->comment .= Literals::get("LINEFEED"); return $this->comment .= $add; } /** * * @param Visitor $ visitor */ public function accept(Visitor $visitor, $level = 1) { $visitor->visit($this, $level++); } // end of member function accept } // end of VariableValue ?>