| Total Complexity | 5 |
| Total Lines | 79 |
| Duplicated Lines | 0 % |
| Coverage | 0% |
| Changes | 0 | ||
| 1 | <?php |
||
| 10 | abstract class AbstractExpr implements ExprInterface |
||
| 11 | { |
||
| 12 | /** |
||
| 13 | * @var string|null |
||
| 14 | */ |
||
| 15 | protected $relation; |
||
| 16 | |||
| 17 | /** |
||
| 18 | * @var string |
||
| 19 | */ |
||
| 20 | protected $column; |
||
| 21 | |||
| 22 | /** |
||
| 23 | * @var mixed |
||
| 24 | */ |
||
| 25 | protected $value; |
||
| 26 | |||
| 27 | /** |
||
| 28 | * @var string |
||
| 29 | */ |
||
| 30 | protected $expression; |
||
| 31 | |||
| 32 | /** |
||
| 33 | * @var string |
||
| 34 | */ |
||
| 35 | protected $operator; |
||
| 36 | |||
| 37 | /** |
||
| 38 | * AbstractExpr constructor. |
||
| 39 | * |
||
| 40 | * @param string|null $relation |
||
| 41 | * @param string $column |
||
| 42 | * @param mixed $value |
||
| 43 | */ |
||
| 44 | public function __construct(?string $relation, string $column, $value) |
||
| 45 | { |
||
| 46 | $this->relation = $relation; |
||
| 47 | $this->column = $column; |
||
| 48 | $this->value = $value; |
||
| 49 | } |
||
| 50 | |||
| 51 | /** |
||
| 52 | * @param string|null $expression |
||
| 53 | * |
||
| 54 | * @return AbstractExpr |
||
| 55 | */ |
||
| 56 | public function setExpression(string $expression = null): self |
||
| 57 | { |
||
| 58 | $this->expression = $expression; |
||
| 59 | |||
| 60 | return $this; |
||
| 61 | } |
||
| 62 | |||
| 63 | /** |
||
| 64 | * @return string |
||
| 65 | */ |
||
| 66 | public function getExpression(): string |
||
| 69 | } |
||
| 70 | |||
| 71 | /** |
||
| 72 | * @param string|null $operator |
||
| 73 | * |
||
| 74 | * @return AbstractExpr |
||
| 75 | */ |
||
| 76 | public function setOperator(string $operator = null): self |
||
| 81 | } |
||
| 82 | |||
| 83 | /** |
||
| 84 | * @return string |
||
| 85 | */ |
||
| 86 | public function getOperator(): string |
||
| 91 |