public function getData() { switch ($this->operator) { case TES4LogicalExpressionOperator::OPERATOR_AND(): return $this->leftValue->getData() && $this->rightValue->getData(); case TES4LogicalExpressionOperator::OPERATOR_OR(): return $this->leftValue->getData() || $this->rightValue->getData(); } throw new ConversionException("Unknown TES4LogicalExpressionOperator"); }