Newer
Older
<?php
/**
* Class ExpressionNotSupportedByQuestion
*
* Date: 25.03.13
* Time: 15:15
* @author Thomas Joußen <tjoussen@databay.de>
*/
class ExpressionNotSupportedByQuestion extends \RuntimeException
{
/**
* @param string $expression
* @param int $question_index
*/
public function __construct($expression, $question_index)
{
$this->expression = $expression;
$this->question_index = $question_index;
parent::__construct(
sprintf('The expression "%s" is not supported by the question with index "Q%s"', $this->expression, $this->question_index)
);
}
/**
* @return int
*/
public function getQuestionIndex()
{
return $this->question_index;
}