| 1 | <?php |
||
| 14 | trait UpdateDeleteTrait |
||
| 15 | { |
||
| 16 | protected static $options; |
||
| 17 | |||
| 18 | /** |
||
| 19 | * Adds a LIMIT clause. |
||
| 20 | * |
||
| 21 | * @param int $limit |
||
| 22 | * @param bool $force |
||
| 23 | * |
||
| 24 | * @return self |
||
| 25 | */ |
||
| 26 | public function limit($limit, $force = false) |
||
| 40 | |||
| 41 | /** |
||
| 42 | * Adds an offset to the LIMIT clause. |
||
| 43 | * |
||
| 44 | * @param int $offset |
||
| 45 | * |
||
| 46 | * @return self |
||
| 47 | */ |
||
| 48 | public function offset($offset) |
||
| 58 | |||
| 59 | /** |
||
| 60 | * Check whether the sqlite has a compiled option. |
||
| 61 | * |
||
| 62 | * @param string $name |
||
| 63 | * |
||
| 64 | * @return bool |
||
| 65 | */ |
||
| 66 | public function hasCompiledOption($name) |
||
| 74 | } |
||
| 75 |
In PHP it is possible to write to properties without declaring them. For example, the following is perfectly valid PHP code:
Generally, it is a good practice to explictly declare properties to avoid accidental typos and provide IDE auto-completion: