public function setValue($value) { if ($this instanceof EntityConstant && !is_scalar($value)) { throw new \LogicException("Only scalar value allowed in constant"); } $this->type = Types::detectType($value); $this->value = $value; return $this; }
public function setValue($value) { if ($this instanceof EntityConstant && !is_scalar($value)) { throw new \LogicException("Only scalar value allowed in constant"); } $this->type = Types::detectType($value); $this->value = $value; return $this; }