1 | <?php |
||
14 | trait ColumnsTrait |
||
15 | { |
||
16 | /** |
||
17 | * Set columns into SelectQuery. |
||
18 | * |
||
19 | * @param SelectQuery $query |
||
20 | * @param bool $minify Minify column names (will work in case when query parsed in |
||
21 | * FETCH_NUM mode). |
||
22 | * @param string $prefix Prefix to be added for each column name. |
||
23 | * @param bool $overwrite When set to true existed columns will be removed. |
||
24 | */ |
||
25 | protected function mountColumns( |
||
49 | |||
50 | /** |
||
51 | * Joined table alias. |
||
52 | * |
||
53 | * @return string |
||
54 | */ |
||
55 | abstract protected function getAlias(): string; |
||
56 | |||
57 | /** |
||
58 | * list of columns to be loaded. |
||
59 | * |
||
60 | * @return array |
||
61 | */ |
||
62 | abstract protected function getColumns(): array; |
||
63 | } |